Ardunio n00b needs some help!



  • I am a network engineer and a pretty good scripter. so i'm fairly technically inclined.
    however I am new with Ardunio.
    I can solder, so i figured i would have a go at this project. but i can't seem to get off the ground
    I need a little push if someone wouldn't mind.

    I purchased.
    This Arduino uno r3 board
    http://www.ebay.com/itm/281548912985

    This Ardunio 5100 shield
    http://www.ebay.com/itm/121458024279

    And this Radio
    http://www.ebay.com/itm/121540572074

    I'm trying to just get the ethernet part of it working first.
    I have tried both codebender and the ardunio IDE
    The sketch verifies and it says it's uploads successfully.

    When i go to the device I hit reset on the enet shield and all the lights light up
    but i can not ping the device. the ardunio module vera also can not see it, but i'm obviously not surprised by that.

    The sketch i'm using is the example sketch at mysensors.org from the the enet gateway link.

    is there something I'm missing? have to change because of my board or shield?

    Thanks!
    Modify message



  • @mvader

    try moving the line

    gw.begin(RF24_PA_LEVEL_GW, RF24_CHANNEL, RF24_DATARATE, writeEthernet);
    

    between

    delay(1000);
    

    and

    server.begin();


  • I will give that a try tonight when i get home.
    Thanks for the reply!!



  • @mvader Could it be that the sketch freezes as you probably may not have used softspi?
    In the Ethernet sketch you'll find the info were to enable softspi.
    Both the radio and the ethernet shield are not able to share the hardware spi. Your ethernet shield keeps blinking. Try to monitor the gateway via serial. You should at least see the message that the gateway started.

    Succes!

    Boozz



  • @boozz said:

    @mvader Could it be that the sketch freezes as you probably may not have used softspi?
    In the Ethernet sketch you'll find the info were to enable softspi.
    Both the radio and the ethernet shield are not able to share the hardware spi. Your ethernet shield keeps blinking. Try to monitor the gateway via serial. You should at least see the message that the gateway started.

    Succes!

    Boozz

    is that something (monitoring) I can do with the aurdunio ide software?
    or do i need something else? My board has a micro usb port and i do have the correct drivers installed in windows.
    Thanks



  • @mvader yes it's in the Arduino IDE. See right above for the button to open the serial monitor. Make sure you select the right baudrate once the monitor has opened. Should be 115.200 by default I believe.

    BR
    Boozz



  • @boozz said:

    @mvader yes it's in the Arduino IDE. See right above for the button to open the serial monitor. Make sure you select the right baudrate once the monitor has opened. Should be 115.200 by default I believe.

    BR
    Boozz

    the port speed seemed to do the trick, thanks for that.
    sadly, i keep getting the
    0;0;3;0;9;check wires message
    I've removed the radio and the ethernet shield, recompiled and re-uploaded many times.
    still get the same message. even with the just the uno.
    the power is coming from my laptop usb port, I verified i'm seeing 3.3 and 5v on the uno
    using both code bender and arduino ide software, i get no errors during compile or upload.
    I also did try to edit and enable the softspi include file.
    again recompile/re-up
    still the same 0;0;3;0;9;check wires

    any suggestions?

    thanks!

    edit: just to make sure my process and equipment worked.
    i uploaded the "simple web server" sketch and it did indeed work
    so the board and shield seem to be good. I'm just having a problem getting the gateway code to work with it.



  • @mvader
    Did you enabled SOFTSPI in RF24_config.h?



  • @ericvdb If you enable SOFTSPI in the MySensors Library, does that also effect the Sensors or only the Gateway code? Is there anything different you would need to do for the Sensors?



  • @mvader said:

    0;0;3;0;9;check wires

    FYI: 0;0;3;0;9;check wires means that the wireless module cannot be initialized. When it starts up, it does a validation check, if that check fails, you will receive the "check wires" message.

    This means you either have the module wired incorrectly or you need to enable SOFTSPI as @ericvdb mentions.

    I just went through the exact same scenario and after about 2 days of tweaking, I finally got a "Started!" message.

    Hang in there, you'll get it. 🙂


  • Admin

    @Squint said:

    @ericvdb If you enable SOFTSPI in the MySensors Library, does that also effect the Sensors or only the Gateway code? Is there anything different you would need to do for the Sensors?

    SOFTSPI is a way to emulate SPI interface on some of the other digital inputs. This is a last resort thing used when one module can't behave correctly on the inteface (normally several devices can co-exists).

    It only affects the code you compile and upload (gateway in you case). You should change code back when gateway has been created unless you want to run SOFTSPI on your sensors as well.



  • @Squint said:

    @mvader said:

    0;0;3;0;9;check wires

    FYI: 0;0;3;0;9;check wires means that the wireless module cannot be initialized. When it starts up, it does a validation check, if that check fails, you will receive the "check wires" message.

    This means you either have the module wired incorrectly or you need to enable SOFTSPI as @ericvdb mentions.

    I just went through the exact same scenario and after about 2 days of tweaking, I finally got a "Started!" message.

    Hang in there, you'll get it. 🙂

    Very helpful. thank you for the info!!



  • @ericvdb said:

    @mvader
    Did you enabled SOFTSPI in RF24_config.h?

    I did.

    I'm assuming that the wireless card is just wired in wrong.
    Do you happen to know what file the pins are defined in?

    Appreciate all the responses and help.
    Getting the simple web server up and running was a good feeling. at least i'm on the right path (& have working hardware). I can move forward with the gateway...



  • @mvader :

    By wireless card you mean the radio (nrf24l01+) i guess...

    see here for the wiring.

    BR,

    Boozz



  • Just wanted to report back.
    I finally got the gateway working.
    I had my wires backwards.
    the screen shots show boards with white squares around each pin
    but my board had no white on it what so ever.
    so my guess at what was pin 1 (ground)
    turned out to be wrong.
    I had to view pics of the boards close up and then i realized my mistake.
    so step 1 - make the gateway work - completed!



  • @mvader can you please tell us how did u solved with this message 0;0;3;0;9;check wires? i get it when i try the SerialGateway on both Arduinos i have, Mega and Uno! What wires are wrong when only Arduino is connected to my laptop with the USB cable?
    Can you please explain more?
    Thanks!


  • Hero Member

    The "check wires" means that arduino can't communicate with nRF24L01+ radio.



  • @ewgor said:

    @mvader can you please tell us how did u solved with this message 0;0;3;0;9;check wires? i get it when i try the SerialGateway on both Arduinos i have, Mega and Uno! What wires are wrong when only Arduino is connected to my laptop with the USB cable?
    Can you please explain more?
    Thanks!

    I had my wires backwards. (they were not hooked up correctly)
    I would suggest verify your soldering work is good and that that wires are in the correct spot. could be a bad / burned up board as well. try switching radios and or ardunios.



  • @rvendrame i dont have any nRF24L01+ radio in my house, i just want to try this SerialGateway between my laptop and my Arduino! What wires to check, the USB cable? this is the only cable i have!
    Do i have to buy this device RF24L01 in order to see the SerialGateway working between my PC and Arduino?


  • Hero Member

    The mySensors runs on a radio mesh network:

    http://www.mysensors.org/about/components

    You need at least one gateway and one sensor/actuator node. Both with radios. You also need one controller (or computer) to process the messages.



  • OMG! so you say i cannot make this work without having this radio network ?
    this is so wrong, normally you should take it step by step as for example first to make a network only between a pc or a RPI and an Arduino and some sensors, actuators and later if needed to expand this network adding another arduino or so, i don't understand anymore.
    i all tutorials i saw, they were testing only with an Arduino on connected to a PC!

    I saw another post here about the EthernetGateway and they were speaking about changing some no of MISO, MOSI and SCK pins in the RF24_config.h file. I did this, but no result :(((
    I don't understand anymore ...



  • @ewgor said:

    OMG! so you say i cannot make this work without having this radio network ?
    this is so wrong, normally you should take it step by step as for example first to make a network only between a pc or a RPI and an Arduino and some sensors, actuators and later if needed to expand this network adding another arduino or so, i don't understand anymore.
    i all tutorials i saw, they were testing only with an Arduino on connected to a PC!

    I saw another post here about the EthernetGateway and they were speaking about changing some no of MISO, MOSI and SCK pins in the RF24_config.h file. I did this, but no result :(((
    I don't understand anymore ...

    respectfully you will need to do some more reading.
    the radios are very cheap and fairly easy to install. you don't need an entire network of them to get started, you will need to build a gateway (arduino and radio) and then build a sensor (with radio) and that is it to get started.



  • @mvader respectfully i read a lot of articles and a lot of post on this site and not only ... i just didn't understand that in order to make a serial link between Arduino board and my PC using Mysensors and SerialGateway i need to use this radio whatever device, the price is not why i'm concern, the principle of this solution is.
    Is there any other way to make a connection through serial between Arduino and Openhab server without using the radio module? i mean really, i don't understand (generally speaking) why to use a radio module if you don't need it at this point! i can connect any sensor directly to Arduino
    I have an 433 Mhz RF link kit, may i use this to make it work? if not, i need to choose other way.
    Using the Ethernet Gateway do i still need the radio module?

    My last chance it seems to be than a Mqtt connection ...


  • Admin

    @ewgor

    right on the frontpage of the mysensors page
    --- quote ---
    This is where all the fun happens!

    Learn how to create your own low cost wireless sensors and connect them to the world.
    --- end of quote ---

    This implies that you need a wireless radio network. Not to communicate with the arduino that you connect to the computer. But to speak with all your homebuild sensors on the sensor network that mysensors is all about. For this we use NRF24L01+ radio modules, together with arduino platform.

    So (a suggestion) head over to the mysensors.org page, and read the stuff there to get a better understanding about what this project is about.



  • @tbowmo i did understand about the principle of Mysensors. I posted already on some other topic here, i'm waiting for a couple of nRF24L01 in a few days (hopefully tomorrow i'll receive them) and i'll start testing.
    Thanks for your answer!



  • hi all,
    can anyone help me? i am trying to make a serial gateway with my arduinos. i have 2 arduino, a mega and an uno. now uploading the serial sketch on each one of them its ok, see on the serial monitor that the gateway is up and running. on the node point the serial monitor still shows check wires. i've switched the arduino between the gateway and the node point and still receiving this message check wires on the node point! can anyone help?
    on the openhab side, i have de serial jar file in the addons and i modified the string items with the right com for my arduino at 115200 baud rate. if i start the bat or sh files its working but i cannot see the connection with the gateway or the node point.
    could anyone who made it working help me please figure this out?
    thanks all.


  • Hero Member

    @ewgor how is the nrf connected? did you switch only the arduino or the arduino+nrf?
    check wire almost always means that the wiring is not right or that you have power problem.



  • @Moshe-Livne I switched both and separately, arduino and the nrf this meaning that both arduino works with both nrf. the 1st problem is the node point nrf connection to arduino. i searched on the net but non of the wiring diagrams found is not working (referring to the node point!). the 2nd problem is related to the openhab installed on my laptop (don't have raspberry ) and the gateway!
    where is the problem here? cant see! followed the instructions and only negative results....
    do i speak other strange language than english?



  • I've managed and now I have both (gateway and node) up and running.
    When I start the bat or sh openhab files the server receive info from my dht11 which is connected to the node. It also receive info from the openhab buttons but I cannot see the dht11 on the local host. I'm following TimO example (http://forum.mysensors.org/topic/655/serial-gateway-connection-to-openhab)!
    Can anybody explain where is the "sketch"?
    Thanks !


Log in to reply
 

Suggested Topics

14
Online

11.4k
Users

11.1k
Topics

112.7k
Posts