|
Post by papa on May 23, 2016 0:01:51 GMT
Node Senses Temps in Enclosed or Liquid Areas "Freezer" Node or Other Purposes Starting April 1, 2019 This Thread was Updated,
Esp. for openHAB 2.5.0.M1, MQTT 2.x Binding, & the Embedded MQTT Broker
The DHT11 is a useful sensor, giving air temperatures in the range 32-122° F (0-50 degrees C, ±2°C accuracy) & good for 20-80% relative air humidity readings with 5% accuracy. However, what if (like me) one needs / wants temperatures sensed beyond the DHT sensor range. What if you want / need a waterproof sensor for liquids. What about measuring temps in an enclosure, but leaving the node outside the enclosure. Another temperature sensor is a Dallas DS18B20 or DS18S20 temperature sensor with a waterproof probe & cable. The two versions work similarly, but this compares them. I’ll refer to only one version for both. Here are examples from Adafruit (which includes the needed 4.7K ohm resistor) & eBay. This sensor’s usable temperature range is -55 to 125° C ( -67°F to +257°F) but its PVC cable covering suggests avoiding much above 100° C (212° F). Its usable with 3.0V to 5.5V power/data, which fits well with our 3.3 volt nodes. << This pictures a typical DS18x20 sensor. A metal probe is on one end & continues with a waterproof PVC covered cable. The other end is three insulated small wires with stripped ends: The red wire goes to power. The yellow wire provides sensor data. The last wire (black or green or blue or ??) goes to GND. I built a Freezer Node to sit on top our freezer. It has an optional DHT11 sensor to measure temperature & humidity of the air above the freezer. It also has a DS18B20 sensor whose cable & probe extends into the freezer to measure the temperature inside the freezer. Since a freezer’s optimum temperature for food preservation is around 0 degrees F & can range a bit above & below that, the DS18 sensors are a good choice. Other uses: given the sensor probe has a waterproof cable, this node could also be used to monitor liquid temperatures.
|
|
|
Post by papa on May 23, 2016 0:05:14 GMT
Node Senses Temps in Enclosed or Liquid Areas
"Freezer" Node or Other Purposes (Hardware) Updated Nov. 9 & 10, 2018
An important assembly note to supplement the schematics below: To avoid damaging the RFM69 radio, use an Arduino compatible that can use 3.3 volts throughout most of it, including the digital pins (D13, etc). Schematics for "Freezer" Node, DS18B updated Nov. 10, 2018 to match the sketch: << Forum members (free registration), click on pic for larger view. ^^ DS18B option ^^ DS18A or DS18B options
Either DS18 Sensor option can be powered by Arduino 3.3 volts. For the DS18B Sensor option, the sketch sets Arduino D5 HIGH to power the sensor with 3.3 volts. This can help a battery-powered node. If not using a battery to power DS18B, you may connect the DS18 sensor's vcc to Arduino 3.3 volts.
More key assembly notes: since this node requires multiple connections to digital pins and 3.3 volts, I recommend that on top the Arduino compatible, you insert a shield hacked for this purpose. In the schematic, note that the DS18 sensor's data wire (yellow?) must connect to Arduino D3 AND (via a 4.7 kilo ohm pull up resistor) to Arduino 3.3 volts. For building this node on a 3.3 volt friendly Arduino shield, you can get help at these Oct 10-15, 2015 posts. Except for this node, omit the steps about the push button AND omit the solid state relay powered by the transistor. On the adapted shield, just install the (optional) DHT11 sensor & the RFM69 radio plus the DS18x20 sensor(s) according to the schematic above. As designed & programmed, this node can have only two temp sensors, one of which can be a DHT11. If you choose to have two DS18x20 temp sensors, omit the DHT11 connections & connect both DS18x20 sensors to the exact same pins, that includes both sensor's data pins connecting to Arduino d3. Hint: Via a multimeter, continuity test your soldered connections to make sure you achieved the right connections (schematic) & avoided the wrong connections. Insert the completed shield on top the Arduino compatible. Match the shield's analog pins with the Arduino compatible's analog sockets & digital pins with digital sockets.
|
|
|
Post by papa on May 23, 2016 0:16:08 GMT
Node Senses Temps in Enclosed or Liquid Areas "Freezer" Node or Other Purposes (Software) Updated Nov. 9 - Dec. 8, 2018
GO HERE to download the latest node choices sketch & achieve initial customization. (Note: this sketch can be customized for several types of nodes with separate or combined functions. See the list here.) With the Arduino IDE, appropriately add this to the initial customization of the sketch:
#define NODEID 02 << change 02 to a unique number in your RFM69 network
I'll assume 80 in the following. For a node with one DHT11 sensor & one DS18x20 sensor:
UNcomment #define FAHR or #define CELS ... (no "//" at their beginning)
UNcomment one line to read #define HT ... (no "//") UNcomment #define DS18 UNcomment DS18B ( caution: leaveDS18 A commented) Summary: UNcomment: #define HT, #define DS18, #define DS18 B plus line #define FAHR OR #define CELS.
-------------------------------------------------------------- For a Battery-Sipping Node (Added Nov. 22, 2018) Use the customizing above EXCEPT ... Also make sure #define SLEEPY is UNcommented (no // at the line's beginning).
-------------------------------------------------------------- For a node with TWO DS18x20 sensors (NO DHT11): Use the customizing above EXCEPT ... Make sure #define HT is commented, i.e. it reads // #define HT UNcomment ALL three lines: #define DS18 #define DS18 A #define DS18 B------------------------------------------- With the Arduino IDE running on a computer & the Freezer Node connected via USB, upload the sketch program to the node. Then with the node still on USB, the Gateway successfully running connected to your Ethernet network & the IDE serial monitor running at 115200 baud, the serial monitor should display connection & data info about the node.
|
|
|
Post by papa on May 23, 2016 0:49:26 GMT
OpenHAB configurations for a "Freezer" Node with DHT11 AND one DS18x20:
(Updated April 1, 2019) Skip this post if you have TWO DS18 Sensors on your node.
For ALL end nodes to work, you need OpenHAB & a MQTT Broker running on a computer connected to your local Ethernet Network
(Presupposes NODEID is 80. In the following, replace 80 with the NODEID you assign)
Go to PaperUI\Inbox\MQTT Binding\Search Manually Add. Click the ">" at right of Generic
Configure a Node80 Generic MQTT Thing using the following fields: Name: Node80 Location: BaseFR [Thing's location on which tab of PaperUI\Control, could also be physical location ] Bridge Selection MQTT Broker - mqtt:systemBroker:embedded-mqtt-broker
PaperUI\Configuration\Things\Node80 Add channels (click + in blue disc)
Type: Text Type: Number Channel ID Node80Channel02 Channel ID Node80Channel48 Label: Node80_RSSI Label: Node80_DHTtemp State Topic: home/rfm_gw/nb/node80/dev02 State Topic: home/rfm_gw/nb/node80/dev48
Type: Number Type: Number Channel ID Node80Channel49 Channel ID Node80Channel50 Label: Node80_DHThumidity Label: Node80_DS18temp State Topic: home/rfm_gw/nb/node80/dev49 State Topic: home/rfm_gw/nb/node80/dev50
Add entries for a Node80.items file in openHAB's \conf\items folder: String Node80Rssi "Frzr80_RSSI (db)[%s]" <network> (Nodes) { channel="mqtt:embedded-mqtt-broker:topic:mything:Node80Channel02" } Number Humidity_Node80 "Humidity_BaseFR80 [%d %%]" <humidity> { channel="mqtt:embedded-mqtt-broker:topic:mything:Node80Channel49" }
Number Temperature_Node80 "Temp_BaseFR05 [%.1f C]" <temperature> { channel="mqtt:embedded-mqtt-broker:topic:mything:Node80Channel48" } Number TempFrzr_Node80 "FzrTemp80 [%.1f C]" <temperature> { channel="mqtt:embedded-mqtt-broker:topic:mything:Node80Channel50" } // For Fahrenheit nodes change ^^ [%.1f C] to [%.1f F]
Important: Link the above channels to the matching items in Node80.items above.
Add to .sitemap file entries: Text item=Temperature_Node80 Text item=Humidity_Node80 Text item=TempFrzr_Node80 Add nothing to the .rules file entries. Add nothing to the icon files Note: The above will gather temp & humidity outside the freezer AND temp inside the freezer & report it on the Classic UI (user interface) displayed on a browser.
|
|
|
Post by papa on May 23, 2016 1:18:24 GMT
OpenHAB configurations for a "Freezer" Node with TWO DS18x20s:
(Updated April 1, 2019) This post is used in place of the previous post.
For ALL end nodes to work, you need OpenHAB & a MQTT Broker running on a computer connected to your local Ethernet Network (Presupposes NODEID is 80. In the following, replace 80 with the NODEID you assign)
If you did not already create a Node80 Thing ...
Go to PaperUI\Inbox\MQTT Binding\Search Manually Add. Click the ">" at right of Generic Configure a Node80 Generic MQTT Thing using the following fields: Name: Node80 Location: BaseFR [Thing's location on which tab of PaperUI\Control, could also be physical location ] Bridge Selection MQTT Broker - mqtt:systemBroker:embedded-mqtt-broker ------------------------------------------------
PaperUI\Configuration\Things\Node80 Add channels (click + in blue disc)
Type: Text Type: Number Channel ID Node80Channel02 Channel ID Node80Channel48 Label: Node80_RSSI Label: Node80_DHTtempA State Topic: home/rfm_gw/nb/node80/dev02 State Topic: home/rfm_gw/nb/node80/dev48
Type: Number Channel ID Node80Channel50 Label: Node80_DS18tempB State Topic: home/rfm_gw/nb/node80/dev50
Add entries for a Node80.items file in openHAB's \conf\items folder: String Node80Rssi "Frzr80_RSSI (db)[%s]" <network> (Nodes) { channel="mqtt:embedded-mqtt-broker:topic:mything:Node80Channel02" }
Number Temp_A_Node80 "Temp_A_80 [%.1f C]" <temperature> { channel="mqtt:embedded-mqtt-broker:topic:mything:Node80Channel48" } Number Temp_B_Node80 "Temp_B_80 [%.1f C]" <temperature> { channel="mqtt:embedded-mqtt-broker:topic:mything:Node80Channel50" } // For Fahrenheit nodes change ^^ [%.1f C] to [%.1f F]
Important: Link the above channels to the matching items in Node80.items above.
Add to .sitemap file entries: Text item=Temp_A_Node80 Text item=Temp_B_Node80
Add nothing to the rules file entries. Add nothing to the icon files.
Note: The above will gather temps from the two DS18x20 sensors & report it on the Classic UI (user interface) displayed on a browser.
|
|
|
Post by papa on May 24, 2018 15:18:42 GMT
Moderator's Notes:
I originally called this a "Freezer Node." However, with one or both types of temp sensors, it could be used in other locations. Most of the node could be in a secure, dry location while the waterproof DS18x20 sensor(s) could be in an enclosed or potentially liquid location. I'd love to hear how you use this node.
I have deleted several posts that were below because they are no longer relevant to using at least openHAB 2.5.0.M1, MQTT 2.x Binding, & the Embedded MQTT Broker. The posts above have been updated.
|
|
|
Post by papa on Jun 13, 2018 14:37:48 GMT
Moderator Notes:
The one rule in My.rules aims to combine heat AND humidity data so it can display together in one slot on the sitemap. If you are NOT using humidity, just delete My.rules. For the same reason, delete this from My.sitemap: Text item=Node##_Data (## is the ID number of your node)
==================================================
In the User Interface sitemap, "Node Health" is supposed to be a clickable link taking you to a page reporting RSSI & node voltage.
|
|
|
Post by papa on Jun 13, 2018 15:25:04 GMT
Original post content was deleted. Post is retained for possible future use.
|
|
kisa
Junior Member
Posts: 54
|
Post by kisa on Jun 14, 2018 10:30:54 GMT
I found a solution to a problem. I was missing a double quote mark (") in one of my items
papa: Yes, little marks like that are hard to see & yet can make a big difference.
kisa: Warning message, Validation issues found in configuration model 'My.sitemap', using it anyway ...
papa: OpenHAB 2 protests over comments in .sitemap files & then generally uses the file anyway.
If you want to avoid that warning about the sitemap, you can delete the comments (lines that start with // ) at the top of My.sitemap
|
|
|
Post by papa on Jun 14, 2018 21:42:04 GMT
Original post content was deleted. Post is retained for possible future use.
|
|
|
Post by papa on Jun 15, 2018 1:02:01 GMT
Original post content was deleted. Post is retained for possible future use.
|
|
kisa
Junior Member
Posts: 54
|
Post by kisa on Jun 15, 2018 7:35:57 GMT
ok , it now WORKS! I have a temperature next to Temperature_Node50 and the power symbol next to Node50_Output is red unless I slide the slider where it goes green. Looks like my lack of OpenHAB understanding has bitten me, by assuming doing a standard openHabian install would be sufficient.
Thank you very much for your speedy help and patience, you have shown a lot of that . I will also reiterate what I said previously, you have an amazing amount of detailed and helpful information on this site and your support has been amazing. THANK YOU. Hopefully I can proceed from here without harassing you too much .
|
|
|
Post by papa on Jun 15, 2018 13:59:12 GMT
kisa: ... made the difference, it now WORKS
Awesome to hear your progress, kisa. As I keep saying, this project is very challenging with lots of details. It's easy to miss things. I'm glad to hear that my time spent in documenting & simplifying (where possible) has been helpful. I'm also hoping that my scripts & RFM69 radio tests will help users (especially new ones) report here what they might need to work on to get success.
kisa: Hopefully I can proceed from here without harassing you too much.
You've been very respectful & have supplied good information to help me help you. I hope you will check in from time to time with your progress & what works for you. Feedback helps & encourages. I'd especially like you to share any new aspects of the project that you discover or try or info that may need correcting.
kisa: Thank you very much for your speedy help and patience You are welcome. Thanks for being the first user to report results from the check_OH script. What did you think of the script? ==============================================
kisa: "one warning/error that comes up now when viewing openhab.log ... weather binding."
papa: Looks like you're using weather binding install from OpenHAB ONE (perhaps via me), not TWO. Please create a new thread maybe called "Issues with Weather Binding" In the new thread's first post, put the last section of your last post: " there is one warning/error that comes up now when viewing openhab.log ... I hate seeing errors"
I'm busy for a couple days, but after that I can probably help you with the weather binding via that new thread you are starting.
|
|
kisa
Junior Member
Posts: 54
|
Post by kisa on Jun 15, 2018 22:53:07 GMT
I'll certainly report any significant progress and if I find any issues.
I'll start the new thread.
Thanks again.
|
|
domin
New Member
Posts: 6
|
Post by domin on Nov 8, 2018 18:19:22 GMT
Hi homeautomation fans :-)
First post here long time lurker :-)
I have been trying to build the freezer node with one DHT11 and one DS18x20 sensor, the node is up and running and connecting fine to the gateway, DHT11 reporting correct values, but the DS18 is not working, the only value i get from it is:
Requesting temperatures...DONE Temperature for DS18 Device 50 is: -196.60 F Node: 3 dev: 99 cmd: 0 Ival: 0 Fval: 0.00 RSSI: -47
Node: 3 dev: 2 cmd: 0 Ival: 0 Fval: 0.00 RSSI: -47 Node: 3 dev: 4 cmd: 0 Ival: 0 Fval: 5.01 RSSI: -47 Node: 3 dev: 9 cmd: 0 Ival: 1 Fval: 5.01 RSSI: -47 Node: 3 dev: 48 cmd: 0 Ival: 0 Fval: 75.20 RSSI: -47 Node: 3 dev: 49 cmd: 0 Ival: 0 Fval: 42.00 RSSI: -47 Node: 3 dev: 50 cmd: 0 Ival: 0 Fval: -196.60 RSSI: -47
This is with the temperature set to F instead of C as an experiment, i started out with C where it reports -127, i checked the wiring several times, changed the pull-up resistor, and changed the DS18B20 but still not working, any suggestions to fix this would be nice.
|
|
|
Post by papa on Nov 8, 2018 19:39:07 GMT
Good to hear from you, domin. Members asking help often help identify issues to be addressed. Please remember to also share insights & tips you are learning from your efforts. Now related to your request ... Suggestion: I googled "wrong values from DS18B20 sensor" The first hit was forum.arduino.cc/index.php?topic=339951.0 which included: "Check your wiring. ... The error "DEVICE_DISCONNECTED" results into a temperature of -196.6 F It sounds like DEVICE_DISCONNECTED is ... the same as no device connection." So check your wiring again. Perhaps post here a closeup pic of your wiring so we can see how you made your connections. Also look for clues & hints at the other links from the Google search.
If you find something in this thread that may need changing, please report back.
|
|
|
Post by papa on Nov 9, 2018 21:28:23 GMT
My documentation on this thread was a couple years old. Since I have so much material on this forum, I don't tend to review & update such threads until someone like domin expresses interest & issues OR I need to build another node that the thread features.
Starting with this post, I just reviewed & updated this thread. The update includes a simplified schematic & the latest version of my multi-choice end node sketch.
The DS18x20 sensor code in the sketch is what I've successfully used for at least six nodes.
Just now I added a DS18x20 sensor & its 4.7 kilo ohm resistor to a bare RFM69 end node & defined NODEID 29, DS18, DS18B, Fahr, etc & got these Serial Monitor results:
Node 29 Version 2.2MhF7 DS18B Fahr GW2.5.1
Transmitting at 915 Mhz... Requesting temperatures...DONE Temperature for DS18 Device 50 is: 72.27 F << (room temp) Node: 29 dev: 99 cmd: 0 Ival: 0 Fval: 0.00 RSSI: -68
Node: 29 dev: 2 cmd: 0 Ival: 0 Fval: 0.00 RSSI: -67 Node: 29 dev: 4 cmd: 0 Ival: 0 Fval: 3.23 RSSI: -67 Node: 29 dev: 9 cmd: 0 Ival: 1 Fval: 3.23 RSSI: -68 Node: 29 dev: 50 cmd: 0 Ival: 0 Fval: 72.27 RSSI: -68
Requesting temperatures...DONE Temperature for DS18 Device 50 is: 81.27 F << (probe held a while in my fingers)
Node: 29 dev: 2 cmd: 0 Ival: 0 Fval: 0.00 RSSI: -60 Node: 29 dev: 4 cmd: 0 Ival: 0 Fval: 3.22 RSSI: -60 Node: 29 dev: 9 cmd: 0 Ival: 1 Fval: 3.22 RSSI: -60 Node: 29 dev: 50 cmd: 0 Ival: 0 Fval: 81.27 RSSI: -60 ===============================
Not having a DHT11 sensor on this node, I tried changing the above defines: commented DS18B & UNcommented DS18A. Then I got similar Serial Monitor results, except via device 48 instead of device 50.
|
|
domin
New Member
Posts: 6
|
Post by domin on Nov 10, 2018 14:50:06 GMT
Hi Papa Thanks for looking into this, i just created a new node with only the DS18b20 sensor and i am still getting the same result, i used a new Uno BuonoR3 new DS18, new 4.7 kilo ohm resistor, but i still get the same result -127 (Celsius) I then updated the node sketch to the latest i could find 2.2MhF6 but the result are still the same: Node 3 Version 2.2MhF6 DS18B Cels ting at 433 Mhz... Requesting temperatures...DONE Temperature for DS18 Device 50 is: -127.00 C Node 3 Version 2.2MhF6 DS18B Cels GW2.5.1
Transmitting at 433 Mhz... Requesting temperatures...DONE Temperature for DS18 Device 50 is: -127.00 C The new sketch i did a new edit and only added the DS18 as a single sensor no DHT sensor, but i am still getting same results.
Here is a picture of the temporary connection for the sensor.
|
|
|
Post by papa on Nov 10, 2018 16:19:50 GMT
domin, from your pic, it looks like you've connected the wires & resistors to the right locations. Using a multi-meter, have you done a continuity check on your wires. If you don't know what I mean ... put the meter's dial on the setting where touching the meter's probes together will generate a tone. Then one at a time for the three sensor wires, put one probe on the bare sensor wire near the insulation & the other probe at the bare far end of the wire soldered to the sensor wire. Do you get a solid tone even when you wiggle the wires? Then put one meter probe on the bare resistor wire on the red wire side & put the other probe on the bare end now inserted into Arduino 3.3v. Finally put one meter probe on the bare resistor wire on the yellow wire side & put the other probe on the bare end now inserted into Arduino D3. Do these all generate solid meter tones indicating reliable soldering?
Since you are not using the DHT11 sensor, in the sketch, try commenting out option DS18B & UNcommenting option DS18A. Then upload & check Serial Monitor. Do you get correct temp results via device 48?
Did you try the Google searches I suggested?
I'm also continuing to research.
|
|
domin
New Member
Posts: 6
|
Post by domin on Nov 17, 2018 11:39:51 GMT
Hi Papa
Sorry for the late reply, got caught up in work
As i currently do not have a multimeter i tried the other solution to use DS18A and that works ;-) Node 3 Version 2.2MhF6 DS18A Cels GW2.5.1
Transmitting at 433 Mhz... Requesting temperatures...DONE Temperature for DS18 device 48 is: 23.94 C
Any hints as to why its not working when i select it in combination with the DHT/DS18B mode?
|
|
domin
New Member
Posts: 6
|
Post by domin on Nov 17, 2018 11:55:38 GMT
Hmm looking at this: // 50 temperature: read temperature (DS18 data on D3), D5 power pin Should i power the DS18 from the D5 pin, i am not doing that now, so it might be because of that?
Edit: Just looked at the new schematics, and that is the error, need to re-solder and test.
|
|
|
Post by papa on Nov 17, 2018 14:32:28 GMT
domin: " i tried the other solution to use DS18A and that works" papa: The original sketch with DHT on device 48 & DS18 on device 50 works fine for me, but ...
at least one other forum member had trouble with the original sketch & success with what DS18A does: temp = sensors.getTempCByIndex(0)
Seems that for some people this DS18B code does not work when only one DS18 sensor is being used: temp = sensors.getTempCByIndex(1)
So for now, if you are using only ONE DS18 sensor on a node along with a DHT sensor on device 48 ...
in this thread's multi-choice node sketch, find "#ifdef DS18B" about line 2248
Soon after that find TWO temp = sensors.getTempCByIndex(1)"
& change both to temp = sensors.getTempCByIndex(0)
Caution: this change in code should not work if TWO DS18 sensors are used on a node.
I may change the DS18B code to use ...Index(1) only when two DS18 sensors are being used.
Thanks, domin, for confirming a need to look closer at this.
|
|
|
Post by papa on Nov 17, 2018 15:06:23 GMT
domin, don't miss my other reply in the just previous post.
domin: "Should i power the DS18 from the D5 pin?"
papa: In schematics & code, I sometimes power the DS18 from the D5 pin. A couple of reasons: It's a way to get another 3.3 volt powering socket on an Arduino AND one can use code to turn it on & off to save power if a node is battery powered.
If not using a battery, one can connect DS18's VCC to Arduino 3.3 volts (even if the code is turning D4 on & off). The sensor just needs 3.3 volts somehow when its seeking temperature.
When I get time, I need to look at how consistently schematics & code are powering DS18.
|
|
domin
New Member
Posts: 6
|
Post by domin on Nov 21, 2018 16:57:49 GMT
domin: " i tried the other solution to use DS18A and that works" papa: The original sketch with DHT on device 48 & DS18 on device 50 works fine for me, but ...
at least one other forum member had trouble with the original sketch & success with what DS18A does: temp = sensors.getTempCByIndex(0)
Seems that for some people this DS18B code does not work when only one DS18 sensor is being used: temp = sensors.getTempCByIndex(1)
So for now, if you are using only ONE DS18 sensor on a node along with a DHT sensor on device 48 ...
in this thread's multi-choice node sketch, find "#ifdef DS18B" about line 2248
Soon after that find TWO temp = sensors.getTempCByIndex(1)"
& change both to temp = sensors.getTempCByIndex(0)
Caution: this change in code should not work if TWO DS18 sensors are used on a node.
I may change the DS18B code to use ...Index(1) only when two DS18 sensors are being used.
Thanks, domin, for confirming a need to look closer at this.
This was exactly the change needed, after changing the above code, everything works as it should.
Thanks a lot for all the help papa
|
|
|
Post by papa on Nov 21, 2018 19:38:45 GMT
You are welcome, domin. Thank you for providing the feedback to help address this issue.
|
|
|
Post by papa on Nov 22, 2018 23:54:46 GMT
Revised Code for DS18 Temp Sensors Revised Naming of the Node Choices Sketch
Forum members (free registration), GO HERE to download the latest version of the Node Choices sketch & get initial customization. I did much testing & work on the DS18 Temperature Sensor code. I corrected DS18 use of the function sensors.getTemp?ByIndex(index) that created issues for domin above & others. Especially via a function, I also reduced DS18 code (sleepy & "awake") in the sketch. (It takes up less space in the sketch, but will probably compile to a similar size as before.) The only thing I did not test was using TWO DS18 sensors on one node.
For this latest sketch version, use the same customization as in the post above, to which I added customization for a battery-sipping DS18 node. For the sketch's file name, I continue to use the sketch's main version ID, like "MhF9xx" as part of the whole name choose_nodes_[ID]_pub.ino. I use _pub to indicate the public file versus _papa for my own personal file. Hence the file name choose_nodes_MhF9xx_pub.
Added Dec. 1, 2018: In this sketch version, 2 DS18 temp sensors can be wired to D3. Temperature readouts are placed in send48 and send50 variables. This sketch allows you to put either a DHT11 (device 48) and DS18 (device 50) on a node, or up to 2 DS18 devices (one on device 48 & one on device 50). The sketch variable TXinterval sets the number of seconds between each reading / sending of temperature measurements.
|
|
domin
New Member
Posts: 6
|
Post by domin on Nov 24, 2018 8:54:42 GMT
Thanks a lot for all the hard work papa.
I can see that the DS18 sensors are One Wire sensors, do this mean that it would be possible to connect several of them on the same connection, measuring several different temperatures? I have 6 different points right besides the current one i would like to measure, so if this is possible that would make it quite a lot easier.
|
|
|
Post by papa on Nov 24, 2018 14:33:57 GMT
domin: "Thanks a lot for all the hard work papa." papa: You are welcome. It's good to have someone interested & also returning encouragement for the efforts here. domin: "The DS18 sensors are One Wire sensors, does this mean that it would be possible to connect several of them on the same connection, measuring several different temperatures?" papa: Good question. It is supposed to be possible. Within the DS18 option, the Node Choices sketch currently provides a DS18A option & a DS18B to attach data lines from TWO DS18 sensors to Arduino D3 & monitor two different temperatures. I have not tested using two DS18 sensors on the same node. I would appreciate your doing that testing & reporting your results here. I encourage you to use the updated sketch in this post. The sketches referenced there since Dec. 1, 2018 has one correction related to DS18A.In this post's schematics, note that Arduino 3.3 volts powers the DS18 A sensor. Arduino D4 or Arduino 3.3 volts powers DS18 B sensor. Once you have two DS18 sensors working, we can discuss using more than two. Some initial thoughts: More than two sensors would need adding code to the sketch (DS18C, etc ?) & work out ways to connect more wires to the node (3 wires per sensor). By testing, one would need to determine how many sensors the Arduino is able to power. Update, April 1, 2019: Sometime after this post, I tested TWO DS18 sensors on the same node & that worked fine.
|
|