RB-Elf-40 (Robot shop product code) is a waterproof digital temp sensor (DS18B20 from ElecFreaks)
Can someone please guide me on how I can connect this sensor to a microBi and possibly program it in MakeCode.
I tried looking for an extension/library for it in Makecode without success.
I tried connecting the sensor to MicroBit with three wires - Yellow to Data line (Pin 7) on MB, Red to +3.3V of MB and black to GND.
In Makecode:
in a forever loop:
set temp = digital read from Pin7
display temp
pause 2sec
All I see is a 1 at the beginning and then 0 after that.
Thanks for your help.
Hello @mojeeza!
I found a guide on how to use this module with the Micro:bit. The package is different in their pictures, but it is the same component
https://www.iot-programmer.com/index.php/books/27-micro-bit-iot-in-c/chapters-micro-bit-iot-in-c/24-micro-bit-and-ds18b20-1-wire-temperature-sensor
I hope this helps!
1 Like
Hello @Magmator
Thanks a lot for your reply.
Worked perfectly…took a little prep work to Install the necessary components (for MicroBit) in the Arduino IDE and hooking up the wiring for single wire sensors.
Just to clarify - apparently One wire sensor will NOT work in MakeCode - from what I understand. But it worked using the Arduino IDE perfectly.
1 Like