From e772c4e1471465de95db04e42767e2d85f243a4d Mon Sep 17 00:00:00 2001 From: SebCanet Date: Thu, 18 Jan 2024 15:37:00 +0100 Subject: [PATCH] fix library bug --- generators/arduino/stendhal.js | 1 + 1 file changed, 1 insertion(+) diff --git a/generators/arduino/stendhal.js b/generators/arduino/stendhal.js index c3347514..d30ed129 100644 --- a/generators/arduino/stendhal.js +++ b/generators/arduino/stendhal.js @@ -178,6 +178,7 @@ Blockly.Arduino['stendhal_ds18b20_search'] = function() { var ds18b20_pin = Blockly.Arduino.valueToCode(this, 'PIN', Blockly.Arduino.ORDER_ATOMIC); var ds18b20_nb = Blockly.Arduino.valueToCode(this, 'NB', Blockly.Arduino.ORDER_ATOMIC); var ds18b20_nb0 = ds18b20_nb - 1; + Blockly.Arduino.includes_['onewire_include'] = '#include '; Blockly.Arduino.includes_['ds18b20_include'] = '#include '; Blockly.Arduino.definitions_['ds18b20_def_' + ds18b20_pin] = 'DS18B20 ds18b20_' + ds18b20_pin + '(' + ds18b20_pin + ');\n' + 'uint8_t addrTempSensor_' + ds18b20_pin + '[' + ds18b20_nb + '][8] = {};';