EthernetGateway - Radio init fail

  • Just starting out on MySensors and have a ENC28J60 and a NRF24L01+ module on a Arduino Uno

    I've wired it up as per the building ethernet gateway section - double checked all the wires with a multimeter.

    Running Arduino 1.6.5
    If I run the ino code (I've commended out the relevant sections for the ENC28J60 module) I get this:

    0;0;3;0;9;radio init fail

    I then tried a seperate ENC28J60 library and it gets a DHCP address so I know the 3.3V and wiring there is working.

    Also tried the RF24 library with the gettingstarted sketch and get this - which looks right:

    STATUS		 = 0x0e RX_DR=0 TX_DS=0 MAX_RT=0 RX_P_NO=7 TX_FULL=0
    Data Rate	 = 1MBPS
    Model		 = nRF24L01+
    CRC Length	 = Disabled
    PA Power	 = PA_LOW

    So I think the wiring for the radio module is correct.

    Any ideas why I get this radio init fail error?

    I'm using a stable PSU to generate the 3.3V with a smoothing cap on the power lines of the radio.

  • replace with this and try

    MyTransportNRF24 transport(RADIO_CE_PIN,RADIO_SPI_SS_PIN, RF24_PA_LEVEL_GW);

  • I already have that in place.

    MyTransportNRF24 transport(RADIO_CE_PIN, RADIO_SPI_SS_PIN, RF24_PA_LEVEL_GW);

  • Another noob here getting same error. Also not finding gateway on my specified port 5003

    Have port fwd the internal IP and reserved it in router.
    Using the V3 of the ethernet shield
    IDE is 1.6.5
    Board is a UNO
    Have a 10uF cap between GND and 3.3V

  • I found it very unstable - sometime it connects and other times it gives radio fail.

    When it does work after 5 mins if I telnet to port 5003 its no longer listening so have to restart the Uno.

    Haven't found a fix yet 😞

  • Admin


    Did you get a chance to try the development brach version of the ENC gateway? Should give more free memory and somewhat better behavior.

  • Nope - haven't tried that. Will give it a bash and let you know how it goes.

    I'm trying this:

    What am I missing?

    void setup()
    void loop() {

  • I've tried the above code - but after compiling and uploading I am unable to ping the gateway.

    If I go back to the stable code it pings fine.

    Are there any settings I'm supposed to change on the dev code for the ENC28J60?

  • Admin

    I did actually verify the ENC gatetaway a couple of weeks ago using the dev-branch. Never tried ping:ing it though. Not sure it support ICMP.

    What happens if you just try connection to the port using telnet or nc?

    Do you power it enough? Had to connect mine to the old lab power supply before it behaved.

  • Can't telnet to the port 5003 either. Can't think what could be the issue.

    I have a 10u cap on with a stable 3.3V. Going back to master branch works each time.

  • Admin


    Not sure why it works better in master than dev branch for you.

    Did you try switching power source? The ENC module can draw up to 250mA...

  • +1 on the separate power for the radio... I had all kinds of radio failures until I powered it separate from the UNO+ENC shield. Once I did, zero failures ever on the radio.

    also, I had a lot of trouble getting my Ethernet GW stabilized. it would run for maybe a day and then quit responding to pings or any network traffic. I found this thread -> ( and used the alternate implementation of UIPEthernet in it and my GW just crashed yesterday for the first time in two months! (although, I can crash it, at will, by telnetting into it and typing "junk".. so I don't do that 🙂 )

    @hek - I didn't know there was a ENC specific GW branch. that's great! Is it stable enough to try? does it have the improvements in the thread above to the UIPEthernet library?

  • After trying all sorts of things for a few days I eventually gave up and got the nodemcu board. Connected to the radio board and its been rock stable for the past 12 hours.

    Steve, I also had the same issue with it crashing when doing a manual telnet and typing junk in. Guess its not a good way to test. 🙂

    I've never had much luck with the ENC28J60 board on other arduino projects. They just don't like me. I might retry again on a rainy day with the alternative uipethernet implementation and see how it goes but for now its ESP8266 for me.

  • My Uno with the enc28j60 shield is more stable, but still not THAT stable. Will go a week, sometimes two without crashing. Now it just locks up for no apparent reason. Haven't had a chance to troubleshoot it. interestingly, it always locks up now at a time when the 'receive' (green) LED is lit, so something about receiving a message over the radio is locking it up...

    I tried using the wiznet shield, but so far I've gotten two bad ones (even the built-in Arduino samples don't work), so I don't put much stock in them any more.

    I have been planning to swap out my enc28j60 shield for just the little detached module and see if that helps. Just amazes me as much as folks have banged on this stuff for all this time, that it's still unstable, but I guess each one is different, knock-offs, etc.

Log in to reply

Suggested Topics