Arduino UNO to RFM69HW - resetting on TX mode [SOLVED]

Started by modemnoise, January 13, 2015, 07:36:54 PM

modemnoise

I've been working on adopting the RFM69HW library for use in an Arduino sensor / gateway setup and hoping to get some needed direction. I'm pretty new to the environment and have been working through the data sheet and various examples out there, but I'm having an issue getting the transceiver set to TX opmode. It seems the default is set to standby, but as soon as I try to call the send method (and change to TX opmode) the Arduino basically hangs indefinitely, or eventually breaks out and restarts from the top of the loop. Some debugging shows that it never seems to come back from attempting modify the REG_OPMODE byte. The transceiver also gets noticeably hot to the touch during this time.

As far as I can tell, the registers seem fine - the program is trying to set the 0x01 reg location to 12 which looks right to me.

From what I can gather, this isn't an uncommon project, so I'm curious if anyone else had problems getting the radio to switch.

Wiring guide: http://www.instructables.com/file/FAPYCPXHZCIY2BG

Felix


modemnoise

I spent some time this afternoon attempting to run the "Node" example, as I believe that is where this project took its direction. When I upload the example Node, the program erratically gets stuck on the radio.initialize during the "Wait for ModeReady" loop. In cases where it hangs, it seems REG_IRQFLAGS1 is never set.

In other cases, it proceeds further and even correctly loops through the Send 123 ABCD....  for some time. In all test cases, it eventually hangs.

The example seems to get further than my program, but neither is exactly completing correctly for me. My first thought was a hardware connection, but all solders passed a continuity test. One of the members on the Arduino forum suggested a possible memory issue, but since I'm using similar code, I'm thinking that probably isn't the problem.

Felix

RFM69 is 3.3v, UNO is 5V, you need buffers to make that conversion, widely discussed in the forum previously.

modemnoise

Gotcha. Googled around a little bit and it looks like that's the problem. I ordered a couple level shifters and will report back.

Thanks for the tip!

modemnoise

Just wanted to report back for any others who may have had similar issues. It seems the voltage was exactly the issue. I purchased a bi-directional voltage leveler and hooked it up to the circuit and it immediately worked.

Thanks for your help Felix. I'm sure I'll be back if I have other troubles.

pustelnik

#6
Hello, I have a problem with two-way(duplex) communication between modules RFM69.
When a check on radio.receiveDone () and after I trying to send a packet, my Arduino Uno(clone) resets.
In secound Arduino Mega(my gateway) when i send packet, i cannot receive and send packet after and i must reboot rfm and arduino.
If i only send or retrive packet, all work correctly.

Gateway code(Arduino Mega): https://www.dropbox.com/s/nj6fr7f1v0nxccu/GatewayRFM69.ino?dl=0

Node code(Arduino Uno): https://www.dropbox.com/s/z2urttpojarwexg/NodeTemperatureRFM69.ino?dl=0

What is wrong?
PS. I use RFM69HW rfv2 868MHZ, and logic level conventer.