computourist / RFM69-MQTT-client

Arduino - RFM69 based sensors and MQTT gateway
GNU General Public License v2.0
81 stars 27 forks source link

Gateway stops functioning after a couple of polls/writes #1

Closed cub69 closed 9 years ago

cub69 commented 9 years ago

Hi, nice solution. I've built both the gateway and the node. The hardware I'm using is slightly different, I'm using arduino Mega 2560's, a different ethernet device - but the library (UIPethernet) is appartently 100% compatible with ethernet.h.
The gateway comes up and on my mosquito side I see it begin to send PINGREQ and getting PINGRESP. I bring up the node and it sends a dev99 and then the temp/humidity. I will see this publish if the gateway has not already gotten lost. After a few minutes the gateway just stops - no more ping requests, and no more forwarding of data. If I do a soft reset it comes back to life until it stops again. Any suggestions on how to figure this out? It most often stops after receiving sensor data, but has occasionally stopped without receiving it as well.

Thx

computourist commented 9 years ago

Hi Cub69,

This is probably a hardware problem. The interrupts are not handled well in the ethernet library. You have to disable/enable interrupts as described in the header of the sketch, otherwise interrupts from the RFM69 mess up. I myself never encountered such problems; my gateway/node has been running weeks at a time without problems. Others have had such ussues, and found solutions. Maybe the discussions on http://homeautomation.proboards.com/ are of use to you...

cub69 commented 9 years ago

thanks found the forum - looking at solutions.