From e13651c4ab3d9f732950c7438fa51fa10c185c37 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=8E=8B=E7=AB=8B=E5=B8=AE?= <3294713004@qq.com>
Date: Tue, 13 Aug 2024 13:48:43 +0800
Subject: [PATCH] =?UTF-8?q?Fix:=20=E4=BF=AE=E5=A4=8Darduino=E6=9D=BF?=
=?UTF-8?q?=E5=8D=A1=E4=B8=8B=E5=9B=BE=E5=BD=A2=E5=9D=97=E6=98=BE=E7=A4=BA?=
=?UTF-8?q?=E5=BC=82=E5=B8=B8?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
boards/default/arduino_avr/index.xml | 2 +-
.../{main.b1e92ec9.css => main.08427a24.css} | 0
boards/default/arduino_esp32/index.xml | 2 +-
.../{main.8fa91583.css => main.39e10414.css} | 0
boards/default/arduino_esp8266/index.xml | 2 +-
.../{main.9297710f.css => main.c5a7b741.css} | 0
.../arduino_avr/blocks/communicate.js | 23 ++++++++++++--
.../arduino_avr/blocks/ethernet.js | 20 +++++++++++--
common/msg/blockly/zh-hant.js | 30 +++++++++++++++++++
9 files changed, 71 insertions(+), 8 deletions(-)
rename boards/default/arduino_avr/styles/{main.b1e92ec9.css => main.08427a24.css} (100%)
rename boards/default/arduino_esp32/styles/{main.8fa91583.css => main.39e10414.css} (100%)
rename boards/default/arduino_esp8266/styles/{main.9297710f.css => main.c5a7b741.css} (100%)
diff --git a/boards/default/arduino_avr/index.xml b/boards/default/arduino_avr/index.xml
index 94877c9d..fb9dc841 100644
--- a/boards/default/arduino_avr/index.xml
+++ b/boards/default/arduino_avr/index.xml
@@ -1 +1 @@
-0010000000100011015001100010001100011001item++item12997millis11001100110011000helloaHelloMixlyABC123Mixlyysubstring036.6662StringStringsQStringsubstringsubstringsubstring0xff0000223a0hellohello000intmylist012123234array22{0,0},{0,0}array000array00array9600Serialprintln0a23220x77100003950100000x5A2345671201992230234A4A5800202011Jan/01/202020201112:34:56800DATE234567894800WHILElocationSeriallocation.latSeriallocation.lng45610054100100200215002121001012341001010100045452454545201000mySerial1011mySerial9600myPlayermySerial50015myPlayer0DFPLAYER_EQ_NORMALmyPlayer2DFPLAYER_DEVICE_SD1111myPlayerreadFileCounts2DFPLAYER_DEVICE_SD1#ff000000024220210002102552552220220clearabcd20234512300x2778910111211mylcd011clear910833ccff0000#000000TRUESTHeiti16米思齐0016480xFCDF33ccff02033ccff02033ccff12340000bitmap1643233ccff11152033ccff113033ccff11102033ccff111020333ccff3030633ccff1455453384333ccff0x3CSSD1306_128X64_NONAMEU8G2_R01098U8G2_R010U8G2_R0234567891011page10201234bitmap96TRUE122STHeiti164816米思齐0012864bitmap110020002064321115201130111020111020330306303061514554533843911111111Mixly300Mixly05ir_item0SerialprintlnHEXir_item30x89ABCDEF3233380800000000array1howMany10010AASPDRSPDR1013111291mylist161mylist164fileName.txtfileName.txtfileName.txtfileName.txthello worldTRUE000itemd9efdd0413ec4b74ab0057a0b8675654nd9efdd0413ec4b74ab0057a0b8675654wifi-ssidwifi-pass59d948d79fe642aab95c1577b1ad419d10V0Serialvpin_value1000V00#ff00000#ff0000example@blynk.ccSubjectContentNotifyV0Serialterminal_textHello,World!V0SerialhourSerialminuteSerialsecondV000923http://yourvideostream.urlTest rowhelloV0SerialindexSerialselectedV0SerialindexFromSerialindexTo0NameJohn0NameJohn000V0V00BLYNK_CONNECTEDV0n2KlfPGDyjDBluNi1G9DG5OEjqDT996L00BLYNK_CONNECTED10V0actionStringEQactionplayplay();45EQactionstoppause();45EQactionnextnext();45EQactionprevprev();45V0SeriallxV0SerialxSerialySerialzV0SerialxSerialySerialzV0
\ No newline at end of file
+0010000000100011015001100010001100011001item++item12997millis11001100110011000helloaHelloMixlyABC123Mixlyysubstring036.6662StringStringsQStringsubstringsubstringsubstring0xff0000223a0hellohello000intmylist012123234array22{0,0},{0,0}array000array00array9600Serialprintln0a23220x77100003950100000x5A2345671201992230234A4A5800202011Jan/01/202020201112:34:56800DATE234567894800WHILElocationSeriallocation.latSeriallocation.lng45610054100100200215002121001012341001010100045452454545201000mySerial1011mySerial9600myPlayermySerial50015myPlayer0DFPLAYER_EQ_NORMALmyPlayer2DFPLAYER_DEVICE_SD1111myPlayerreadFileCounts2DFPLAYER_DEVICE_SD1#ff000000024220210002102552552220220clearabcd20234512300x2778910111211mylcd011clear910833ccff0000#000000TRUESTHeiti16米思齐0016480xFCDF33ccff02033ccff02033ccff12340000bitmap1643233ccff11152033ccff113033ccff11102033ccff111020333ccff3030633ccff1455453384333ccff0x3CSSD1306_128X64_NONAMEU8G2_R01098U8G2_R010U8G2_R0234567891011page10201234bitmap96TRUE122STHeiti164816米思齐0012864bitmap110020002064321115201130111020111020330306303061514554533843911111111Mixly300Mixly05ir_item0SerialprintlnHEXir_item30x89ABCDEF3233380800000000array1howMany10010AASPDRSPDR1013111291mylist161mylist164fileName.txtfileName.txtfileName.txtfileName.txthello worldTRUE000itemd9efdd0413ec4b74ab0057a0b8675654nd9efdd0413ec4b74ab0057a0b8675654wifi-ssidwifi-pass59d948d79fe642aab95c1577b1ad419d10V0Serialvpin_value1000V00#ff00000#ff0000example@blynk.ccSubjectContentNotifyV0Serialterminal_textHello,World!V0SerialhourSerialminuteSerialsecondV000923http://yourvideostream.urlTest rowhelloV0SerialindexSerialselectedV0SerialindexFromSerialindexTo0NameJohn0NameJohn000V0V00BLYNK_CONNECTEDV0n2KlfPGDyjDBluNi1G9DG5OEjqDT996L00BLYNK_CONNECTED10V0actionStringEQactionplayplay();45EQactionstoppause();45EQactionnextnext();45EQactionprevprev();45V0SeriallxV0SerialxSerialySerialzV0SerialxSerialySerialzV0
\ No newline at end of file
diff --git a/boards/default/arduino_avr/styles/main.b1e92ec9.css b/boards/default/arduino_avr/styles/main.08427a24.css
similarity index 100%
rename from boards/default/arduino_avr/styles/main.b1e92ec9.css
rename to boards/default/arduino_avr/styles/main.08427a24.css
diff --git a/boards/default/arduino_esp32/index.xml b/boards/default/arduino_esp32/index.xml
index 56217134..2f03845e 100644
--- a/boards/default/arduino_esp32/index.xml
+++ b/boards/default/arduino_esp32/index.xml
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/boards/default/arduino_esp32/styles/main.8fa91583.css b/boards/default/arduino_esp32/styles/main.39e10414.css
similarity index 100%
rename from boards/default/arduino_esp32/styles/main.8fa91583.css
rename to boards/default/arduino_esp32/styles/main.39e10414.css
diff --git a/boards/default/arduino_esp8266/index.xml b/boards/default/arduino_esp8266/index.xml
index 51167cec..100d30f9 100644
--- a/boards/default/arduino_esp8266/index.xml
+++ b/boards/default/arduino_esp8266/index.xml
@@ -1 +1 @@
-01000000010001101110001000111001item++item12997millis11001100110011000helloaHelloMixlyABC123Mixlyysubstring036.6662StringStringsQStringsubstringsubstringsubstring0xff0000223a0hellohello000intmylist012123234array22{0,0},{0,0}array000array00array96000a0x77100003950100000x5A2345671201992240234SDASCL800202011Jan/01/202020201112:34:568000245121314154800WHILElocationSeriallocation.latSeriallocation.lng45610054100100100001500121001012341001010100045452454545208830801000mySerial1011mySerial9600myPlayermySerial50015myPlayer0DFPLAYER_EQ_NORMALmyPlayer2DFPLAYER_DEVICE_SD1111myPlayerreadFileCounts2DFPLAYER_DEVICE_SD1#ff000000042020100010255255202020clearabcd20234530012300x270245121311mylcd011clear0x3CSSD1306_128X64_NONAMEU8G2_R01098U8G2_R010page1timR08_tr0201234bitmap96TRUE122STHeiti16hz_up0hz_left04816TRUE米思齐0012864bitmap1100200020643211152011301110201110203303063030615145545338431211SDASCL111111Mixly300Mixly05ir_item0SerialprintlnHEXir_item32021mylist161mylist164fileName.txtfileName.txtfileName.txtfileName.txthello worldTRUE000itemssidpasswordntp1.aliyun.com860030:AE:A4:58:9D:7CrandomMixly1100SerialSent with successSerialError sending the dataSerialmessagehttp://jsonplaceholder.typicode.com/posts/1SerialRequest_resultSerialInvalid response!http://jsonplaceholder.typicode.com/posts/1{\"name\":\"Mixly\"}SerialRequest_resultSerialInvalid response!0d9efdd0413ec4b74ab0057a0b8675654wifi-ssidwifi-passd9efdd0413ec4b74ab0057a0b8675654d9efdd0413ec4b74ab0057a0b8675654V0Serialvpin_valueV01000V00#ff00000#ff0000example@blynk.ccSubjectContentNotifyV0Serialterminal_textHello,World!V0SerialhourSerialminuteSerialsecondV000923http://yourvideostream.urlTest rowhelloV0SerialindexSerialselectedV0SerialindexFromSerialindexTo0NameJohn0NameJohn000BLYNK_CONNECTEDV0n2KlfPGDyjDBluNi1G9DG5OEjqDT996L00BLYNK_CONNECTED10V0actionStringEQactionplayplay();45EQactionstoppause();45EQactionnextnext();45EQactionprevprev();45V0SeriallxV0SerialxSerialySerialzV0SerialxSerialySerialzV039.98.114.1221883IDsiotsiot120Topic_0Serialmixio.mixly.cn188312345678@qq.comd86d2e60b813590963e2641b44945154testtextSerialprintlnmqtt_dataHellotext
\ No newline at end of file
+01000000010001101110001000111001item++item12997millis11001100110011000helloaHelloMixlyABC123Mixlyysubstring036.6662StringStringsQStringsubstringsubstringsubstring0xff0000223a0hellohello000intmylist012123234array22{0,0},{0,0}array000array00array96000a0x77100003950100000x5A2345671201992240234SDASCL800202011Jan/01/202020201112:34:568000245121314154800WHILElocationSeriallocation.latSeriallocation.lng45610054100100100001500121001012341001010100045452454545208830801000mySerial1011mySerial9600myPlayermySerial50015myPlayer0DFPLAYER_EQ_NORMALmyPlayer2DFPLAYER_DEVICE_SD1111myPlayerreadFileCounts2DFPLAYER_DEVICE_SD1#ff000000042020100010255255202020clearabcd20234530012300x270245121311mylcd011clear0x3CSSD1306_128X64_NONAMEU8G2_R01098U8G2_R010page1timR08_tr0201234bitmap96TRUE122STHeiti16hz_up0hz_left04816TRUE米思齐0012864bitmap1100200020643211152011301110201110203303063030615145545338431211SDASCL111111Mixly300Mixly05ir_item0SerialprintlnHEXir_item32021mylist161mylist164fileName.txtfileName.txtfileName.txtfileName.txthello worldTRUE000itemssidpasswordntp1.aliyun.com860030:AE:A4:58:9D:7CrandomMixly1100SerialSent with successSerialError sending the dataSerialmessagehttp://jsonplaceholder.typicode.com/posts/1SerialRequest_resultSerialInvalid response!http://jsonplaceholder.typicode.com/posts/1{\"name\":\"Mixly\"}SerialRequest_resultSerialInvalid response!0d9efdd0413ec4b74ab0057a0b8675654wifi-ssidwifi-passd9efdd0413ec4b74ab0057a0b8675654d9efdd0413ec4b74ab0057a0b8675654V0Serialvpin_valueV01000V00#ff00000#ff0000example@blynk.ccSubjectContentNotifyV0Serialterminal_textHello,World!V0SerialhourSerialminuteSerialsecondV000923http://yourvideostream.urlTest rowhelloV0SerialindexSerialselectedV0SerialindexFromSerialindexTo0NameJohn0NameJohn000BLYNK_CONNECTEDV0n2KlfPGDyjDBluNi1G9DG5OEjqDT996L00BLYNK_CONNECTED10V0actionStringEQactionplayplay();45EQactionstoppause();45EQactionnextnext();45EQactionprevprev();45V0SeriallxV0SerialxSerialySerialzV0SerialxSerialySerialzV039.98.114.1221883IDsiotsiot120Topic_0Serialmixio.mixly.cn188312345678@qq.comd86d2e60b813590963e2641b44945154testtextSerialprintlnmqtt_dataHellotext
\ No newline at end of file
diff --git a/boards/default/arduino_esp8266/styles/main.9297710f.css b/boards/default/arduino_esp8266/styles/main.c5a7b741.css
similarity index 100%
rename from boards/default/arduino_esp8266/styles/main.9297710f.css
rename to boards/default/arduino_esp8266/styles/main.c5a7b741.css
diff --git a/boards/default_src/arduino_avr/blocks/communicate.js b/boards/default_src/arduino_avr/blocks/communicate.js
index b890266e..f891071b 100644
--- a/boards/default_src/arduino_avr/blocks/communicate.js
+++ b/boards/default_src/arduino_avr/blocks/communicate.js
@@ -32,7 +32,23 @@ export const ir_recv = {
//红外发射模块(NEC)
export const ir_send_nec = {
init: function () {
- var TYPE = [['RC5', 'RC5'], ['RC6', 'RC6'], ['NEC', 'NEC'], ['Sony', 'Sony'], ['Panasonic', 'Panasonic'], ['JVC', 'JVC'], ['SAMSUNG', 'SAMSUNG'], ['Whynter', 'Whynter'], ['AiwaRCT501', 'AiwaRCT501'], ['LG', 'LG'], ['Sanyo', 'Sanyo'], ['Mitsubishi', 'Mitsubishi'], ['DISH', 'DISH'], ['SharpRaw', 'SharpRaw'], ['Denon', 'Denon']];
+ var TYPE = [
+ ['RC5', 'RC5'],
+ ['RC6', 'RC6'],
+ ['NEC', 'NEC'],
+ ['Sony', 'Sony'],
+ ['Panasonic', 'Panasonic'],
+ ['JVC', 'JVC'],
+ ['SAMSUNG', 'SAMSUNG'],
+ ['Whynter', 'Whynter'],
+ ['AiwaRCT501', 'AiwaRCT501'],
+ ['LG', 'LG'],
+ ['Sanyo', 'Sanyo'],
+ ['Mitsubishi', 'Mitsubishi'],
+ ['DISH', 'DISH'],
+ ['SharpRaw', 'SharpRaw'],
+ ['Denon', 'Denon']
+ ];
this.setColour(COMMUNICATE_HUE);
this.appendDummyInput("")
.appendField(Blockly.Msg.MIXLY_IR_SEND_NEC1)
@@ -185,6 +201,7 @@ export const i2c_slave_write_array = {
this.setTooltip(Blockly.Msg.MIXLY_TOOLTIP_I2C_SLAVE_WRITE_ARRAY);
}
};
+
// IIC从机读取字节数
export const i2c_howmany = {
init: function () {
@@ -289,10 +306,10 @@ export const i2c_master_writer = {
.appendField(Blockly.Msg.HTML_VALUE);
this.setPreviousStatement(true);
this.setNextStatement(true);
-
this.setTooltip(Blockly.Msg.MIXLY_TOOLTIP_I2C_MASTER_WRITE);
}
};
+
export const i2c_master_reader = {
init: function () {
this.setColour(COMMUNICATE_HUE);
@@ -309,6 +326,7 @@ export const i2c_master_reader = {
this.setTooltip(Blockly.Msg.MIXLY_TOOLTIP_I2C_MASTER_READ);
}
};
+
export const i2c_master_reader2 = {
init: function () {
this.setColour(COMMUNICATE_HUE);
@@ -477,7 +495,6 @@ export const RFID_readcarddata = {
.appendField(Blockly.Msg.MIXLY_COMMUNICATION_DATA_FROM)
this.setOutput(true, Number);
this.setTooltip(Blockly.Msg.MIXLY_TOOLTIP_RFID_READBLOCK);
-
}
};
diff --git a/boards/default_src/arduino_avr/blocks/ethernet.js b/boards/default_src/arduino_avr/blocks/ethernet.js
index d7f4ef6d..9174f540 100644
--- a/boards/default_src/arduino_avr/blocks/ethernet.js
+++ b/boards/default_src/arduino_avr/blocks/ethernet.js
@@ -747,7 +747,13 @@ export const WeatherGetToday = {
this.setColour(ETHERNET_HUE);
this.appendDummyInput("")
.appendField(Blockly.Msg.WeatherGetToday)
- .appendField(new Blockly.FieldDropdown([[Blockly.Msg.MIXLY_Humidity, "0"], ['PM2.5', "1"], ['PM1.0', "2"], [Blockly.Msg.TodayQuality, "3"], [Blockly.Msg.MIXLY_TEMPERATURE, "4"]]), "type");
+ .appendField(new Blockly.FieldDropdown([
+ [Blockly.Msg.MIXLY_Humidity, "0"],
+ ['PM2.5', "1"],
+ ['PM1.0', "2"],
+ [Blockly.Msg.TodayQuality, "3"],
+ [Blockly.Msg.MIXLY_TEMPERATURE, "4"]
+ ]), "type");
this.setOutput(true, Number);
this.setTooltip("返回对应数据 字符串型。");
}
@@ -759,7 +765,17 @@ export const WeatherGetForecast = {
this.setColour(ETHERNET_HUE);
this.appendDummyInput("")
.appendField(Blockly.Msg.WeatherGetForecast)
- .appendField(new Blockly.FieldDropdown([[Blockly.Msg.MIXLY_GPS_DATE, "ForecastDate"], [Blockly.Msg.ForecastHigh, "ForecastHigh"], [Blockly.Msg.ForecastLow, "ForecastLow"], [Blockly.Msg.ForecastYmd, "ForecastYmd"], [Blockly.Msg.MIXLY_WEEK, "ForecastWeek"], [Blockly.Msg.ForecastAqi, "ForecastAqi"], [Blockly.Msg.ForecastFx, "ForecastFx"], [Blockly.Msg.ForecastFl, "ForecastFl"], [Blockly.Msg.ForecastType, "ForecastType"]]), "type");
+ .appendField(new Blockly.FieldDropdown([
+ [Blockly.Msg.MIXLY_GPS_DATE, "ForecastDate"],
+ [Blockly.Msg.ForecastHigh, "ForecastHigh"],
+ [Blockly.Msg.ForecastLow, "ForecastLow"],
+ [Blockly.Msg.ForecastYmd, "ForecastYmd"],
+ [Blockly.Msg.MIXLY_WEEK, "ForecastWeek"],
+ [Blockly.Msg.ForecastAqi, "ForecastAqi"],
+ [Blockly.Msg.ForecastFx, "ForecastFx"],
+ [Blockly.Msg.ForecastFl, "ForecastFl"],
+ [Blockly.Msg.ForecastType, "ForecastType"]
+ ]), "type");
this.appendValueInput('date', Number)
.appendField(Blockly.Msg.MIXLY_GPS_DATE + '(0~14)');
this.setOutput(true, Number);
diff --git a/common/msg/blockly/zh-hant.js b/common/msg/blockly/zh-hant.js
index ad4d72d9..5c49149a 100644
--- a/common/msg/blockly/zh-hant.js
+++ b/common/msg/blockly/zh-hant.js
@@ -24,6 +24,9 @@ ZhHant.MSG = {
catSocket: "無線插座",
catRFID: "RFID",
catStorage: "存儲",
+ catStorageSD: 'SD',
+ catStorageSPIFFS: 'SPIFFS',
+ catStorageEEPROM: 'EEPROM',
catME_GO:"ME GO",
catME_G1:"ME G1",
catPE_G1:"PE G1",
@@ -3003,6 +3006,21 @@ ZhHant.MIXLY_SD_clusterCount = "簇數";
ZhHant.MIXLY_SD_blocksPerCluster = "每簇扇區數";
ZhHant.MIXLY_SD_TOTAL_blocks = "總扇區數";
ZhHant.MIXLY_PRINT_INLINE = "不換行";
+ZhHant.MIXLY_STM32_TFT_GREENTAB = "綠色標籤";
+ZhHant.MIXLY_STM32_TFT_REDTAB = "紅色標籤";
+ZhHant.MIXLY_STM32_TFT_BLACKTAB = "黑色標籤";
+ZhHant.MIXLY_STM32_TFT_FONT_COLOR = "字體顏色";
+ZhHant.MIXLY_STM32_TFT_BACKGROUND_COLOR = "背景顏色";
+ZhHant.MIXLY_STM32_TFT_BACKGROUND = "背景";
+ZhHant.MIXLY_STM32_TFT_SIZE = "尺寸";
+ZhHant.MIXLY_TOOLTIP_STORE_EEPROM_PUT = '寫入任何類型資料到EEPROM特定位址';
+ZhHant.MIXLY_TOOLTIP_STORE_EEPROM_GET = '從EEPROM的特定位址讀取任何類型資料';
+ZhHant.MIXLY_WIFI_LINK_DEVICE = '連結設備';
+ZhHant.MIXLY_STM32_SPI_REMAP = '重新映射';
+ZhHant.MIXLY_RFID_READ_CARD_UID = '讀取卡號';
+ZhHant.MIXLY_RFID_WRITE_CARD = '寫卡片';
+ZhHant.MIXLY_RFID_READ_CARD = '讀卡';
+ZhHant.MIXLY_RFID_BYTE_ARRAY = '位元組陣列';
ZhHant.MIXLY_STM32_OLED_DRAW_ARC = "畫圓弧";
ZhHant.MIXLY_STM32_OLED_ARC = "弧段";
ZhHant.MIXLY_NominalResistance = '常溫電阻值';
@@ -3082,6 +3100,18 @@ ZhHant.ADS1015_Get_Value = 'ADS1015模数转换模块';
ZhHant.ADS1015_setGain = "ADS1015采样范围和精度";
ZhHant.MIXLY_MP3_UDISK = '优盘';
ZhHant.MIXLY_MP3_SOURCE = '播放来源';
+ZhHant.MIXLY_DewPoint = '結露點';
+ZhHant.WeatherGet = '刷新天氣 城市 ';
+ZhHant.WeatherGetToday = '取得今日資料';
+ZhHant.TodayQuality = '空氣品質';
+ZhHant.WeatherGetForecast = '取得15日報資料';
+ZhHant.ForecastHigh = '最高溫度';
+ZhHant.ForecastLow = '最低溫度';
+ZhHant.ForecastYmd = '年月日';
+ZhHant.ForecastAqi = '空氣指數';
+ZhHant.ForecastFx = '風向';
+ZhHant.ForecastFl = '風力';
+ZhHant.ForecastType = '天氣';
ZhHant.SPACE_ALLOCATION = '空間分配';
ZhHant.MIXLY_IR_RANGE = '雙紅外測距';
ZhHant.MIXLY_LASER_RANGE = '鐳射測距儀';