I have several temperature/humidity sensors located in my house. The are well-known lacrosse TX3-TH, transmitting data on 433 mhz. I have a simple arduino with 433 mhz receiver that receives and decodes the signals.
Arduino is attached to serial port of HAH and feeds serial port with data in the form
id=505,type=t,value=24 (sensor with id 505 transmitted temperature with value of 24 centigrade)
or
Member for
16 years 10 monthsVores8,When creating a filter
Vores8,
When creating a filter you should filter only for messages originating from the PORT you are after.
Then you would not need to bother with this line. As you know you must be having data from the filter.
if not frame:isValue("Serial.Received", "data", xap.FILTER_ABSENT) thengood stuff.
Brett
Member for
14 years 8 monthsGreat, thanks! (and as usual,
Great, thanks! (and as usual, thanks for the gerat software :))
Member for
16 years 10 monthsVores8, You code is rather
Vores8, You're code is rather long. I've shortened it a little (see attached). I've not compiled nor tested this but I think you get my drift. It might just work first time too :)
Brett
Member for
14 years 8 monthspolished version
I've polished code a bit (see attached). Now it also helps with the situation when u r changig sensor's batteries which results in a new ID being assigned to the sensor. To identify new ID the script creates "unregistered" BSC endpoint which broadcasts data containing new sensor ID - so you just need to sniff these messages with say xfx viewer and modify sensors table accordingly
results happily flow to pachube (9 sensors each with temp and humi)
And again guys, thanks for the great software :)
Member for
16 years 10 monthsYou should not be using
You should not be using ep:sendInfo() you should be using ep:sendEvent()
xAPBSC.info is only used when no data has been seen for a timeout period when a change of value occurs that you wish to report you should use xAPBSC.event.
If you look at my Applet you would see that I only send an EVENT when the DATA is different. This is how BSC works.
if ep.text ~= value then ep:setText(value) ep:sendEvent() endThis is an important point as you are violating the BSC schema specification with your code. Yes it might work but its not kosher.
Brett
Member for
14 years 8 monthsHmm... ok, will change it
Hmm... ok, will change it into a kosher code
Member for
13 years 11 monthsDecode TX3-TH signal on arduino
Hi all, hi vores8, I'm planning to buy TX3-TH sensors to interface them with an Arduino. I made some research on the web to check if it has been done before, because I don't have the skills to do the reverse engineering myself. I found one project implementing the TX3 decoding : http://code.google.com/p/arduinoha/ and TH4 decoding https://github.com/kjordahl/Arduino-Weather-Station/ and I found this TX3 protocol description http://www.f6fbb.org/domo/sensors/tx3_th.php
Do you think I will be able to decode TX3 sensor with that ? One thing I can't figure out is : what if two sensor send a packet at the same time ? How did you handle the concurrent computing ? Did you write your own decoding library and maybe could you share it ?
Thanks in advance for your answer,
Johan
Member for
17 yearsFire and forget
>One thing I can't figure out is : what if two sensor send a packet at the same time ?
If two of these units happen to transmit at the very same time, the resulting signals will interfere with each other and the receiver won't get a message that it can decode. Fortunately, the transmissions are generally repeated a few times and more often than not, a valid message will get thru.
If you need 'reliable' messaging then you should use a bi-directional transceiver (e.g. http://www.dbzoo.com/livebox/hah_hahnode). These can request that a device send some readings. If the expected reading is not received, you can ask for a re-send.
I know that KevinT did some work with units like these TX3. See his writeup at http://netcompsys.wordpress.com/
Cheers,
Derek.
Member for
13 years 11 monthsOk, thanks for your answer. I
Ok, thanks for your answer. I am making the design of a controlling system for my electric heaters, and I was considering buying temperature wireless probes to report temperatures from the rooms instead of using 1-wire probes. As you say, I think it's not important if some messages are dropped.
But for the moment I don't have the skills of making the whole reverse engineering process myself. However thank you for the links, I didn't know the JeeNode solution.
Cheers.