[SOLVED] Newbie trying to get RFM69HCW working with ATMEGA328P
-
Hi, first post here. I followed the tutorial to get RFM69HCW working on a raspberry pi and have set one up as a gateway.
I am now trying to get the RFM69HCW working with an ATMEGA328P
I have checked the wiring and I have D0 going to PIN 2 of the ATMEGA328PIn MySensors sketch, do I need to change anything?
I have changed the following
// Enable and select radio type attached
//#define MY_RADIO_NRF24
//#define MY_RADIO_NRF5_ESB
#define MY_RADIO_RFM69
//#define MY_RADIO_RFM95and I also added this
#define MY_RFM69_FREQUENCY RF69_433MHZ
#define MY_IS_RFM69HW -
Hi, first post here. I followed the tutorial to get RFM69HCW working on a raspberry pi and have set one up as a gateway.
I am now trying to get the RFM69HCW working with an ATMEGA328P
I have checked the wiring and I have D0 going to PIN 2 of the ATMEGA328PIn MySensors sketch, do I need to change anything?
I have changed the following
// Enable and select radio type attached
//#define MY_RADIO_NRF24
//#define MY_RADIO_NRF5_ESB
#define MY_RADIO_RFM69
//#define MY_RADIO_RFM95and I also added this
#define MY_RFM69_FREQUENCY RF69_433MHZ
#define MY_IS_RFM69HW -
Welcome to the MySensors community @gaz83!
That looks good (except that I think you wrote "not" instead of "now)". -
I have an RFM69HW running on a 328P. My code may help.
You didn't specify your clock rate but if it is a std board running at 3.3V it is probably 8Mhz.
The default DEBUG baud rate is 115k maybe a little too fast for the 8Mhz.
I lowered mine to 9600 because I can't read that fast anyway :)#define MY_DEBUG #define MY_BAUD_RATE (9600ul) // === Hardware / MySensors Initialization ================ // ======================================================== #define MY_RADIO_RFM69 #define MY_RFM69_FREQUENCY RFM69_915MHZ #include <MySensors.h> // === Node Initialization ================================ // ======================================================== #define CHILD_ID 5 #define sensortype S_MULTIMETER #define LEDPIN 9 //PB1 is pin 9 on ProMini #define LED_TST A0 #define NODE_TXT "Counting_test_Node" uint8_t MyCount; uint8_t ACK_Result; uint8_t NACK_Count; -
Had a look at your code and the only thing I spotted was in the frequency you had RFM69_915MHZ where as I was using RF69_433MHZ... I missed the M.
Tried again and still issues. Here is my monitor output, I am using the PassiveNode example sketch.
__ __ ____ | \/ |_ _/ ___| ___ _ __ ___ ___ _ __ ___ | |\/| | | | \___ \ / _ \ `_ \/ __|/ _ \| `__/ __| | | | | |_| |___| | __/ | | \__ \ _ | | \__ \ |_| |_|\__, |____/ \___|_| |_|___/\___/|_| |___/ |___/ 2.2.0 16 MCO:BGN:INIT NODE,CP=RRNPA---,VER=2.2.0 25 TSM:INIT 26 TSF:WUR:MS=0 78 !TSM:INIT:TSP FAIL 79 TSM:FAIL:CNT=1 81 TSM:FAIL:DIS 82 TSF:TDI:TSLThe tutorial doesn't mention anything about wiring the RS but I know on the adafruit version of RFM69HCW, you do need RS wired.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login