I've had a really difficult time getting the two RFM69HCW breakouts I ordered to work. I've tried the RadioHead library as well as the LowPowerLab version and I'm getting nowhere. Anyway I found this post with the same symptom ("RFM69 radio init failed"). This poster was fortunate to find that it was just a wire problem, but I've replaced my wires and it persists. Just like this previous poster, I wired up the Uno like the example. I'm sure I'm doing something stupid somewhere, but I really need some help. I attached an image of my breadboard (I put the LED on there just to show that it should definitely be getting power). Thanks for any help you can provide.
Edit: Also, I may as well mention that I was trying to demo this simple sketch because I couldn't get the breakouts to work with another application - there is more information there as well.
RFM69HCW on Arduino Uno Not Initialising
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- highlifelight
- Posts: 8
- Joined: Fri Jul 12, 2019 12:48 pm
- highlifelight
- Posts: 8
- Joined: Fri Jul 12, 2019 12:48 pm
Re: RFM69HCW on Arduino Uno Not Initialising
I'm so worn out with this. I've spent the better part of the last two days testing every bit of code I could find for both RadioHead and LowPowerLab libraries. I've double and triple checked my connections. I've set up Arduino Pro Minis (3.3V of course_ and wired them accordingly. Nothing works. At what point does one decide that the two breakouts I received were defective? I'm just so tired of "init failed".
Edit: I'm going to outline what I'm (re)trying this morning. I'm using the "rf69 demo tx rx.pde" RadioHead RawDemo_RX sketch linked from the tutorial. I have an Arduino Pro Mini 3.3 connected as follows:
Arduino <->RFM69HCW Breakout
VCC <->VIN
GND <->GND
2 <->G0
13 <->SCK
12 <->MISO
11 <->MOSI
10 <->CS
9<->RST
When I run the sketch, I get the error 'RFM69_CS' was not declared in this scope, so I remove all the IFs and declare the variables matching my pin assignments:
And I compile successfully and upload and get the following in my console:
I run the exact same code with exact same jumper placement on my Uno (different breadboard, different jumper wire, different microcontroller) and I get this.
Edit: It's a new day, let's try again! I found this postwhich claims that you can't use pin 13 for LED because it's reserved for SCK. I changed arbitrarily to 4 to just get it to compile. No difference. I also found this post which claims removing "pinMode(RFM95_RST, OUTPUT);" from the sketch makes it work. Not for me. Also, adafruit_support_mike has some advice about increasing the delay, which doesn't work for me either.
Edit #2 for 7/15: I swapped the two breakouts and lo and behold, I got a message that init() actually worked and it said it was sending message #0, but it appeared to be frozen. I then uploaded the RX version of the sketch with the same pin assignments (without changing anything on the breadboard), and it was back to "RFM69 radio init failed". Then I felt really stupid and reuploaded the TX version, and it's back to "RFM69 radio init failed" as well. Switched the breakouts back, and fail fail fail. Everything fails. Hey, just for fun, here's a snapshot my breadboard when it accidentally didn't fail.
Edit: I'm going to outline what I'm (re)trying this morning. I'm using the "rf69 demo tx rx.pde" RadioHead RawDemo_RX sketch linked from the tutorial. I have an Arduino Pro Mini 3.3 connected as follows:
Arduino <->RFM69HCW Breakout
VCC <->VIN
GND <->GND
2 <->G0
13 <->SCK
12 <->MISO
11 <->MOSI
10 <->CS
9<->RST
When I run the sketch, I get the error 'RFM69_CS' was not declared in this scope, so I remove all the IFs and declare the variables matching my pin assignments:
Code: Select all
// Change to 434.0 or other frequency, must match RX's freq!
#define RF69_FREQ 915.0
#define RFM69_CS 10
#define RFM69_INT 2
#define RFM69_RST 9
#define LED 13
// Singleton instance of the radio driver
RH_RF69 rf69(RFM69_CS, RFM69_INT);
Code: Select all
Feather RFM69 RX Test!
12:20:28.489 ->
12:20:28.591 -> RFM69 radio init failed
Code: Select all
14:58:28.146 -> Feather RFM69 RX Test!
14:58:28.146 ->
14:58:28.282 -> RFM69 radio init failed
Edit #2 for 7/15: I swapped the two breakouts and lo and behold, I got a message that init() actually worked and it said it was sending message #0, but it appeared to be frozen. I then uploaded the RX version of the sketch with the same pin assignments (without changing anything on the breadboard), and it was back to "RFM69 radio init failed". Then I felt really stupid and reuploaded the TX version, and it's back to "RFM69 radio init failed" as well. Switched the breakouts back, and fail fail fail. Everything fails. Hey, just for fun, here's a snapshot my breadboard when it accidentally didn't fail.
- adafruit_support_carter
- Posts: 29473
- Joined: Tue Nov 29, 2016 2:45 pm
Re: RFM69HCW on Arduino Uno Not Initialising
You shouldn't need to change the wiring or the example code from what is shown. Wire per here:
https://learn.adafruit.com/adafruit-rfm ... ino-wiring
Download the library:
https://learn.adafruit.com/adafruit-rfm ... xample-9-4
and run the RadioHead69_RawDemo_TX demo:
https://learn.adafruit.com/adafruit-rfm ... e-code-9-8
and should get: If that still does not work, it may be connection related. Post another photo that better shows the soldering job on the header pins.
https://learn.adafruit.com/adafruit-rfm ... ino-wiring
Download the library:
https://learn.adafruit.com/adafruit-rfm ... xample-9-4
and run the RadioHead69_RawDemo_TX demo:
https://learn.adafruit.com/adafruit-rfm ... e-code-9-8
and should get: If that still does not work, it may be connection related. Post another photo that better shows the soldering job on the header pins.
- highlifelight
- Posts: 8
- Joined: Fri Jul 12, 2019 12:48 pm
Re: RFM69HCW on Arduino Uno Not Initialising
Thank you for reading and responding to my post. I followed the instructions exactly. The jumpers are identical to the linked diagram, and I ran the RadioHead69_RawDemo_TX demo sketch. This is the output.
I'll admit my soldering is poor, but there are no bridges and from what I can tell, there is good contact. These are the best pictures I could take with my phone, I apologize that they're a little blurry.
Code: Select all
13:06:45.693 -> Feather RFM69 TX Test!
13:06:45.693 ->
13:06:45.793 -> RFM69 radio init failed
- adafruit_support_carter
- Posts: 29473
- Joined: Tue Nov 29, 2016 2:45 pm
Re: RFM69HCW on Arduino Uno Not Initialising
It might be worth trying to touch up the soldering. It looks like maybe there's a chance they are not wetted out enough on the breakout pads.
https://learn.adafruit.com/adafruit-gui ... n-problems
I just wired one up to an UNO and tested everything. That's how I got the serial monitor output above. So it doesn't seem like there are any software issues.
https://learn.adafruit.com/adafruit-gui ... n-problems
I just wired one up to an UNO and tested everything. That's how I got the serial monitor output above. So it doesn't seem like there are any software issues.
- highlifelight
- Posts: 8
- Joined: Fri Jul 12, 2019 12:48 pm
Re: RFM69HCW on Arduino Uno Not Initialising
Okay, thank you, I will try to clean it up tonight and will report back.
- adafruit_support_carter
- Posts: 29473
- Joined: Tue Nov 29, 2016 2:45 pm
Re: RFM69HCW on Arduino Uno Not Initialising
OK, and also revert back to the wiring shown in the guide and the un-modified example sketch.
- highlifelight
- Posts: 8
- Joined: Fri Jul 12, 2019 12:48 pm
Re: RFM69HCW on Arduino Uno Not Initialising
Sorry for the delay - I did as you asked (my setup is identical to the diagram, save using the ground on the other side) and my results have not changed. I have a multimeter here, do you have any advice on how I should proceed? My brain hurts.
- adafruit_support_carter
- Posts: 29473
- Joined: Tue Nov 29, 2016 2:45 pm
Re: RFM69HCW on Arduino Uno Not Initialising
Post a photo of the new setup showing all the wiring connections.
Are you still getting the "RFM69 radio init failed" message?
Are you still getting the "RFM69 radio init failed" message?
- highlifelight
- Posts: 8
- Joined: Fri Jul 12, 2019 12:48 pm
Re: RFM69HCW on Arduino Uno Not Initialising
Yes, it's the same message. I wicked off and resoldered or just added solder to any of the joints that looked dodgy on both of my breakouts but both still fail.
Code: Select all
12:22:41.660 -> Feather RFM69 TX Test!
12:22:41.660 ->
12:22:41.759 -> RFM69 radio init failed
- Attachments
-
- 7-18.jpg (106.01 KiB) Viewed 734 times
- adafruit_support_carter
- Posts: 29473
- Joined: Tue Nov 29, 2016 2:45 pm
Re: RFM69HCW on Arduino Uno Not Initialising
Try running this sketch and post the output you get on the serial monitor:
Code: Select all
#include <SPI.h>
#define RFM69_CS 4
#define RFM69_RST 2
#define RH_RF69_REG_10_VERSION 0x10
#define RH_SPI_WRITE_MASK 0x80
void setup() {
Serial.begin(115200);
while (!Serial);
Serial.println("RFM69 Test!");
SPI.begin();
pinMode(RFM69_RST, OUTPUT);
digitalWrite(RFM69_RST, LOW);
pinMode(RFM69_CS, OUTPUT);
digitalWrite(RFM69_CS, LOW);
// manual reset
digitalWrite(RFM69_RST, HIGH);
delay(10);
digitalWrite(RFM69_RST, LOW);
delay(10);
// get info
digitalWrite(RFM69_CS, LOW);
SPI.transfer(RH_RF69_REG_10_VERSION & ~RH_SPI_WRITE_MASK);
uint8_t result = SPI.transfer(0x00);
digitalWrite(RFM69_CS, HIGH);
Serial.print("result = "); Serial.println(result);
}
void loop() {
}
- highlifelight
- Posts: 8
- Joined: Fri Jul 12, 2019 12:48 pm
Re: RFM69HCW on Arduino Uno Not Initialising
Breakout #1
Breakout #2
Code: Select all
13:47:56.028 -> RFM69 Test!
13:47:56.028 -> result = 0
13:48:05.898 -> RFM69 Test!
13:48:05.898 -> result = 0
Code: Select all
13:48:43.483 -> RFM69 Test!
13:48:43.483 -> result = 0
13:48:56.710 -> RFM69 Test!
13:48:56.710 -> result = 0
- adafruit_support_carter
- Posts: 29473
- Joined: Tue Nov 29, 2016 2:45 pm
Re: RFM69HCW on Arduino Uno Not Initialising
Bummer. 0 for both. This really seems to indicate some kind of wiring or other connection issue. Your wiring looks OK pin-wise. Maybe it's still the soldering? Can you post a good close up of current soldering on both of the breakouts.
- highlifelight
- Posts: 8
- Joined: Fri Jul 12, 2019 12:48 pm
Re: RFM69HCW on Arduino Uno Not Initialising
I took the time tonight and desoldered and removed the pins entirely. I took pictures of the process, but it probably doesn't matter. I resoldered new pins being very careful to do a cleaner job and to cover the pads entirely (although I hadn't cleaned off the flux when I took the picture). Still:adafruit_support_carter wrote:Bummer. 0 for both. This really seems to indicate some kind of wiring or other connection issue. Your wiring looks OK pin-wise. Maybe it's still the soldering? Can you post a good close up of current soldering on both of the breakouts.
Code: Select all
23:06:53.861 -> RFM69 Test!
23:06:53.861 -> result = 0
- Attachments
-
- 20190723_231121.jpg (88.24 KiB) Viewed 671 times
- adafruit2
- Posts: 22194
- Joined: Fri Mar 11, 2005 7:36 pm
Re: RFM69HCW on Arduino Uno Not Initialising
ok please setup one uno with the RFM69
use one color wire at a time. use red for power, black for ground, etc. don't have two wires with the same color. use only square-end jumpers, dont use the rubber-end jumpers
after you've wired it up, post another photo top down so we can clearly see the wiring.
use one color wire at a time. use red for power, black for ground, etc. don't have two wires with the same color. use only square-end jumpers, dont use the rubber-end jumpers
after you've wired it up, post another photo top down so we can clearly see the wiring.
Please be positive and constructive with your questions and comments.