From 84e3fee2c17f783d6045be3a080ceaa29697b9e5 Mon Sep 17 00:00:00 2001
From: Irene-Maxine <114802521+Irene-Maxine@users.noreply.github.com>
Date: Tue, 19 Nov 2024 12:52:07 +0800
Subject: [PATCH] =?UTF-8?q?=E5=BE=AE=E6=B3=A2=E9=9B=B7=E8=BE=BE=E5=9D=97?=
=?UTF-8?q?=E7=A7=BB=E5=8A=A8=E4=BD=8D=E7=BD=AE=E5=92=8C=E5=9D=97=E8=B0=83?=
=?UTF-8?q?=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../micropython/blocks/sensor_extern.js | 20 ++++--------
.../micropython_esp32/template.xml | 32 +++++++++++--------
.../micropython_esp32c2/template.xml | 32 +++++++++++--------
.../micropython_esp32c3/template.xml | 32 +++++++++++--------
.../micropython_esp32s2/template.xml | 32 +++++++++++--------
.../micropython_esp32s3/template.xml | 32 +++++++++++--------
6 files changed, 96 insertions(+), 84 deletions(-)
diff --git a/boards/default_src/micropython/blocks/sensor_extern.js b/boards/default_src/micropython/blocks/sensor_extern.js
index c853130d..09d5b6d3 100644
--- a/boards/default_src/micropython/blocks/sensor_extern.js
+++ b/boards/default_src/micropython/blocks/sensor_extern.js
@@ -375,24 +375,16 @@ export const radar_set_DETECTION_THRESHOLD = {
.setCheck("var");
this.appendDummyInput("")
.appendField(Blockly.Msg.LISTS_SET_INDEX_SET + Blockly.Msg.MIXlY_INTERACTION)
+ this.appendValueInput('VAR')
+ .appendField(Blockly.Msg.MIXLY_DETECTION_THRESHOLD);
+ this.appendValueInput('VAR2')
+ .appendField(Blockly.Msg.MIXLY_DELAY_TIME);
this.appendDummyInput()
- .appendField(new Blockly.FieldDropdown([
- [Blockly.Msg.MIXLY_DETECTION_THRESHOLD,'threshold'],
- [Blockly.Msg.MIXLY_DELAY_TIME+' ms','delay_ms']
- ]),"key")
- this.appendValueInput('VAR');
+ .appendField('ms');
this.setPreviousStatement(true);
this.setNextStatement(true);
this.setInputsInline(true);
- var thisBlock = this;
- this.setTooltip(function () {
- var mode = thisBlock.getFieldValue('key');
- var TOOLTIPS = {
- "threshold": Blockly.Msg.MIXLY_THRESHOLD_TOOLTIP,
- "delay_ms": Blockly.Msg.MIXLY_DELAY_TIME_RANGE
- };
- return TOOLTIPS[mode]
- });
+ this.setTooltip(Blockly.Msg.MIXLY_THRESHOLD_TOOLTIP+' ; '+Blockly.Msg.MIXLY_DELAY_TIME_RANGE)
}
};
diff --git a/boards/default_src/micropython_esp32/template.xml b/boards/default_src/micropython_esp32/template.xml
index 5b6c77c9..6de15468 100644
--- a/boards/default_src/micropython_esp32/template.xml
+++ b/boards/default_src/micropython_esp32/template.xml
@@ -3808,6 +3808,24 @@
+
+
+
+ xsensor
+
+
+
+
+ 5000
+
+
+
+
+ 500
+
+
+
+
@@ -4125,20 +4143,6 @@
-
-
-
- xsensor
-
-
-
-
- 5000
-
-
-
-
-
diff --git a/boards/default_src/micropython_esp32c2/template.xml b/boards/default_src/micropython_esp32c2/template.xml
index b6f63183..0f9b21ba 100644
--- a/boards/default_src/micropython_esp32c2/template.xml
+++ b/boards/default_src/micropython_esp32c2/template.xml
@@ -3667,6 +3667,24 @@
+
+
+
+ xsensor
+
+
+
+
+ 5000
+
+
+
+
+ 500
+
+
+
+
@@ -3987,20 +4005,6 @@
-
-
-
- xsensor
-
-
-
-
- 5000
-
-
-
-
-
diff --git a/boards/default_src/micropython_esp32c3/template.xml b/boards/default_src/micropython_esp32c3/template.xml
index b21b22f9..5935d658 100644
--- a/boards/default_src/micropython_esp32c3/template.xml
+++ b/boards/default_src/micropython_esp32c3/template.xml
@@ -3605,6 +3605,24 @@
+
+
+
+ xsensor
+
+
+
+
+ 5000
+
+
+
+
+ 500
+
+
+
+
@@ -3925,20 +3943,6 @@
-
-
-
- xsensor
-
-
-
-
- 5000
-
-
-
-
-
diff --git a/boards/default_src/micropython_esp32s2/template.xml b/boards/default_src/micropython_esp32s2/template.xml
index 69f14e33..c65bf385 100644
--- a/boards/default_src/micropython_esp32s2/template.xml
+++ b/boards/default_src/micropython_esp32s2/template.xml
@@ -3401,6 +3401,24 @@
+
+
+
+ xsensor
+
+
+
+
+ 5000
+
+
+
+
+ 500
+
+
+
+
@@ -3718,20 +3736,6 @@
-
-
-
- xsensor
-
-
-
-
- 5000
-
-
-
-
-
diff --git a/boards/default_src/micropython_esp32s3/template.xml b/boards/default_src/micropython_esp32s3/template.xml
index 4272290e..67c72b55 100644
--- a/boards/default_src/micropython_esp32s3/template.xml
+++ b/boards/default_src/micropython_esp32s3/template.xml
@@ -4040,6 +4040,24 @@
+
+
+
+ xsensor
+
+
+
+
+ 5000
+
+
+
+
+ 500
+
+
+
+
@@ -4357,20 +4375,6 @@
-
-
-
- xsensor
-
-
-
-
- 5000
-
-
-
-
-