microsoft / pxt-brainpad
File Size

The distribution of size of files (measured in lines of code).

Intro
  • File size measurements show the distribution of size of files.
  • Files are classified in four categories based on their size (lines of code): 1-100 (very small files), 101-200 (small files), 201-500 (medium size files), 501-1000 (long files), 1001+(very long files).
  • It is a good practice to keep files small. Long files may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
File Size Overall
  • There are 156 files with 11,515 lines of code.
    • 1 very long files (1,293 lines of code)
    • 2 long files (1,537 lines of code)
    • 7 medium size files (2,090 lines of codeclsfd_ftr_w_mp_ins)
    • 22 small files (3,060 lines of code)
    • 124 very small files (3,535 lines of code)
11% | 13% | 18% | 26% | 30%
Legend:
1001+
501-1000
201-500
101-200
1-100


explore: zoomable circles | sunburst | 3D view
File Size per Extension
1001+
501-1000
201-500
101-200
1-100
ts16% | 8% | 22% | 25% | 27%
cpp0% | 32% | 11% | 24% | 31%
html0% | 0% | 0% | 87% | 12%
h0% | 0% | 0% | 23% | 76%
less0% | 0% | 0% | 66% | 33%
File Size per Logical Decomposition
primary
1001+
501-1000
201-500
101-200
1-100
sim/visuals64% | 31% | 0% | 0% | 4%
libs/screen0% | 87% | 0% | 11% | 1%
libs/game0% | 0% | 36% | 36% | 26%
libs/core0% | 0% | 24% | 27% | 48%
libs/accelerometer0% | 0% | 71% | 0% | 28%
libs/display0% | 0% | 49% | 0% | 50%
libs/neopixel0% | 0% | 79% | 0% | 20%
libs/music0% | 0% | 0% | 61% | 38%
libs/infrared0% | 0% | 0% | 76% | 23%
libs/brainbot0% | 0% | 0% | 100% | 0%
sim0% | 0% | 0% | 100% | 0%
sim/public0% | 0% | 0% | 87% | 12%
libs/settings0% | 0% | 0% | 83% | 16%
libs/controller0% | 0% | 0% | 86% | 13%
sim/state0% | 0% | 0% | 60% | 39%
theme0% | 0% | 0% | 66% | 33%
libs/brainpad0% | 0% | 0% | 0% | 100%
libs/lightbulb0% | 0% | 0% | 0% | 100%
libs/leds0% | 0% | 0% | 0% | 100%
libs/animation0% | 0% | 0% | 0% | 100%
libs/base0% | 0% | 0% | 0% | 100%
libs/buttons0% | 0% | 0% | 0% | 100%
libs/braingamer0% | 0% | 0% | 0% | 100%
libs/cptest0% | 0% | 0% | 0% | 100%
libs/thermometer0% | 0% | 0% | 0% | 100%
libs/sonar0% | 0% | 0% | 0% | 100%
libs/led0% | 0% | 0% | 0% | 100%
editor0% | 0% | 0% | 0% | 100%
libs/blocksprj0% | 0% | 0% | 0% | 100%
Longest Files (Top 50)
File# lines# units
boardsvg.ts
in sim/visuals
1293 -
image.cpp
in libs/screen
902 56
board.ts
in sim/visuals
635 26
sprite.ts
in libs/game
443 27
hf2.cpp
in libs/core
328 9
accelerometer.ts
in libs/accelerometer/sim
291 20
neopixel.ts
in libs/core/sim
289 17
info.ts
in libs/game
286 33
graph.ts
in libs/display
227 11
neopixel.ts
in libs/neopixel
226 16
brainbot.ts
in libs/brainbot
196 17
codal.cpp
in libs/core
196 21
tilemap.ts
in libs/game
196 25
dalboard.ts
in sim
193 4
physics.ts
in libs/game
181 9
siminstructions.html
in sim/public
179 -
melodies.ts
in libs/music
148 7
pins.h
in libs/core
144 -
game.ts
in libs/game
133 15
settings.cpp
in libs/settings
131 8
buttons.ts
in libs/core/sim
126 5
controller.ts
in libs/controller
119 13
receiverir.cpp
in libs/infrared
119 5
background.ts
in libs/game
118 7
led.ts
in libs/core/sim
116 6
leds.ts
in sim/state
116 5
screen.cpp
in libs/screen
115 8
style.less
in theme
115 -
switch.ts
in libs/core/sim
110 3
infrared.cpp
in libs/infrared
104 7
music.ts
in libs/music
104 7
spritemap.ts
in libs/game
101 9
accelerometer.cpp
in libs/accelerometer
99 5
photocell.ts
in libs/core/sim
99 7
edgeconnector.ts
in libs/core/sim
98 10
scene.ts
in libs/game
95 2
pins.ts
in libs/core/sim
94 23
leds.cpp
in libs/display
94 3
platform.h
in libs/core
90 -
display.ts
in libs/display
89 11
uf2hid.h
in libs/core
88 -
animation.ts
in libs/animation
80 12
console.ts
in libs/base
78 9
uf2format.h
in libs/core
77 4
pincontrol.ts
in sim/visuals
77 5
buttons.cpp
in libs/buttons
76 5
usb.cpp
in libs/core
76 6
lightbulb.ts
in libs/lightbulb
73 12
hitbox.ts
in libs/game
71 6
scenes.ts
in libs/game
70 14
Files With Most Units (Top 20)
File# lines# units
image.cpp
in libs/screen
902 56
info.ts
in libs/game
286 33
sprite.ts
in libs/game
443 27
board.ts
in sim/visuals
635 26
tilemap.ts
in libs/game
196 25
pins.ts
in libs/core/sim
94 23
codal.cpp
in libs/core
196 21
accelerometer.ts
in libs/accelerometer/sim
291 20
brainbot.ts
in libs/brainbot
196 17
neopixel.ts
in libs/core/sim
289 17
neopixel.ts
in libs/neopixel
226 16
game.ts
in libs/game
133 15
scenes.ts
in libs/game
70 14
controller.ts
in libs/controller
119 13
animation.ts
in libs/animation
80 12
lightbulb.ts
in libs/lightbulb
73 12
display.ts
in libs/display
89 11
graph.ts
in libs/display
227 11
music.ts
in libs/music/sim
65 11
edgeconnector.ts
in libs/core/sim
98 10
Files With Long Lines (Top 20)

There are 23 files with lines longer than 120 characters. In total, there are 157 long lines.

File# lines# units# long lines
boardsvg.ts
in sim/visuals
1293 - 49
switch.ts
in libs/core/sim
110 3 19
led.ts
in libs/core/sim
116 6 16
photocell.ts
in libs/core/sim
99 7 14
neopixel.ts
in libs/core/sim
289 17 10
board.ts
in sim/visuals
635 26 8
accelerometer.ts
in libs/accelerometer/sim
291 20 5
microservo.ts
in libs/core/sim
64 4 5
leds.cpp
in libs/display
94 3 5
leds.cpp
in libs/leds
56 1 5
sprite.ts
in libs/game
443 27 4
graph.ts
in libs/display
227 11 3
serial.ts
in libs/core/sim
35 10 2
info.ts
in libs/game
286 33 2
dalboard.ts
in sim
193 4 2
analogSensor.ts
in libs/core/sim
12 - 1
buttons.ts
in libs/core/sim
126 5 1
physics.ts
in libs/game
181 9 1
spritemap.ts
in libs/game
101 9 1
melodies.ts
in libs/music
148 7 1