-
Notifications
You must be signed in to change notification settings - Fork 0
/
i2c_expansion_board_mixly.mix
1 lines (1 loc) · 4.37 KB
/
i2c_expansion_board_mixly.mix
1
<xml version="Mixly 2.0 rc3" board="Arduino AVR@Arduino/Genuino Uno"><block type="base_setup" id="2]TK,LtT=k}TAtfP/QbY" x="-1367" y="-923"><statement name="DO"><block type="serial_begin" id="LiU$B]Ym`)0[^{a}{:f4"><field name="serial_select">Serial</field><value name="CONTENT"><shadow type="math_number" id="hYD(b,hI1`!srXPXPc^D"><field name="NUM">9600</field></shadow></value><next><block type="nulllab_init_i2c_expansion_board" id="Qj]rC^X_TUgTWJmCl63A"><field name="nulllab_i2cBoard">myI2CExpansionBoard</field><value name="nulllab_i2cAddr"><shadow type="math_number" id="M+Hb-jj+$$HiP0UgfM[L"><field name="NUM">0x24</field></shadow></value><next><block type="nulllab_set_i2c_expansion_board_mode" id="R_ONYUy-:8=t*,.5l;]-"><field name="nulllab_i2cBoard">myI2CExpansionBoard</field><field name="nulllab_pin">I2cExpansionBoard::kGpioPinE0</field><field name="nulllab_mode">I2cExpansionBoard::kGpioModeOutput</field><next><block type="nulllab_set_i2c_expansion_board_level" id="IefH0V4Vb(TnBnA(VfKP"><field name="nulllab_i2cBoard">myI2CExpansionBoard</field><field name="nulllab_pin">I2cExpansionBoard::kGpioPinE0</field><field name="nulllab_level">LOW</field><next><block type="nulllab_set_i2c_expansion_board_mode" id="e/KVmRLqEC[m.wmyT?s4"><field name="nulllab_i2cBoard">myI2CExpansionBoard</field><field name="nulllab_pin">I2cExpansionBoard::kGpioPinE1</field><field name="nulllab_mode">I2cExpansionBoard::kGpioModeAdc</field><next><block type="nulllab_set_i2c_expansion_board_mode" id="fKY~g+B=+hE])^K-Eo]M"><field name="nulllab_i2cBoard">myI2CExpansionBoard</field><field name="nulllab_pin">I2cExpansionBoard::kGpioPinE0</field><field name="nulllab_mode">I2cExpansionBoard::kGpioModeInputPullDown</field></block></next></block></next></block></next></block></next></block></next></block></statement></block><block type="serial_print" id="V+|=(J^|NSV2U64x@PcH" x="-1365" y="-647"><field name="serial_select">Serial</field><field name="new_line">println</field><value name="CONTENT"><block type="text_join" id="/GV3^X@LqioL58Sr62Vs"><value name="A"><shadow type="text" id="Vld^|L6dIKG$Y:*FaJcy"><field name="TEXT"> E0 digital data: </field></shadow></value><value name="B"><shadow type="text" id="}RUIN(K8UkqZ#{!zF+Im"><field name="TEXT">Mixly</field></shadow><block type="nulllab_get_i2c_expansion_board_level" id="h5CHAW3WCgqW:BYPZOGg"><field name="nulllab_i2cBoard">myI2CExpansionBoard</field><field name="nulllab_pin">I2cExpansionBoard::kGpioPinE0</field></block></value></block></value><next><block type="serial_print" id="h$~^MTnO8Lj_eSObzn2W"><field name="serial_select">Serial</field><field name="new_line">println</field><value name="CONTENT"><block type="text_join" id="bJT5?u@GmRZd~q~ifE;5"><value name="A"><shadow type="text" id="d`veAk?l^+lKa{_aH6;v"><field name="TEXT"> E1 analog data: </field></shadow></value><value name="B"><shadow type="text" id="Vq4v*.pY1d!3Cq?I$#An"><field name="TEXT">Mixly</field></shadow><block type="nulllab_get_i2c_expansion_board_adc" id="@`7A;+-3f9zz(Z*kH,x_"><field name="nulllab_i2cBoard">myI2CExpansionBoard</field><field name="nulllab_pin">I2cExpansionBoard::kGpioPinE1</field></block></value></block></value><next><block type="controls_delay" id=";kr}9nNzjauf@C6MMj2z"><field name="UNIT">delay</field><value name="DELAY_TIME"><shadow type="math_number" id="_lwHw$h/oUT6|ez-U-bS"><field name="NUM">200</field></shadow></value></block></next></block></next></block></xml><code>I2luY2x1ZGUgPGkyY19leHBhbnNpb25fYm9hcmQuaD4KSTJjRXhwYW5zaW9uQm9hcmQgbXlJMkNFeHBhbnNpb25Cb2FyZCgweDI0KTsKCnZvaWQgc2V0dXAoKXsKICBTZXJpYWwuYmVnaW4oOTYwMCk7CiAgbXlJMkNFeHBhbnNpb25Cb2FyZC5TZXRHcGlvTW9kZShJMmNFeHBhbnNpb25Cb2FyZDo6a0dwa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