turtlestitch/libraries/signada.xml

1 wiersz
15 KiB
XML

<blocks app="Snap! 7dev, https://snap.berkeley.edu" version="2"><block-definition s="🤖 connect to %&apos;ip&apos;" type="command" category="other"><header></header><code></code><translations>ca:🤖 connecta&apos;t a _&#xD;</translations><inputs><input type="%s">192.168.4.1</input></inputs><script><block s="doApplyExtension"><l>src_load(url)</l><list><l>libraries/signada.js</l></list></block><custom-block s="🤖 disconnect"></custom-block><block s="doApplyExtension"><l>sgd_connect(ip)</l><list><block var="ip"/></list></block></script></block-definition><block-definition s="🤖 disconnect" type="command" category="other"><header></header><code></code><translations>ca:🤖 desconnecta&apos;t&#xD;</translations><inputs></inputs><script><block s="doIf"><custom-block s="🤖 connected"></custom-block><script><block s="doApplyExtension"><l>sgd_disconnect()</l><list><l></l></list></block></script></block></script></block-definition><block-definition s="🤖 connected" type="predicate" category="other"><header></header><code></code><translations>ca:🤖 connectat&#xD;</translations><inputs></inputs><script><block s="doReport"><block s="reportApplyExtension"><l>sgd_connected()</l><list></list></block></block></script></block-definition><block-definition s="play note %&apos;notename&apos; octave %&apos;octave&apos; for %&apos;ms&apos; ms" type="command" category="sound"><header></header><code></code><translations>ca:toca la nota _ a l&apos;octava _ durant _ ms&#xD;</translations><inputs><input type="%txt">C<options>C&#xD;C#&#xD;D&#xD;D#&#xD;E&#xD;F&#xD;F#&#xD;G&#xD;G#&#xD;A&#xD;A#&#xD;B</options></input><input type="%n">1<options>1&#xD;2&#xD;3&#xD;4&#xD;5</options></input><input type="%n">100</input></inputs><script><block s="doDeclareVariables"><list><l>a</l></list></block><block s="doSetVar"><l>a</l><block s="reportApplyExtension"><l>sgd_call(blockname, params, defaultresponse)</l><list><l>play tone</l><block s="reportNewList"><list><block var="notename"/><block var="octave"/><block var="ms"/></list></block><l>0</l></list></block></block></script></block-definition><block-definition s="button %&apos;buttonname&apos;" type="predicate" category="sensing"><header></header><code></code><translations>ca:botó _&#xD;</translations><inputs><input type="%s" readonly="true"><options>🆗&#xD;&#xD;➡️&#xD;⬆️&#xD;⬇️&#xD;⬅️</options></input></inputs><script><block s="doReport"><block s="reportApplyExtension"><l>sgd_call(blockname, params, defaultresponse)</l><list><block s="reportJoinWords"><list><block s="reportListItem"><block s="reportListIndex"><block var="buttonname"/><block s="reportNewList"><list><l>🆗</l><l></l><l>➡️</l><l>⬆️</l><l>⬇️</l><l>⬅️</l></list></block></block><block s="reportNewList"><list><l>OK</l><l>cancel</l><l>right</l><l>up</l><l>down</l><l>left</l></list></block></block><l> button</l></list></block><l></l><block s="reportBoolean"><l><bool>false</bool></l></block></list></block></block></script></block-definition><block-definition s="set LED display $nl %&apos;i1&apos; %&apos;i2&apos; %&apos;i3&apos; %&apos;i4&apos; %&apos;i5&apos; $nl %&apos;i6&apos; %&apos;i7&apos; %&apos;i8&apos; %&apos;i9&apos; %&apos;i10&apos; $nl %&apos;i11&apos; %&apos;i12&apos; %&apos;i13&apos; %&apos;i14&apos; %&apos;i15&apos; $nl %&apos;i16&apos; %&apos;i17&apos; %&apos;i18&apos; %&apos;i19&apos; %&apos;i20&apos; $nl %&apos;i21&apos; %&apos;i22&apos; %&apos;i23&apos; %&apos;i24&apos; %&apos;i25&apos;" type="command" category="pen"><header></header><code></code><translations>ca:dibuixa a la pantalla _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _&#xD;</translations><inputs><input type="%b">false</input><input type="%b">false</input><input type="%b">false</input><input type="%b">false</input><input type="%b">false</input><input type="%b">false</input><input type="%b">true</input><input type="%b">false</input><input type="%b">true</input><input type="%b">false</input><input type="%b">false</input><input type="%b">false</input><input type="%b">false</input><input type="%b">false</input><in