-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path_history
1 lines (1 loc) · 27.5 KB
/
_history
1
{"entries":[{"timestamp":1730883790768,"editorVersion":"7.0.51","changes":[{"type":"edited","filename":"main.blocks","patch":[{"diffs":[[0,"pe=\""],[-1,"function_definition\" id=\"Lynit7*t*+CJPq2L!vr/\" x=\"547\" y=\"-48\"><mutation name=\"charToMorse\" functionid=\"c(syow,kueThchIXqe}j\"><arg name=\"ch"],[1,"pxt-on-st"],[0,"ar"],[1,"t"],[0,"\" id=\"j"],[-1,"d2u8214ukacefxxz9dn\" type=\"string\"></arg></mutation><field name=\"function_name\">charToMorse</field><value name=\"jd2u8214ukacefxxz9dn\"><block type=\"argument_reporter_string\" id=\"TOiC1rOMx?eTM.qo2FgN\"><mutation duplicateondrag=\"true\"></mutation><field name=\"VALUE\">char</field></block></value"],[1,"S84xC)K%9c3*W^%L^/z\" x=\"0\" y=\"0\""],[0,"><st"]],"start1":246,"start2":246,"length1":446,"length2":59},{"diffs":[[0,"statement name=\""],[-1,"STACK"],[1,"HANDLER"],[0,"\"><block type=\"f"]],"start1":303,"start2":303,"length1":37,"length2":39},{"diffs":[[0,"pe=\""],[-1,"function_return\" id=\"RW)SMG-|7k=*`dv[;[?2\"><mutation xmlns=\"http://www.w3.org/1999/xhtml\" no_return_value=\"false\"></mutation"],[1,"radio_set_group\" id=\"jFFN,emGGlQw$~,lgTAN\""],[0,"><va"]],"start1":337,"start2":337,"length1":132,"length2":50},{"diffs":[[0,"value name=\""],[-1,"RETURN_VALUE"],[1,"ID"],[0,"\"><shadow ty"]],"start1":385,"start2":385,"length1":36,"length2":26},{"diffs":[[0,"mber"],[-1,"\" id=\"wt%~XUJ)rb(P^-/bf,PH\"><field name=\"NUM\">0</field></shadow><block type=\"lists_index_get\" id=\"],l-=!F3!-l}c7x)7~U_\"><value name=\"LIST\"><block type=\"variables_get\" id=\"$BrWrMD0{[4D]/SN=V`w\"><field name=\"VAR\" id=\"KQ;GE9bR^m|c2gC_j?%/\">MORSE_CODE</field></block></value><value name=\"INDEX\"><shadow type=\"math_number\" id=\"?f^?fNpD$$%zaGu/o([)\"><field name=\"NUM\">0</field></shadow><block type=\"typescript_expression\" id=\"v%N^Q{4yH/LOpm=x.1r2\"><field name=\"EXPRESSION\">char.toUpperCase()</field></block></value></block></value></block></statement></block><block type=\"pxt-on-start\" id=\"N?O,5f$AcGG~u1ZAX8h6\" x=\"0\" y=\"0\"><statement name=\"HANDLER\""],[1,"_minmax\" id=\";Uc$UCH[-5[|f3|BOi8@\"><mutation min=\"0\" max=\"255\" precision=\"0\"></mutation><field name=\"SLIDER\">1</field></shadow></value><next"],[0,"><bl"]],"start1":422,"start2":422,"length1":651,"length2":148},{"diffs":[[0,"id=\""],[-1,"UQE|FWZW$Y2ze2e*2`t7"],[1,"G%BYVSp:0+bi6fNvXHbx"],[0,"\"><m"]],"start1":602,"start2":602,"length1":28,"length2":28},{"diffs":[[0,"on><"],[-1,"/block></statement></block><block type=\"function_definition\" id=\"A5rwIFHUrY$ty^Cx]#?G\" x=\"523\" y=\"172\"><mutation name=\"morseToChar\" functionid=\"DZo0r?4H?DaTMw9beQ/T\"><arg name=\"morse\" id=\"fkv4pkfnnso2o5iyo4nz\" type=\"Array\"></arg></mutation><field name=\"function_name\">morseToChar</field"],[1,"next><block type=\"variables_set\" id=\"@ag!UwKIqf}0Q:DqgL,?\"><field name=\"VAR\" id=\"~xH2)7b3]sy2X{yK*ogH\">list</field><value name=\"VALUE\"><shadow type=\"math_number\" id=\"LS]_m#ve~K/+$^iCH;fa\"><field name=\"NUM\">0</field></shadow><block type=\"lists_create_with\" id=\"Wa)|#)fJ;G[iqq_g,.Ck\"><mutation items=\"0\" horizontalafter=\"3\"></mutation></block></value></block></next></block></next></block></statement></block><block type=\"device_button_event\" id=\"LZsT-rHDH2M7G.lu3`KI\" x=\"490\" y=\"0\"><field name=\"NAME\">Button.A</field><statement name=\"HANDLER\"><block type=\"array_push\" id=\"|H;v+H2;2?[9O+9k0u%@\"><value name=\"list\"><block type=\"variables_get\" id=\"vBM.c(}5b8S|}8RYLQDA\"><field name=\"VAR\" id=\"~xH2)7b3]sy2X{yK*ogH\">list</field></block></value><value name=\"value\"><shadow type=\"math_number\" id=\"?{32Zcxl)AgyryD*j!Vi\"><field name=\"NUM\">0</field></shadow></value><next><block type=\"device_show_leds\" id=\"PHPn~m:uMpZ#@oK8Pgi#\"><field name=\"LEDS\">`\n . . . . . \n . . . . . \n . . # . . \n . . . . . \n . . . . .\n `</field><next><block type=\"music_playable_play\" id=\"FK;=PMVP])DWcWQx50k$\"><field name=\"playbackMode\">music.PlaybackMode.InBackground</field><value name=\"toPlay\"><shadow type=\"music_string_playable\" id=\"esZq8oShqV34`}w`Y9a_\"></shadow><block type=\"music_tone_playable\" id=\"~Ia7)_)j^=Be{(_.daw4\"><value name=\"note\"><shadow type=\"device_note\" id=\"UEDIJh1c:J!70BtRd-,d\"><field name=\"name\">494</field></shadow></value><value name=\"duration\"><shadow type=\"device_beat\" id=\"!jO0*r#FPz@2n4EPhAnt\"><field name=\"fraction\">BeatFraction.Eighth</field></shadow></value></block></value><next><block type=\"device_pause\" id=\"|zOviVD(dJ4!h*mu;@IQ\"><value name=\"pause\"><shadow type=\"timePicker\" id=\"P|ysX~~0T/@ryqHV~g~-\"><field name=\"ms\">200</field></shadow></value><next><block type=\"device_clear_display\" id=\"Sg.XG7K5rx#1jZjz?QUT\"></block></next></block></next></block></next></block></next></block></statement></block><block type=\"device_button_event\" id=\"=CBP4qydV4+16yBUG@5y\" x=\"1079\" y=\"0\"><field name=\"NAME\">Button.B</field><statement name=\"HANDLER\"><block type=\"array_push\" id=\"]6RPEVpSGFel?%*4|b,u\"><value name=\"list\"><block type=\"variables_get\" id=\"*0wj`15+[I)i1([afVmI\"><field name=\"VAR\" id=\"~xH2)7b3]sy2X{yK*ogH\">list</field></block></value><value name=\"value\"><shadow type=\"math_number\" id=\"7|Up~w7I+1U@$LY_XXUr\"><field name=\"NUM\">1</field></shadow></value><next><block type=\"device_show_leds\" id=\"S1^?c2tOKZtY]RxDL[*F\"><field name=\"LEDS\">`\n . . . . . \n . . . . . \n . # # # . \n . . . . . \n . . . . .\n `</field><next><block type=\"music_playable_play\" id=\"-d2DbMZ:Uduf[;E9tX^j\"><field name=\"playbackMode\">music.PlaybackMode.InBackground</field><value name=\"toPlay\"><shadow type=\"music_string_playable\" id=\"6%1;#h-bG~NtX/1=CR]L\"></shadow><block type=\"music_tone_playable\" id=\"CELDK]2@{9$*tl1YR=ck\"><value name=\"note\"><shadow type=\"device_note\" id=\"bH[!t9Zah=HuI+;UJViI\"><field name=\"name\">494</field></shadow></value><value name=\"duration\"><shadow type=\"device_beat\" id=\"w`r3H91H(n*;:o0RINxb\"><field name=\"fraction\">BeatFraction.Half</field></shadow></value></block></value><next><block type=\"device_pause\" id=\"q8YHTdX2M$kLX^YA:wMK\"><value name=\"pause\"><shadow type=\"timePicker\" id=\"kyf9-)UC:}q-]Kg!A_2{\"><field name=\"ms\">200</field></shadow></value><next><block type=\"device_clear_display\" id=\"KGH25/}~*Un#P;fjU;hI\"></block></next></block></next></block></next></block></next></block></statement></block><block type=\"device_forever\" id=\"~2tjJLc{v}x!-=004+S~\" x=\"2144\" y=\"0\"></block><block type=\"device_button_event\" id=\"A{78f=cHbgi.9|$E.]2b\" x=\"1866\" y=\"119\"><field name=\"NAME\">Button.AB</field><statement name=\"HANDLER\"><block type=\"device_print_message\" id=\"}7K:Kz,[1)|e@cib[NWE\"><value name=\"text\"><shadow type=\"text\" id=\"[zJ,UM~7MX~a-HM0aFO9\"><field name=\"TEXT\"></field></shadow><block type=\"function_call_output\" id=\"oHW?_O`X|yN==cUZEw_@\"><mutation name=\"morseToChar\" functionid=\"DZo0r?4H?DaTMw9beQ/T\"><arg name=\"morse\" id=\"fkv4pkfnnso2o5iyo4nz\" type=\"Array\"></arg></mutation><value name=\"fkv4pkfnnso2o5iyo4nz\"><block type=\"variables_get\" id=\"NE^XdB{HO=N~e%s{|H|v\"><field name=\"VAR\" id=\"~xH2)7b3]sy2X{yK*ogH\">list</field></block></value></block></value><next><block type=\"radio_datagram_send_string\" id=\"Ofeby`q%Vt9c6t}zsGWc\"><value name=\"msg\"><shadow type=\"text\" id=\"o3{Pe_Y4H+b%z8UZM7}/\"><field name=\"TEXT\"></field></shadow><block type=\"function_call_output\" id=\"*]+jVI8^AtuyiWEZB,p8\"><mutation name=\"morseToChar\" functionid=\"DZo0r?4H?DaTMw9beQ/T\"><arg name=\"morse\" id=\"fkv4pkfnnso2o5iyo4nz\" type=\"Array\"></arg></mutation"],[0,"><va"]],"start1":1978,"start2":1978,"length1":294,"length2":4612},{"diffs":[[0,"pe=\""],[1,"v"],[0,"ar"],[-1,"gument_reporter_array\" id=\"7L81d]3+z4m5lm-oRP@j"],[1,"iables_get\" id=\"2+w[z00_lS:ASMnJO0y3\"><field name=\"VAR\" id=\"~xH2)7b3]sy2X{yK*ogH\">list</field></block></value></block></value><next><block type=\"variables_set\" id=\"5b.4l|GWeqp)^#@R0ggw\"><field name=\"VAR\" id=\"~xH2)7b3]sy2X{yK*ogH\">list</field><value name=\"VALUE\"><shadow type=\"math_number\" id=\"HsdP}_Zo]kSQDj8}GhPW\"><field name=\"NUM\">0</field></shadow><block type=\"lists_create_with\" id=\"$KRQD*B]*wO+|MJ3O)9f\"><mutation items=\"0\" horizontalafter=\"3\"></mutation></block></value></block></next></block></next></block></statement></block><block type=\"radio_on_string_drag\" id=\"l*Ll:A`#m60AX/R49jWz\" x=\"502\" y=\"583\"><value name=\"HANDLER_DRAG_PARAM_receivedString\"><block type=\"argument_reporter_string\" id=\"9678OkLLbFrjd`Q-u1U6\"><mutation duplicateondrag=\"true\"></mutation><field name=\"VALUE\">receivedString</field></block></value><statement name=\"HANDLER\"><block type=\"device_print_message\" id=\"`36K_WUfpx}hP1]wFF~y\"><value name=\"text\"><block type=\"argument_reporter_string\" id=\")aefhL]X*8/^DQsK:2?X\"><field name=\"VALUE\">receivedString</field></block></value></block></statement></block><block type=\"function_definition\" id=\"i(2yiYkYz#hM1nM~eX7)\" x=\"465\" y=\"1689\"><mutation name=\"morseToChar\" functionid=\"DZo0r?4H?DaTMw9beQ/T\"><arg name=\"morse\" id=\"fkv4pkfnnso2o5iyo4nz\" type=\"Array\"></arg></mutation><field name=\"function_name\">morseToChar</field><value name=\"fkv4pkfnnso2o5iyo4nz\"><block type=\"argument_reporter_array\" id=\"TQ,8DB!-54i}fV%%_jOu"],[0,"\"><m"]],"start1":6631,"start2":6631,"length1":57,"length2":1452},{"diffs":[[0,"id=\""],[-1,"clg}kTIX*VD]btc[7acC"],[1,"79?*V[Wf|y@d{uhS^=:y"],[0,"\"><m"]],"start1":8233,"start2":8233,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"G8)jHZ3-;ABdV|gtSjRd"],[1,"E=ZmU1X$gzlIw+8jMu,E"],[0,"\"><v"]],"start1":8498,"start2":8498,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"L),/:Zo-8#la^Q/vptJD"],[1,"7AVxZqoCoygmK^p?KmuU"],[0,"\"><f"]],"start1":8571,"start2":8571,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"jk%SP{]Vaj{YQYly0fj."],[1,"8z5.@,`MFxwmsHBb,ekg"],[0,"\"><f"]],"start1":8665,"start2":8665,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"N0tvitNzF!QJ?9KX|ak4"],[1,"=~IO=k:KV`C5ZDxDP#Y/"],[0,"\"><f"]],"start1":8761,"start2":8761,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"3HH9V6HhivJuQ$CwXwfz"],[1,"Rash9Xgy.BUq2?J;VzrL"],[0,"\"><f"]],"start1":8851,"start2":8851,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"%:2]vz8$:CK}!_`ew}bB"],[1,"aAj%Lt~^XQ/j|lZ{7Xfx"],[0,"\"><f"]],"start1":8992,"start2":8992,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"pRZ05.-rL%-ap7DgS]KN"],[1,"uZMV9ao@Qz0J1M/p?B}U"],[0,"\"><f"]],"start1":9090,"start2":9090,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"N%~zy$I$!Fd*XaqP[XvX"],[1,"/%owqVh~w8I4,?.$[%qM"],[0,"\"><m"]],"start1":9242,"start2":9242,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"qubPo^B{;}^]R3_2Vo;g"],[1,"Ir1(ly]RL)jLlW:Axn()"],[0,"\"><f"]],"start1":9404,"start2":9404,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"-*L{W_PBL+7HLdqTabZs"],[1,"9dDS#m7m/_V8m_XoA534"],[0,"\"><f"]],"start1":9485,"start2":9485,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"E7apTX9i4F.f@Mfwfe7%"],[1,"ppcS,FYz/*HM0]p_sqwg"],[0,"\"><m"]],"start1":9611,"start2":9611,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"K_G%yzgnSKq/E3ix5^|]"],[1,"8qQP;WQV$heVS#8QD=*#"],[0,"\"><f"]],"start1":9773,"start2":9773,"length1":28,"length2":28},{"diffs":[[0,"id=\""],[-1,"{ZR+v71(Nx3yanI@f1vO"],[1,"xmTH4RXG6=:}$]q}[kbQ"],[0,"\"><f"]],"start1":9863,"start2":9863,"length1":28,"length2":28},{"diffs":[[0,"/block><"],[1,"block type=\"function_definition\" id=\"#HFkc(c)SLk-@cdO6RGO\" x=\"1458\" y=\"1677\"><mutation name=\"charToMorse\" functionid=\"c(syow,kueThchIXqe}j\"><arg name=\"char\" id=\"jd2u8214ukacefxxz9dn\" type=\"string\"></arg></mutation><field name=\"function_name\">charToMorse</field><value name=\"jd2u8214ukacefxxz9dn\"><block type=\"argument_reporter_string\" id=\"r#O{{h4SW0Cd|Jm:DZy[\"><mutation duplicateondrag=\"true\"></mutation><field name=\"VALUE\">char</field></block></value><statement name=\"STACK\"><block type=\"function_return\" id=\"O-adwe)tMSL`pA0G^`o$\"><mutation xmlns=\"http://www.w3.org/1999/xhtml\" no_return_value=\"false\"></mutation><value name=\"RETURN_VALUE\"><shadow type=\"math_number\" id=\"GnDvdjh7~?YZ$pGfQe*U\"><field name=\"NUM\">0</field></shadow><block type=\"lists_index_get\" id=\"B@wx~8^]P%bhKAwuwaTV\"><value name=\"LIST\"><block type=\"variables_get\" id=\"Fj(hf!kfcDcs]R}Y^3fi\"><field name=\"VAR\" id=\"KQ;GE9bR^m|c2gC_j?%/\">MORSE_CODE</field></block></value><value name=\"INDEX\"><shadow type=\"math_number\" id=\"kd^E.At(FW_aW{4;LBKE\"><field name=\"NUM\">0</field></shadow><block type=\"typescript_expression\" id=\"bn-xGgC+*UG?yHkI5g6@\"><field name=\"EXPRESSION\">char.toUpperCase()</field></block></value></block></value></block></statement></block><"],[0,"/xml>"]],"start1":10012,"start2":10012,"length1":13,"length2":1234}]},{"type":"edited","filename":"main.ts","patch":[{"diffs":[[1,"input.onButtonPressed(Button.A, function () {\n list.push(0)\n basic.showLeds(`\n . . . . .\n . . . . .\n . . # . .\n . . . . .\n . . . . .\n `)\n music.play(music.tonePlayable(494, music.beat(BeatFraction.Eighth)), music.PlaybackMode.InBackground)\n basic.pause(200)\n basic.clearScreen()\n})\ninput.onButtonPressed(Button.AB, function () {\n basic.showString(\"\" + (morseToChar(list)))\n radio.sendString(\"\" + (morseToChar(list)))\n list = []\n})\nradio.onReceivedString(function (receivedString) {\n basic.showString(receivedString)\n})\ninput.onButtonPressed(Button.B, function () {\n list.push(1)\n basic.showLeds(`\n . . . . .\n . . . . .\n . # # # .\n . . . . .\n . . . . .\n `)\n music.play(music.tonePlayable(494, music.beat(BeatFraction.Half)), music.PlaybackMode.InBackground)\n basic.pause(200)\n basic.clearScreen()\n})\n"],[0,"function charToM"]],"start1":0,"start2":0,"length1":16,"length2":941},{"diffs":[[0," char\n}\n"],[1,"let list: number[] = []\nradio.setGroup(1)\n"],[0,"let MORS"]],"start1":1214,"start2":1214,"length1":16,"length2":58},{"diffs":[[0,"[],\n"],[-1,""],[0,"};\n"],[1,"list = []\nbasic.forever(function () {\n\t\n})\n"]],"start1":2061,"start2":2061,"length1":7,"length2":50}]},{"type":"edited","filename":"pxt.json","patch":[{"diffs":[[0,"code"],[-1,"-template"],[0,"\",\n "]],"start1":21,"start2":21,"length1":17,"length2":8}]}]}],"snapshots":[{"timestamp":1730883790767,"editorVersion":"7.0.51","text":{"main.blocks":"<xml xmlns=\"https://developers.google.com/blockly/xml\"><variables><variable id=\"K)X^~uL/`IN1[PBBRt[Z\">char</variable><variable id=\"~xH2)7b3]sy2X{yK*ogH\">list</variable><variable id=\"KQ;GE9bR^m|c2gC_j?%/\">MORSE_CODE</variable></variables><block type=\"pxt-on-start\" id=\"jS84xC)K%9c3*W^%L^/z\" x=\"0\" y=\"0\"><statement name=\"HANDLER\"><block type=\"radio_set_group\" id=\"jFFN,emGGlQw$~,lgTAN\"><value name=\"ID\"><shadow type=\"math_number_minmax\" id=\";Uc$UCH[-5[|f3|BOi8@\"><mutation min=\"0\" max=\"255\" precision=\"0\"></mutation><field name=\"SLIDER\">1</field></shadow></value><next><block type=\"typescript_statement\" id=\"G%BYVSp:0+bi6fNvXHbx\"><mutation xmlns=\"http://www.w3.org/1999/xhtml\" line0=\"let MORSE_CODE: { [key: string]: number[] } = {\" line1=\" A: [0, 1],\" line2=\" B: [1, 0, 0, 0],\" line3=\" C: [1, 0, 1, 0],\" line4=\" D: [1, 0, 0],\" line5=\" E: [0],\" line6=\" F: [0, 0, 1, 0],\" line7=\" G: [1, 1, 0],\" line8=\" H: [0, 0, 0, 0],\" line9=\" I: [0, 0],\" line10=\" J: [0, 1, 1, 1],\" line11=\" K: [1, 0, 1],\" line12=\" L: [0, 1, 0, 0],\" line13=\" M: [1, 1],\" line14=\" N: [1, 0],\" line15=\" O: [1, 1, 1],\" line16=\" P: [0, 1, 1, 0],\" line17=\" Q: [1, 1, 0, 1],\" line18=\" R: [0, 1, 0],\" line19=\" S: [0, 0, 0],\" line20=\" T: [1],\" line21=\" U: [0, 0, 1],\" line22=\" V: [0, 0, 0, 1],\" line23=\" W: [0, 1, 1],\" line24=\" X: [1, 0, 0, 1],\" line25=\" Y: [1, 0, 1, 1],\" line26=\" Z: [1, 1, 0, 0],\" line27=\" "0": [1, 1, 1, 1, 1],\" line28=\" "1": [0, 1, 1, 1, 1],\" line29=\" "2": [0, 0, 1, 1, 1],\" line30=\" "3": [0, 0, 0, 1, 1],\" line31=\" "4": [0, 0, 0, 0, 1],\" line32=\" "5": [0, 0, 0, 0, 0],\" line33=\" "6": [1, 0, 0, 0, 0],\" line34=\" "7": [1, 1, 0, 0, 0],\" line35=\" "8": [1, 1, 1, 0, 0],\" line36=\" "9": [1, 1, 1, 1, 0],\" line37=\" " ": [],\" line38=\"};\" numlines=\"39\" declaredvars=\"MORSE_CODE\"></mutation><next><block type=\"variables_set\" id=\"@ag!UwKIqf}0Q:DqgL,?\"><field name=\"VAR\" id=\"~xH2)7b3]sy2X{yK*ogH\">list</field><value name=\"VALUE\"><shadow type=\"math_number\" id=\"LS]_m#ve~K/+$^iCH;fa\"><field name=\"NUM\">0</field></shadow><block type=\"lists_create_with\" id=\"Wa)|#)fJ;G[iqq_g,.Ck\"><mutation items=\"0\" horizontalafter=\"3\"></mutation></block></value></block></next></block></next></block></statement></block><block type=\"device_button_event\" id=\"LZsT-rHDH2M7G.lu3`KI\" x=\"490\" y=\"0\"><field name=\"NAME\">Button.A</field><statement name=\"HANDLER\"><block type=\"array_push\" id=\"|H;v+H2;2?[9O+9k0u%@\"><value name=\"list\"><block type=\"variables_get\" id=\"vBM.c(}5b8S|}8RYLQDA\"><field name=\"VAR\" id=\"~xH2)7b3]sy2X{yK*ogH\">list</field></block></value><value name=\"value\"><shadow type=\"math_number\" id=\"?{32Zcxl)AgyryD*j!Vi\"><field name=\"NUM\">0</field></shadow></value><next><block type=\"device_show_leds\" id=\"PHPn~m:uMpZ#@oK8Pgi#\"><field name=\"LEDS\">`\n . . . . . \n . . . . . \n . . # . . \n . . . . . \n . . . . .\n `</field><next><block type=\"music_playable_play\" id=\"FK;=PMVP])DWcWQx50k$\"><field name=\"playbackMode\">music.PlaybackMode.InBackground</field><value name=\"toPlay\"><shadow type=\"music_string_playable\" id=\"esZq8oShqV34`}w`Y9a_\"></shadow><block type=\"music_tone_playable\" id=\"~Ia7)_)j^=Be{(_.daw4\"><value name=\"note\"><shadow type=\"device_note\" id=\"UEDIJh1c:J!70BtRd-,d\"><field name=\"name\">494</field></shadow></value><value name=\"duration\"><shadow type=\"device_beat\" id=\"!jO0*r#FPz@2n4EPhAnt\"><field name=\"fraction\">BeatFraction.Eighth</field></shadow></value></block></value><next><block type=\"device_pause\" id=\"|zOviVD(dJ4!h*mu;@IQ\"><value name=\"pause\"><shadow type=\"timePicker\" id=\"P|ysX~~0T/@ryqHV~g~-\"><field name=\"ms\">200</field></shadow></value><next><block type=\"device_clear_display\" id=\"Sg.XG7K5rx#1jZjz?QUT\"></block></next></block></next></block></next></block></next></block></statement></block><block type=\"device_button_event\" id=\"=CBP4qydV4+16yBUG@5y\" x=\"1079\" y=\"0\"><field name=\"NAME\">Button.B</field><statement name=\"HANDLER\"><block type=\"array_push\" id=\"]6RPEVpSGFel?%*4|b,u\"><value name=\"list\"><block type=\"variables_get\" id=\"*0wj`15+[I)i1([afVmI\"><field name=\"VAR\" id=\"~xH2)7b3]sy2X{yK*ogH\">list</field></block></value><value name=\"value\"><shadow type=\"math_number\" id=\"7|Up~w7I+1U@$LY_XXUr\"><field name=\"NUM\">1</field></shadow></value><next><block type=\"device_show_leds\" id=\"S1^?c2tOKZtY]RxDL[*F\"><field name=\"LEDS\">`\n . . . . . \n . . . . . \n . # # # . \n . . . . . \n . . . . .\n `</field><next><block type=\"music_playable_play\" id=\"-d2DbMZ:Uduf[;E9tX^j\"><field name=\"playbackMode\">music.PlaybackMode.InBackground</field><value name=\"toPlay\"><shadow type=\"music_string_playable\" id=\"6%1;#h-bG~NtX/1=CR]L\"></shadow><block type=\"music_tone_playable\" id=\"CELDK]2@{9$*tl1YR=ck\"><value name=\"note\"><shadow type=\"device_note\" id=\"bH[!t9Zah=HuI+;UJViI\"><field name=\"name\">494</field></shadow></value><value name=\"duration\"><shadow type=\"device_beat\" id=\"w`r3H91H(n*;:o0RINxb\"><field name=\"fraction\">BeatFraction.Half</field></shadow></value></block></value><next><block type=\"device_pause\" id=\"q8YHTdX2M$kLX^YA:wMK\"><value name=\"pause\"><shadow type=\"timePicker\" id=\"kyf9-)UC:}q-]Kg!A_2{\"><field name=\"ms\">200</field></shadow></value><next><block type=\"device_clear_display\" id=\"KGH25/}~*Un#P;fjU;hI\"></block></next></block></next></block></next></block></next></block></statement></block><block type=\"device_forever\" id=\"~2tjJLc{v}x!-=004+S~\" x=\"2144\" y=\"0\"></block><block type=\"device_button_event\" id=\"A{78f=cHbgi.9|$E.]2b\" x=\"1866\" y=\"119\"><field name=\"NAME\">Button.AB</field><statement name=\"HANDLER\"><block type=\"device_print_message\" id=\"}7K:Kz,[1)|e@cib[NWE\"><value name=\"text\"><shadow type=\"text\" id=\"[zJ,UM~7MX~a-HM0aFO9\"><field name=\"TEXT\"></field></shadow><block type=\"function_call_output\" id=\"oHW?_O`X|yN==cUZEw_@\"><mutation name=\"morseToChar\" functionid=\"DZo0r?4H?DaTMw9beQ/T\"><arg name=\"morse\" id=\"fkv4pkfnnso2o5iyo4nz\" type=\"Array\"></arg></mutation><value name=\"fkv4pkfnnso2o5iyo4nz\"><block type=\"variables_get\" id=\"NE^XdB{HO=N~e%s{|H|v\"><field name=\"VAR\" id=\"~xH2)7b3]sy2X{yK*ogH\">list</field></block></value></block></value><next><block type=\"radio_datagram_send_string\" id=\"Ofeby`q%Vt9c6t}zsGWc\"><value name=\"msg\"><shadow type=\"text\" id=\"o3{Pe_Y4H+b%z8UZM7}/\"><field name=\"TEXT\"></field></shadow><block type=\"function_call_output\" id=\"*]+jVI8^AtuyiWEZB,p8\"><mutation name=\"morseToChar\" functionid=\"DZo0r?4H?DaTMw9beQ/T\"><arg name=\"morse\" id=\"fkv4pkfnnso2o5iyo4nz\" type=\"Array\"></arg></mutation><value name=\"fkv4pkfnnso2o5iyo4nz\"><block type=\"variables_get\" id=\"2+w[z00_lS:ASMnJO0y3\"><field name=\"VAR\" id=\"~xH2)7b3]sy2X{yK*ogH\">list</field></block></value></block></value><next><block type=\"variables_set\" id=\"5b.4l|GWeqp)^#@R0ggw\"><field name=\"VAR\" id=\"~xH2)7b3]sy2X{yK*ogH\">list</field><value name=\"VALUE\"><shadow type=\"math_number\" id=\"HsdP}_Zo]kSQDj8}GhPW\"><field name=\"NUM\">0</field></shadow><block type=\"lists_create_with\" id=\"$KRQD*B]*wO+|MJ3O)9f\"><mutation items=\"0\" horizontalafter=\"3\"></mutation></block></value></block></next></block></next></block></statement></block><block type=\"radio_on_string_drag\" id=\"l*Ll:A`#m60AX/R49jWz\" x=\"502\" y=\"583\"><value name=\"HANDLER_DRAG_PARAM_receivedString\"><block type=\"argument_reporter_string\" id=\"9678OkLLbFrjd`Q-u1U6\"><mutation duplicateondrag=\"true\"></mutation><field name=\"VALUE\">receivedString</field></block></value><statement name=\"HANDLER\"><block type=\"device_print_message\" id=\"`36K_WUfpx}hP1]wFF~y\"><value name=\"text\"><block type=\"argument_reporter_string\" id=\")aefhL]X*8/^DQsK:2?X\"><field name=\"VALUE\">receivedString</field></block></value></block></statement></block><block type=\"function_definition\" id=\"i(2yiYkYz#hM1nM~eX7)\" x=\"465\" y=\"1689\"><mutation name=\"morseToChar\" functionid=\"DZo0r?4H?DaTMw9beQ/T\"><arg name=\"morse\" id=\"fkv4pkfnnso2o5iyo4nz\" type=\"Array\"></arg></mutation><field name=\"function_name\">morseToChar</field><value name=\"fkv4pkfnnso2o5iyo4nz\"><block type=\"argument_reporter_array\" id=\"TQ,8DB!-54i}fV%%_jOu\"><mutation duplicateondrag=\"true\"></mutation><field name=\"VALUE\">morse</field></block></value><statement name=\"STACK\"><block type=\"typescript_statement\" id=\"79?*V[Wf|y@d{uhS^=:y\"><mutation xmlns=\"http://www.w3.org/1999/xhtml\" line0=\"let char = Object.keys(MORSE_CODE).find(key => JSON.stringify(MORSE_CODE[key]) == JSON.stringify(morse))\" numlines=\"1\" declaredvars=\"char\"></mutation><next><block type=\"controls_if\" id=\"E=ZmU1X$gzlIw+8jMu,E\"><value name=\"IF0\"><shadow type=\"logic_boolean\" id=\"7AVxZqoCoygmK^p?KmuU\"><field name=\"BOOL\">TRUE</field></shadow><block type=\"logic_compare\" id=\"8z5.@,`MFxwmsHBb,ekg\"><field name=\"OP\">EQ</field><value name=\"A\"><shadow type=\"math_number\" id=\"=~IO=k:KV`C5ZDxDP#Y/\"><field name=\"NUM\">0</field></shadow><block type=\"variables_get\" id=\"Rash9Xgy.BUq2?J;VzrL\"><field name=\"VAR\" id=\"K)X^~uL/`IN1[PBBRt[Z\">char</field></block></value><value name=\"B\"><shadow type=\"math_number\" id=\"aAj%Lt~^XQ/j|lZ{7Xfx\"><field name=\"NUM\">0</field></shadow><block type=\"typescript_expression\" id=\"uZMV9ao@Qz0J1M/p?B}U\"><field name=\"EXPRESSION\">undefined</field></block></value></block></value><statement name=\"DO0\"><block type=\"function_return\" id=\"/%owqVh~w8I4,?.$[%qM\"><mutation xmlns=\"http://www.w3.org/1999/xhtml\" no_return_value=\"false\"></mutation><value name=\"RETURN_VALUE\"><shadow type=\"math_number\" id=\"Ir1(ly]RL)jLlW:Axn()\"><field name=\"NUM\">0</field></shadow><block type=\"text\" id=\"9dDS#m7m/_V8m_XoA534\"><field name=\"TEXT\"> </field></block></value></block></statement><next><block type=\"function_return\" id=\"ppcS,FYz/*HM0]p_sqwg\"><mutation xmlns=\"http://www.w3.org/1999/xhtml\" no_return_value=\"false\"></mutation><value name=\"RETURN_VALUE\"><shadow type=\"math_number\" id=\"8qQP;WQV$heVS#8QD=*#\"><field name=\"NUM\">0</field></shadow><block type=\"variables_get\" id=\"xmTH4RXG6=:}$]q}[kbQ\"><field name=\"VAR\" id=\"K)X^~uL/`IN1[PBBRt[Z\">char</field></block></value></block></next></block></next></block></statement></block><block type=\"function_definition\" id=\"#HFkc(c)SLk-@cdO6RGO\" x=\"1458\" y=\"1677\"><mutation name=\"charToMorse\" functionid=\"c(syow,kueThchIXqe}j\"><arg name=\"char\" id=\"jd2u8214ukacefxxz9dn\" type=\"string\"></arg></mutation><field name=\"function_name\">charToMorse</field><value name=\"jd2u8214ukacefxxz9dn\"><block type=\"argument_reporter_string\" id=\"r#O{{h4SW0Cd|Jm:DZy[\"><mutation duplicateondrag=\"true\"></mutation><field name=\"VALUE\">char</field></block></value><statement name=\"STACK\"><block type=\"function_return\" id=\"O-adwe)tMSL`pA0G^`o$\"><mutation xmlns=\"http://www.w3.org/1999/xhtml\" no_return_value=\"false\"></mutation><value name=\"RETURN_VALUE\"><shadow type=\"math_number\" id=\"GnDvdjh7~?YZ$pGfQe*U\"><field name=\"NUM\">0</field></shadow><block type=\"lists_index_get\" id=\"B@wx~8^]P%bhKAwuwaTV\"><value name=\"LIST\"><block type=\"variables_get\" id=\"Fj(hf!kfcDcs]R}Y^3fi\"><field name=\"VAR\" id=\"KQ;GE9bR^m|c2gC_j?%/\">MORSE_CODE</field></block></value><value name=\"INDEX\"><shadow type=\"math_number\" id=\"kd^E.At(FW_aW{4;LBKE\"><field name=\"NUM\">0</field></shadow><block type=\"typescript_expression\" id=\"bn-xGgC+*UG?yHkI5g6@\"><field name=\"EXPRESSION\">char.toUpperCase()</field></block></value></block></value></block></statement></block></xml>","main.ts":"","README.md":"\n> Open this page at [https://lemonyte.github.io/morse-code/](https://lemonyte.github.io/morse-code/)\n\n## Use as Extension\n\nThis repository can be added as an **extension** in MakeCode.\n\n* open [https://makecode.microbit.org/](https://makecode.microbit.org/)\n* click on **New Project**\n* click on **Extensions** under the gearwheel menu\n* search for **https://github.com/lemonyte/morse-code** and import\n\n## Edit this project\n\nTo edit this repository in MakeCode.\n\n* open [https://makecode.microbit.org/](https://makecode.microbit.org/)\n* click on **Import** then click on **Import URL**\n* paste **https://github.com/lemonyte/morse-code** and click import\n\n#### Metadata (used for search, rendering)\n\n* for PXT/microbit\n<script src=\"https://makecode.com/gh-pages-embed.js\"></script><script>makeCodeRender(\"{{ site.makecode.home_url }}\", \"{{ site.github.owner_name }}/{{ site.github.repository_name }}\");</script>\n","pxt.json":"{\n \"name\": \"morse-code\",\n \"description\": \"\",\n \"dependencies\": {\n \"core\": \"*\",\n \"radio\": \"*\",\n \"microphone\": \"*\"\n },\n \"files\": [\n \"main.blocks\",\n \"main.ts\",\n \"README.md\"\n ],\n \"testFiles\": [\n \"test.ts\"\n ],\n \"targetVersions\": {\n \"target\": \"7.0.51\",\n \"targetId\": \"microbit\"\n },\n \"supportedTargets\": [\n \"microbit\"\n ],\n \"preferredEditor\": \"blocksprj\"\n}\n","test.ts":"// tests go here; this will not be compiled when this package is used as an extension.\n"}}],"shares":[],"lastSaveTime":1730883945066}