一些板载显示修改
This commit is contained in:
@@ -72,6 +72,20 @@ export const esp32_music_play_list = {
|
||||
}
|
||||
}
|
||||
|
||||
export const backstage_esp32_music_play_list = {
|
||||
init: function () {
|
||||
this.setColour(ACTUATOR_EXTERN_HUE);
|
||||
this.appendValueInput('SUB')
|
||||
this.appendValueInput('LIST')
|
||||
.appendField(Blockly.Msg.MIXLY_BACKSTAGE + Blockly.Msg.MIXLY_ESP32_MUSIC_PLAY_LISTS)
|
||||
this.setPreviousStatement(true);
|
||||
this.setNextStatement(true);
|
||||
this.setInputsInline(true);
|
||||
this.setTooltip(Blockly.Msg.MIXLY_BACKSTAGE + Blockly.Msg.MIXLY_ESP32_MUSIC_PLAY_LISTS);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
export const esp32_music_set_tempo_extern = {
|
||||
init: function () {
|
||||
this.setColour(ACTUATOR_EXTERN_HUE);
|
||||
|
||||
@@ -349,8 +349,13 @@ export const OPEN_IMAGE = {
|
||||
['180','180'],
|
||||
['270','270']
|
||||
]),'angle');
|
||||
this.appendValueInput("w")
|
||||
.appendField(Blockly.Msg.MIXLY_Enlarge_and_scale_to)
|
||||
this.appendValueInput("h")
|
||||
.appendField(Blockly.Msg.MIXLY_High_zoom_level_to)
|
||||
this.setOutput(true);
|
||||
this.setInputsInline(true);
|
||||
this.setTooltip(Blockly.Msg.MIXLY_OPEN_IMAGE_TOOLTIP);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -1607,6 +1607,58 @@ export const onboard_tft_show_texts = {
|
||||
}
|
||||
};
|
||||
|
||||
export const onboard_tft_show_qrcode = {
|
||||
init: function () {
|
||||
this.setColour(DISPLAY_ONBOARD_HUE);
|
||||
this.appendValueInput('direct')
|
||||
.appendField(Blockly.Msg.OLED_BITMAP)
|
||||
.appendField(Blockly.Msg.MIXLY_QR_CODE);
|
||||
if (JSFuncs.getPlatform() === 'Python ESP32-S3') {
|
||||
this.appendValueInput('boolean')
|
||||
.appendField( Blockly.Msg.MIXLY_synchronize);
|
||||
}
|
||||
this.setPreviousStatement(true);
|
||||
this.setNextStatement(true);
|
||||
this.setInputsInline(true);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
export const onboard_tft_show_qrcode_details = {
|
||||
init: function () {
|
||||
this.setColour(DISPLAY_ONBOARD_HUE);
|
||||
this.appendValueInput('data')
|
||||
.appendField(Blockly.Msg.OLED_BITMAP)
|
||||
.appendField(Blockly.Msg.MIXLY_QR_CODE);
|
||||
this.appendValueInput("x")
|
||||
.setCheck(Number)
|
||||
.appendField('x');
|
||||
this.appendValueInput("y")
|
||||
.setCheck(Number)
|
||||
.appendField('y');
|
||||
this.appendValueInput("size")
|
||||
.setCheck(Number)
|
||||
.appendField(Blockly.Msg.MIXLY_MICROBIT_JS_NUMBER);
|
||||
this.appendDummyInput("")
|
||||
.appendField(Blockly.Msg.MIXLY_ERROR_RATE)
|
||||
.appendField(new Blockly.FieldDropdown([
|
||||
["0","7%"],
|
||||
["1","15%"],
|
||||
["2","25%"],
|
||||
["3","30"]
|
||||
]),"correct");
|
||||
this.appendValueInput('VAR')
|
||||
.appendField(Blockly.Msg.HTML_COLOUR);
|
||||
if (JSFuncs.getPlatform() === 'Python ESP32-S3') {
|
||||
this.appendValueInput('boolean')
|
||||
.appendField( Blockly.Msg.MIXLY_synchronize);
|
||||
}
|
||||
this.setPreviousStatement(true, null);
|
||||
this.setNextStatement(true, null);
|
||||
this.setInputsInline(true);
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* @deprecated To be removed in the future
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user