-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.blocks
25 lines (19 loc) · 7.17 KB
/
main.blocks
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<xml xmlns="https://developers.google.com/blockly/xml"><variables><variable id="JoY+{VR,o$/V@/3vpdoT">tallet</variable><variable id="%T$7S_2OGXyGm~6fiV$4">startigjen0</variable><variable id="((}!9,{LWchT$f.JS*Z[">startigjen10</variable></variables><comment id="$HiH3MM}d#AyI,MQZg!I" data="0" x="-12" y="-1112" h="360" w="480">Unngå å telle forbi 9. pga. "scrolling", og test med modulus..
Teller opp med A og ned med B
Telle opp reset til 0
Telle ned reset til 9
Lurt å teste på enkle ting for å brukes senere.
Lyden er med for å se det er liv i Mbit.
Endrer nok intervall etter hvert.</comment><block type="pxt-on-start" id="KqdI6O}E4Q|XEeWJKeU9" x="495" y="-1075"><statement name="HANDLER"><block type="variables_set" id="gFrzyylEQbCQR?mS~tWY"><field name="VAR" id="JoY+{VR,o$/V@/3vpdoT">tallet</field><value name="VALUE"><shadow type="math_number" id="OOzUEY}+1j,llCPO}{zQ"><field name="NUM">0</field></shadow></value><next><block type="variables_set" id="+iQFH219OBgr13ee-;%o"><field name="VAR" id="%T$7S_2OGXyGm~6fiV$4">startigjen0</field><value name="VALUE"><shadow type="math_number" id="oC7eIxCKx:K+Gh+?q8[/"><field name="NUM">10</field></shadow></value><next><block type="variables_set" id="cVkMQ29*i91|1~3-]h@m"><field name="VAR" id="((}!9,{LWchT$f.JS*Z[">startigjen10</field><value name="VALUE"><shadow type="math_number" id="QJWF}IVZ(Y7;=IwfK;b?"><field name="NUM">10</field></shadow></value><next><block type="device_show_number" id="XpI2AP`}oyF3ii_a0-[*"><value name="number"><block type="variables_get" id="+).jEsH%*H]jqUv+tI/F"><field name="VAR" id="JoY+{VR,o$/V@/3vpdoT">tallet</field></block></value></block></next></block></next></block></next></block></statement></block><block type="device_forever" id="mS!@r@g/ImH1~`,M@|l," x="820" y="-1075"><statement name="HANDLER"><block type="device_ring" id="]!(RO*se1|8#BH|O$r-g"><value name="note"><shadow type="device_note" id="%,?Qw-a2wLDt=N(WGhl3"><field name="name">262</field></shadow></value><next><block type="device_pause" id="k,m|[*$jD+C2T.fMS{h)"><value name="pause"><shadow type="timePicker" id="]A5;b:)K3n[np/^WN$|:"><field name="ms">25</field></shadow></value><next><block type="device_rest" id="r}zPm-mrsh9i:z#vi0/s"><value name="duration"><shadow type="device_beat" id="aqq13mKU3*T,++Z:_jM1"><field name="fraction">BeatFraction.Whole</field></shadow></value><next><block type="device_pause" id="TQqy~fbxjH]$uB8?(T4k"><value name="pause"><shadow type="timePicker" id="7t^rN9);b*Z#N}uh{Mc@"><field name="ms">9000</field></shadow></value></block></next></block></next></block></next></block></statement></block><block type="device_button_event" id=",LP;R#l1uhQd2r.*LVIn" x="-4" y="-706"><field name="NAME">Button.A</field><data>0</data><statement name="HANDLER"><block type="variables_change" id="dZMA_Cvs9;CEek0Y,;pq"><field name="VAR" id="JoY+{VR,o$/V@/3vpdoT">tallet</field><value name="VALUE"><shadow type="math_number" id=",k+0ZgG:rt-nkE8K.B7{"><field name="NUM">1</field></shadow></value><next><block type="controls_if" id="D-kL}ZT%yTAfkbKtp5Ku"><mutation else="1"/><value name="IF0"><shadow type="logic_boolean"><field name="BOOL">TRUE</field></shadow><block type="logic_compare" id="otHfQ$tXw@1AFtsOrK}["><field name="OP">EQ</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="math_modulo" id="7Qv!o]+L`||iafaf.U1]"><value name="DIVIDEND"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="H~,|1)HQmZHu8b~__Mss"><field name="VAR" id="JoY+{VR,o$/V@/3vpdoT">tallet</field></block></value><value name="DIVISOR"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="l!F5=tMA,FC8Tu#M[g;B"><field name="VAR" id="%T$7S_2OGXyGm~6fiV$4">startigjen0</field></block></value></block></value><value name="B"><shadow type="math_number" id="42w{Mj_1whnCij79y5bX"><field name="NUM">0</field></shadow></value></block></value><statement name="DO0"><block type="variables_set" id="Xo7UT%L2|!tXr4..O`1x"><field name="VAR" id="JoY+{VR,o$/V@/3vpdoT">tallet</field><value name="VALUE"><shadow type="math_number" id="g2%UG0Y-MFdY?Y.y,Nss"><field name="NUM">0</field></shadow></value><next><block type="device_show_leds" id="n%5xM{]wt`}LzlQ/@*Ht"><field name="LEDS">`
# # # # #
. . . . #
. # . . #
# # # # #
. # . . .
`</field><next><block type="device_pause" id="dr+-z/p[sA6D])-xg+YJ"><value name="pause"><shadow type="timePicker" id=".5u-+75i1qw)Go0ouW),"><field name="ms">100</field></shadow></value></block></next></block></next></block></statement><statement name="ELSE"><block type="device_clear_display" id="W(X5E2.n#W{70bqsA~SM"/></statement><next><block type="device_show_number" id="SZQ$u~67OP6]v8xfTILZ"><value name="number"><block type="variables_get" id="9qd4_dRkEo5S64c-`5NL"><field name="VAR" id="JoY+{VR,o$/V@/3vpdoT">tallet</field></block></value></block></next></block></next></block></statement></block><block type="device_button_event" id="H!qZ[f`y.vB-%JCBR@2X" x="0" y="0"><field name="NAME">Button.B</field><statement name="HANDLER"><block type="variables_change" id="}]H*|+k4WF|f-SEBqEPl"><field name="VAR" id="JoY+{VR,o$/V@/3vpdoT">tallet</field><value name="VALUE"><shadow type="math_number" id="k2(^kKY}1%4=aEG{]d3t"><field name="NUM">-1</field></shadow></value><next><block type="controls_if" id="fM7LZk1s]B#w*?Tj={-0"><mutation else="1"/><value name="IF0"><shadow type="logic_boolean"><field name="BOOL">TRUE</field></shadow><block type="logic_compare" id="b0WD(b:ARg{6T{rGbL4D"><field name="OP">EQ</field><value name="A"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="math_modulo" id="qdio;%yBLT~FuXCy]s`/"><value name="DIVIDEND"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="#o_uus/5XeEw$O!I6q!e"><field name="VAR" id="JoY+{VR,o$/V@/3vpdoT">tallet</field></block></value><value name="DIVISOR"><shadow type="math_number"><field name="NUM">0</field></shadow><block type="variables_get" id="Vop482?:U|d}JV6JVKLu"><field name="VAR" id="%T$7S_2OGXyGm~6fiV$4">startigjen0</field></block></value></block></value><value name="B"><shadow type="math_number" id="7VM1M?v3pI9Ef(f71.aH"><field name="NUM">0</field></shadow></value></block></value><statement name="DO0"><block type="variables_set" id="cU6y1YGXH,BS6!YZGupW"><field name="VAR" id="JoY+{VR,o$/V@/3vpdoT">tallet</field><value name="VALUE"><shadow type="math_number" id="JLVbm$.f}82/;h~(or3%"><field name="NUM">9</field></shadow></value><next><block type="device_show_leds" id="w.D2n9Z8nWRL*`d,Fnm|"><field name="LEDS">`
# # # # #
# . . . .
# . . # .
# # # # #
. . . # .
`</field><next><block type="device_pause" id="HKF/5pMPR;$=YrW-WX.V"><value name="pause"><shadow type="timePicker" id="M4Rvg.Y^LQIf]k$E9Rt:"><field name="ms">100</field></shadow></value></block></next></block></next></block></statement><statement name="ELSE"><block type="device_clear_display" id="XrM,TR9;TgPWXH/km(yO"/></statement><next><block type="device_show_number" id="Gh(Fc^1PTlrltlNbbKQF"><value name="number"><block type="variables_get" id="ec^Y4~3!-}|MPPwbN.3c"><field name="VAR" id="JoY+{VR,o$/V@/3vpdoT">tallet</field></block></value></block></next></block></next></block></statement></block></xml>