Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
E

ElCheekytico

@ElCheekytico
About
Posts
16
Topics
3
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Nodemanage + EasyPCB Sleep
    E ElCheekytico

    @user2684 Thanks for the confirmation. Now I'm just not sure if I have enough IO pins without wiring directly from pro mini.

    @sundberg84 how many IO pins are actually available on easypcb rev10 without wiring directly from pro mini? I'm using D3 for PIR, A4/A5 for oled i2c, and D5 for DHT22. I think A0 is for battery voltage and D2 for RFM69. Maybe D6 and A1?

    NodeManager

  • Nodemanage + EasyPCB Sleep
    E ElCheekytico

    @user2684 The MCP1702 appears to be a voltage regulator. Are you running a higher input voltage? I am running a pro mini on the easyPCB powered by 2xAA. All the DHT22, PIR, and SSD1306 are all powered at 3.3v. My idea was to use a 2n2222a with base to D6 and E to ground and C negative of sensors. Based on a forum post or issue on your github I saw that we can pass in -1 for the ground pin of the PowerManager constructor and of course 6 would be the power pin. Does this sound like it will work?

    NodeManager

  • Nodemanage + EasyPCB Sleep
    E ElCheekytico

    @sundberg84 said in Nodemanage + EasyPCB Sleep:

    @ElCheekytico sorry - I do not know the software and how this works, but if you power a display and other sensors through VCC it will still consume power. One option (if the do not use to high current) is to power them through a digital pin and set this pin to high or low before sleep to make them shut down completley., Not sure if this is possible with a display since it maybe takes quite much current (???).

    I wondered about that as well. My thinking has been going down the path of using a transistor and triggering it from the IO pin.

    NodeManager

  • Nodemanage + EasyPCB Sleep
    E ElCheekytico

    @user2684 @sundberg84

    I am currently using Nodemanager 1.8dev, MySensors 2.3.1. I have built a battery sensor using EasyPCB rev10 with SSD1306, DHT22, and motion sensor. By all accounts it appears to go to sleep according to debug logging, but at least the display does not turn off which leads me to believe the DHT and motion sensor are also consuming power. I have them wired to the 3.3v and GND rows on the EasyPCB. Below is my current sketch.

    /**********************************
     * MySensors node configuration
     */
    
    // General settings
    #define SKETCH_NAME "NodeManager TempHumMotionDisplayBatteryNode"
    #define SKETCH_VERSION "1.0"
    
    #define MY_DEBUG
    #define MY_DEBUG_VERBOSE_RFM69
    
    // Enable and select radio type attached
    #define MY_RADIO_RFM69
    
    // Define this to enable the improved RFM69 driver
    #define MY_RFM69_NEW_DRIVER
    
    // The frequency to use.
    #define MY_RFM69_FREQUENCY RFM69_915MHZ
    
    // Define this if you are using the RFM69HW
    #define MY_IS_RFM69HW
    
    // Advanced settings
    #define MY_BAUD_RATE 9600
    //#define MY_SMART_SLEEP_WAIT_DURATION_MS 500
    #define MY_SPLASH_SCREEN_DISABLED
    //#define MY_DISABLE_RAM_ROUTING_TABLE_FEATURE
    //#define MY_SIGNAL_REPORT_ENABLED
    
    /***********************************
     * NodeManager configuration
     */
    
    #define NODEMANAGER_DEBUG ON
    #define NODEMANAGER_INTERRUPTS ON
    #define NODEMANAGER_SLEEP ON
    #define NODEMANAGER_RECEIVE ON
    #define NODEMANAGER_DEBUG_VERBOSE ON
    #define NODEMANAGER_POWER_MANAGER ON
    #define NODEMANAGER_CONDITIONAL_REPORT OFF
    #define NODEMANAGER_EEPROM OFF
    #define NODEMANAGER_TIME OFF
    #define NODEMANAGER_RTC OFF
    #define NODEMANAGER_SD OFF
    #define NODEMANAGER_HOOKING OFF
    #define NODEMANAGER_OTA_CONFIGURATION OFF
    #define NODEMANAGER_SERIAL_INPUT OFF
    
    // import NodeManager library (a nodeManager object will be then made available)
    #include <MySensors_NodeManager.h>
    
    /***********************************
     * Add your sensors
     */
    
    //PowerManager power(5,6);
     
    #include <sensors/SensorBattery.h>
    SensorBattery battery;
    
    #include <sensors/SensorDHT22.h>
    SensorDHT22 dht22(5);
    
    #include <sensors/SensorMotion.h>
    SensorMotion motion(3);
    
    #include <sensors/DisplaySSD1306.h>
    DisplaySSD1306 ssd1306;
    
    /***********************************
     * Main Sketch
     */
    
    // before
    void before() {
    	
      /***********************************
       * Configure your sensors
       */
       
      // EXAMPLES:
      // report measures of every attached sensors every 15 minutes
      nodeManager.setReportIntervalMinutes(15);
      // set the node to sleep in 15 minutes cycles
      nodeManager.setSleepMinutes(15);
      // report battery level every 60 minutes
      battery.setReportIntervalMinutes(60);
      // power all the nodes through dedicated pins
      //nodeManager.setPowerManager(power);
    
      // call NodeManager before routine
      nodeManager.before();
    }
    
    // presentation
    void presentation() {
      // call NodeManager presentation routine
      nodeManager.presentation();
    }
    
    // setup
    void setup() {
      // call NodeManager setup routine
      nodeManager.setup();
    }
    
    // loop
    void loop() {
      // call NodeManager loop routine
      nodeManager.loop();
    }
    
    #if NODEMANAGER_RECEIVE == ON
    // receive
    void receive(const MyMessage &message) {
      // call NodeManager receive routine
      nodeManager.receive(message);
    }
    #endif
    
    #if NODEMANAGER_TIME == ON
    // receiveTime
    void receiveTime(unsigned long ts) {
      // call NodeManager receiveTime routine
      nodeManager.receiveTime(ts);
    }
    #endif
    
    

    Do i need to uncomment the below and set to an available IO pin

    //PowerManager power(5,6);
    

    and connect the each sensor's VCC to said IO pin?

    NodeManager

  • Values not presenting in DisplaySSD1306
    E ElCheekytico

    I have a motion sensor, DHT22, and DisplaySSD1306 connected. I am experiencing the same issue. The values are read from the sensors and sent to the controller. However, the display shows lines for battery, DHT22 temp and humidity, and motion, but they are showing 0 for values.

    NodeManager

  • Node unable to find parent
    E ElCheekytico

    @elcheekytico said in Node unable to find parent:

    Ok, Really dumb, I had MY_RFM69_IRQ_PIN connected to the radio's RESET instead of DI00. I was grasping at straws and went to re-do my antenna because they were about 3mm too short when I noticed the mis-wiring. Once I fixed that swapped 3.3v and Ground and troubleshot that for a minute before I realized it. Before trying to fix the antenna I thought maybe since I didn't have a sensor defined the battery level data wasn't enough.The node is now talking to the controller with the MockMySensors sketch.

    Thanks for your help guys.

    I cleared eeprom and went back to my battery sketch and all is well.

    Troubleshooting

  • Node unable to find parent
    E ElCheekytico

    @bgunnarb said in Node unable to find parent:

    @ElCheekytico
    I cannot find that you set your NODE_ID in the beginning of the sensor sketch.
    Since OpenHAB does not hand out node-id as far as I know (I do not use the MySensors binding in OpenHAB since I connect over mqtt) you have to set NODE_ID manually.

    Note: The GW does not assign node id either.

    In your sensor sketch, start by adding

    #define MY_NODE_ID   5
    

    for example and see if you are able to connect.

    @bgunnarb I found that OpenHAB does assign node ID's even though the controller feature table somewhere on this site says it does not.

    Troubleshooting

  • Node unable to find parent
    E ElCheekytico

    Ok, Really dumb, I had MY_RFM69_IRQ_PIN connected to the radio's RESET instead of DI00. I was grasping at straws and went to re-do my antenna because they were about 3mm too short when I noticed the mis-wiring. Once I fixed that swapped 3.3v and Ground and troubleshot that for a minute before I realized it. Before trying to fix the antenna I thought maybe since I didn't have a sensor defined the battery level data wasn't enough.The node is now talking to the controller with the MockMySensors sketch.

    Thanks for your help guys.

    Troubleshooting

  • Node unable to find parent
    E ElCheekytico

    @sundberg84 said in Node unable to find parent:

    @elcheekytico - hmm, I can not seems to parse your node log - but anyways, it seems like no reply is the major error code here so it seems like its an issue with the radio communication.

    How is your hardware setup. How do you power the node and gateway?
    How did you build the gateway? Is this one starting up correctly?
    I see you define alot of things in the gatewat sketch... seems a bit strange, but maybe thats right. Im not defining that much: https://github.com/sundberg84/HomeAutomation/blob/master/Sketches MySensors RFM69 radio/RFM69gw/Rfm69gw/Rfm69gw.ino

    #define MY_RFM69_CS_PIN 6
    

    I dont think EasyPCB RFM Edition is wired to D6 - do you use this for the gateway or only the node?

    @sundberg84 The node, Pro Mini 3.3v, is powered by battery, but i guess still by USB while debugging. The gateway has been powered by USB while debugging and a known good power supply. The gateway is Leonardo with Ethernet shield. The gateway is the only one with RFM pin defines

    @bgunnarb said in Node unable to find parent:

    @ElCheekytico
    I cannot find that you set your NODE_ID in the beginning of the sensor sketch.
    Since OpenHAB does not hand out node-id as far as I know (I do not use the MySensors binding in OpenHAB since I connect over mqtt) you have to set NODE_ID manually.

    Note: The GW does not assign node id either.

    In your sensor sketch, start by adding

    #define MY_NODE_ID   5
    

    for example and see if you are able to connect.

    @bgunnarb I had a test setup with ESP8266 as gateway and node before and didn't remember specifying a node ID as I though OpenHAB would handle it. I found some documentation that said otherwise. That being said, I adding a node id, but still no luck.

    Troubleshooting

  • Node unable to find parent
    E ElCheekytico

    I am trying to setup my first EasyPCB node and I am unable to get them online. Both Gateway and Node logs look OK to me other than the obvious failures. Gateway is configured in OpenHAB.

    Node battery sketch

    // Enable debug prints to serial monitor
    #define MY_DEBUG
    #define MY_DEBUG_VERBOSE_RFM69
    
    // Enable and select radio type attached
    #define MY_RADIO_RFM69
    
    // Define this to enable the improved RFM69 driver
    #define MY_RFM69_NEW_DRIVER
    
    // The frequency to use.
    #define MY_RFM69_FREQUENCY RFM69_915MHZ
    
    // Define this if you are using the RFM69HW
    #define MY_IS_RFM69HW
    
    #include <MySensors.h>
    
    int BATTERY_SENSE_PIN = A0;  // select the input pin for the battery sense point
    
    uint32_t SLEEP_TIME = 900000;  // sleep time between reads (seconds * 1000 milliseconds)
    int oldBatteryPcnt = 0;
    
    void setup()
    {
      // use the 1.1 V internal reference
    #if defined(__AVR_ATmega2560__)
      analogReference(INTERNAL1V1);
    #else
      analogReference(INTERNAL);
    #endif
    }
    
    void presentation()
    {
      // Send the sketch version information to the gateway and Controller
      sendSketchInfo("Battery Meter", "1.0");
    }
    
    void loop()
    {
      // get the battery Voltage
      int sensorValue = analogRead(BATTERY_SENSE_PIN);
    #ifdef MY_DEBUG
      Serial.println(sensorValue);
    #endif
    
      // 1M, 470K divider across battery and using internal ADC ref of 1.1V
      // Sense point is bypassed with 0.1 uF cap to reduce noise at that point
      // ((1e6+470e3)/470e3)*1.1 = Vmax = 3.44 Volts
      // 3.44/1023 = Volts per bit = 0.003363075
    
      int batteryPcnt = sensorValue / 10;
    
    #ifdef MY_DEBUG
      float batteryV  = sensorValue * 0.003363075;
      Serial.print("Battery Voltage: ");
      Serial.print(batteryV);
      Serial.println(" V");
    
      Serial.print("Battery percent: ");
      Serial.print(batteryPcnt);
      Serial.println(" %");
    #endif
    
      if (oldBatteryPcnt != batteryPcnt) {
        // Power up radio after sleep
        sendBatteryLevel(batteryPcnt);
        oldBatteryPcnt = batteryPcnt;
      }
      sleep(SLEEP_TIME);
    }
    

    Node log

    18:55:26.204 ->  
    18:55:26.204 ->  __  __       ____
    18:55:26.204 -> |  \/  |_   _/ ___|  ___ _ __  ___  ___  _ __ ___
    18:55:26.204 -> | |\/| | | | \___ \ / _ \ `_ \/ __|/ _ \| `__/ __|
    18:55:26.204 -> | |  | | |_| |___| |  __/ | | \__ \  _  | |  \__ \
    18:55:26.204 -> |_|  |_|\__, |____/ \___|_| |_|___/\___/|_|  |___/
    18:55:26.204 ->         |___/                      2.3.1
    18:55:26.204 -> 
    18:55:26.204 -> 16 MCO:BGN:INIT NODE,CP=RPNNA---,REL=255,VER=2.3.1
    18:55:26.204 -> 28 TSM:INIT
    18:55:26.204 -> 28 TSF:WUR:MS=0
    18:55:26.204 -> 30 RFM69:INIT
    18:55:26.204 -> 32 RFM69:INIT:PIN,CS=10,IQP=2,IQN=0
    18:55:26.204 -> 36 RFM69:PTX:LEVEL=5 dBm
    18:55:26.204 -> 38 TSM:INIT:TSP OK
    18:55:26.204 -> 40 TSM:FPAR
    18:55:26.204 -> 43 RFM69:SWR:SEND,TO=255,SEQ=0,RETRY=0
    18:55:26.204 -> 47 RFM69:CSMA:RSSI=-35
    ...
    18:55:26.378 -> 546 RFM69:CSMA:RSSI=-35
    18:55:26.378 -> 552 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK:
    18:55:28.366 -> 2562 !TSM:FPAR:NO REPLY
    18:55:28.810 -> 2564 TSM:FPAR
    18:55:28.810 -> 2566 RFM69:SWR:SEND,TO=255,SEQ=1,RETRY=0
    18:55:28.810 -> 2570 RFM69:CSMA:RSSI=-36
    ...
    18:55:28.912 -> 3069 RFM69:CSMA:RSSI=-35
    18:55:28.912 -> 3076 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK:
    18:55:30.906 -> 5085 !TSM:FPAR:NO REPLY
    18:55:30.906 -> 5087 TSM:FPAR
    18:55:31.317 -> 5089 RFM69:SWR:SEND,TO=255,SEQ=2,RETRY=0
    18:55:31.317 -> 5093 RFM69:CSMA:RSSI=-35
    18:55:31.317 -> 5097 RFM69:CSMA:RSSI=-35
    ...
    18:55:31.455 -> 5591 RFM69:CSMA:RSSI=-35
    18:55:31.455 -> 5597 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK:
    18:55:33.439 -> 7606 !TSM:FPAR:NO REPLY
    18:55:33.439 -> 7608 TSM:FPAR
    18:55:33.439 -> 7610 RFM69:SWR:SEND,TO=255,SEQ=3,RETRY=0
    18:55:33.852 -> 7614 RFM69:CSMA:RSSI=-35
    ...
    18:55:33.988 -> 8112 RFM69:CSMA:RSSI=-35
    18:55:33.988 -> 8118 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK:
    18:55:35.990 -> 10127 !TSM:FPAR:FAIL
    18:55:35.990 -> 10129 TSM:FAIL:CNT=1
    18:55:35.990 -> 10131 TSM:FAIL:DIS
    18:55:35.990 -> 10133 TSF:TDI:TSL
    18:55:35.990 -> 10135 RFM69:RSL
    18:55:46.444 -> 20140 TSM:FAIL:RE-INIT
    18:55:46.444 -> 20142 TSM:INIT
    18:55:46.444 -> 20144 RFM69:INIT
    18:55:46.444 -> 20146 RFM69:INIT:PIN,CS=10,IQP=2,IQN=0
    18:55:46.444 -> 20150 RFM69:PTX:LEVEL=5 dBm
    18:55:46.444 -> 20152 TSM:INIT:TSP OK
    18:55:46.444 -> 20156 TSM:FPAR
    18:55:46.444 -> 20158 RFM69:SWR:SEND,TO=255,SEQ=0,RETRY=0
    

    Ethernet gateway sketch

    // Enable debug prints to serial monitor
    #define MY_DEBUG
    #define MY_DEBUG_VERBOSE_RFM69
    
    // Enable and select radio type attached
    #define MY_RADIO_RFM69
    
    // Define this to enable the improved RFM69 driver
    #define MY_RFM69_NEW_DRIVER
    
    // The frequency to use.
    #define MY_RFM69_FREQUENCY RFM69_915MHZ
    
    // Define this if you are using the RFM69HW
    #define MY_IS_RFM69HW
    
    // RFM69 SPI chip select pin
    #define MY_RFM69_CS_PIN 6
    
    // Define this to override the default RFM69 IRQ pin assignment
    #define MY_RFM69_IRQ_PIN 2
    
    // RFM69 IRQ number
    #define MY_RFM69_IRQ_NUM 1
    
    // Enable gateway ethernet module type
    #define MY_GATEWAY_W5100
    
    // Enable UDP communication
    //#define MY_USE_UDP  // If using UDP you need to set MY_CONTROLLER_IP_ADDRESS below
    
    // Enable MY_IP_ADDRESS here if you want a static ip address (no DHCP)
    #define MY_IP_ADDRESS 192,168,60,200
    
    // If using static ip you can define Gateway and Subnet address as well
    #define MY_IP_GATEWAY_ADDRESS 192,168,60,1
    #define MY_IP_SUBNET_ADDRESS 255,255,255,0
    
    // Renewal period if using DHCP
    //#define MY_IP_RENEWAL_INTERVAL 60000
    
    // The port to keep open on node server mode / or port to contact in client mode
    #define MY_PORT 5003
    
    // Controller ip address. Enables client mode (default is "server" mode).
    // Also enable this if MY_USE_UDP is used and you want sensor data sent somewhere.
    //#define MY_CONTROLLER_IP_ADDRESS 192, 168, 60, 2
    
    // The MAC address can be anything you want but should be unique on your network.
    // Newer boards have a MAC address printed on the underside of the PCB, which you can (optionally) use.
    // Note that most of the Arduino examples use  "DEAD BEEF FEED" for the MAC address.
    #define MY_MAC_ADDRESS 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED
    
    #if defined(MY_USE_UDP)
    #include <EthernetUdp.h>
    #endif
    #include <Ethernet.h>
    #include <MySensors.h>
    
    void setup()
    {
      // Setup locally attached sensors
    }
    
    void presentation()
    {
      // Present locally attached sensors here
    }
    
    void loop()
    {
      // Send locally attached sensors data here
    }
    

    Gateway log

    1565 MCO:BGN:STP
    1565 MCO:BGN:INIT OK,TSP=1
    1566 TSM:READY:NWD REQ
    1566 RFM69:SWR:SEND,TO=255,SEQ=0,RETRY=0
    1568 RFM69:CSMA:RSSI=-102
    3569 TSF:MSG:SEND,0-0-255-255,s=255,c=3,t=20,pt=0,l=0,sg=0,ft=0,st=OK:
    359508 GWT:TSA:ETH OK
    359512 GWT:RFC:MSG=0;0;3;0;2;
    359514 GWT:RFC:MSG=
    539523 GWT:RFC:MSG=0;0;3;0;2;
    539525 GWT:RFC:MSG=
    542523 GWT:RFC:MSG=0;255;3;0;18;
    542525 GWT:RFC:MSG=
    542724 GWT:RFC:MSG=1;255;3;0;18;
    542724 !TSF:RTE:1 UNKNOWN
    542725 RFM69:SWR:SEND,TO=1,SEQ=1,RETRY=0
    542726 RFM69:CSMA:RSSI=-103
    544927 !RFM69:SWR:NACK
    544927 RFM69:SWR:SEND,TO=1,SEQ=2,RETRY=1
    544929 RFM69:CSMA:RSSI=-107
    547129 !RFM69:SWR:NACK
    547129 RFM69:SWR:SEND,TO=1,SEQ=2,RETRY=2
    547131 RFM69:CSMA:RSSI=-102
    549331 !RFM69:SWR:NACK
    549331 RFM69:SWR:SEND,TO=1,SEQ=2,RETRY=3
    549334 RFM69:CSMA:RSSI=-100
    551534 !RFM69:SWR:NACK
    551534 RFM69:SWR:SEND,TO=1,SEQ=2,RETRY=4
    551536 RFM69:CSMA:RSSI=-99
    553736 !RFM69:SWR:NACK
    553736 RFM69:SWR:SEND,TO=1,SEQ=2,RETRY=5
    553738 RFM69:CSMA:RSSI=-102
    555938 !RFM69:SWR:NACK
    555938 !TSF:MSG:SEND,0-0-1-1,s=255,c=3,t=18,pt=0,l=0,sg=0,ft=0,st=NACK:
    555939 GWT:RFC:MSG=
    

    @sundberg84 Any thought? I'm using rev10.

    Troubleshooting

  • Leonardo/RFM69HW ethernet gateway not working
    E ElCheekytico

    I did manage to get this to work this morning. As I mentioned, I have a Freaduino Leonardo clone. This has a selector switch for 3.3v and 5v IO. I decided to go back and try with it at 3.3v and not use logic converters. It also has a ICSP breakout for SPI/IIC. I re-wired this thing many times, but was only able to get it to work when I wired it directly to the ICSP breakout and used the VCC/ground on the ICSP breakout as well. I tried the 3.3v on from one of the other pins on the board and 3.3v from a breadboarded power supply. Maybe it's something more simple that I just don't understand or missed, but it doesn't make sense to me. I made sure the 3.3v was there with each wiring change.

    I did however set the following:

    // RFM69 SPI chip select pin
    #define MY_RFM69_CS_PIN 6
    
    // Define this to override the default RFM69 IRQ pin assignment
    #define MY_RFM69_IRQ_PIN 2
    
    // RFM69 IRQ number
    #define MY_RFM69_IRQ_NUM 1
    

    And the log shows:

    565 GWT:TIN:IP=192.168.0.75
    1565 MCO:BGN:STP
    1566 MCO:BGN:INIT OK,TSP=1
    1566 TSM:READY:NWD REQ
    1566 RFM69:SWR:SEND,TO=255,SEQ=0,RETRY=0
    1568 RFM69:CSMA:RSSI=-97
    3569 TSF:MSG:SEND,0-0-255-255,s=255,c=3,t=20,pt=0,l=0,sg=0,ft=0,st=OK:
    

    I know @Carywin mentioned extending the ICSP connector through the shield and used that. Maybe that's why it worked for him.

    Troubleshooting

  • Leonardo/RFM69HW ethernet gateway not working
    E ElCheekytico

    @carywin said in Leonardo/RFM69HW ethernet gateway not working:

    I got this working here: https://forum.mysensors.org/topic/6249/mqtt-ethernet-gateway-using-leonardo-32u4-w5100-rfm69h-hard-spi

    @Carywin Have you tried with the new rfm69 driver? From what I have read this should support SPI transactions.

    Troubleshooting

  • Leonardo/RFM69HW ethernet gateway not working
    E ElCheekytico

    @elcheekytico said in Leonardo/RFM69HW ethernet gateway not working:

    @mfalkvidd I wasn't sure on how to do that. I saw that setup for NRF radios, but couldn't figure it how to apply that with RFM radios and what defines to use and such.

    @mfalkvidd I just found the API docs for soft SPI. I'll give that a try tonight or in the next couple days.

    Troubleshooting

  • Leonardo/RFM69HW ethernet gateway not working
    E ElCheekytico

    @mfalkvidd I wasn't sure on how to do that. I saw that setup for NRF radios, but couldn't figure it how to apply that with RFM radios and what defines to use and such.

    Troubleshooting

  • Leonardo/RFM69HW ethernet gateway not working
    E ElCheekytico

    I am having trouble building an ethernet gateway with RFM69HW. I have several radios and used them with an ESP8266 gateway so I know they work. It kept dropping off the network every so often to I want to move to wired. I have Freaduino Leonardo clone and clone 5100 shield and I borrowed a genuine Uno and clone 5100 shield. I have wired everything up per the documentation and neither will work. If I comment out all the RFM lines the gateway comes online and I can ping it on either board/shield. With RFM enabled I get init failures. I have tried the with default wiring and defines and changed them up based on what I've read in other posts. I really need to get it working on the Leonardo as I will have to give back the Uno. I am using level converters as well.

    Here is the log from the Uno:

    0 MCO:BGN:INIT GW,CP=RPNGA---,REL=255,VER=2.3.1
    4 TSM:INIT
    5 TSF:WUR:MS=0
    6 RFM69:INIT
    7 RFM69:INIT:PIN,CS=6,IQP=2,IQN=0
    809 RFM69:PTX:LEVEL=5 dBm
    812 !RFM69:INIT:SANCHK FAIL
    815 !TSM:INIT:TSP FAIL
    817 TSM:FAIL:CNT=1
    818 TSM:FAIL:DIS
    820 TSF:TDI:TSL
    821 RFM69:RSL
    

    Here is the sketch:

    // Enable debug prints to serial monitor
    #define MY_DEBUG
    #define MY_DEBUG_VERBOSE_RFM69
    
    // Enable and select radio type attached
    #define MY_RADIO_RFM69
    
    // Enable gateway ethernet module type
    #define MY_GATEWAY_W5100
    
    // W5100 Ethernet module SPI enable (optional if using a shield/module that manages SPI_EN signal)
    //#define MY_W5100_SPI_EN 4
    
    // Define this to enable the improved RFM69 driver
    #define MY_RFM69_NEW_DRIVER
    
    // The frequency to use.
    #define MY_RFM69_FREQUENCY RFM69_915MHZ
    
    // Define this if you are using the RFM69HW
    #define MY_IS_RFM69HW
    
    // RFM69 SPI chip select pin
    #define MY_RFM69_CS_PIN 6
    
    // Define this to override the default RFM69 IRQ pin assignment
    //#define MY_RFM69_IRQ_PIN 7
    
    // Enable UDP communication
    //#define MY_USE_UDP  // If using UDP you need to set MY_CONTROLLER_IP_ADDRESS below
    
    // Enable MY_IP_ADDRESS here if you want a static ip address (no DHCP)
    #define MY_IP_ADDRESS 192,168,0,75
    
    // If using static ip you can define Gateway and Subnet address as well
    #define MY_IP_GATEWAY_ADDRESS 192,168,0,1
    #define MY_IP_SUBNET_ADDRESS 255,255,255,0
    
    // Renewal period if using DHCP
    //#define MY_IP_RENEWAL_INTERVAL 60000
    
    // The port to keep open on node server mode / or port to contact in client mode
    #define MY_PORT 5003
    
    // Controller ip address. Enables client mode (default is "server" mode).
    // Also enable this if MY_USE_UDP is used and you want sensor data sent somewhere.
    //#define MY_CONTROLLER_IP_ADDRESS 192, 168, 178, 254
    
    // The MAC address can be anything you want but should be unique on your network.
    // Newer boards have a MAC address printed on the underside of the PCB, which you can (optionally) use.
    // Note that most of the Arduino examples use  "DEAD BEEF FEED" for the MAC address.
    #define MY_MAC_ADDRESS 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED
    
    #if defined(MY_USE_UDP)
    #include <EthernetUdp.h>
    #endif
    #include <Ethernet.h>
    #include <MySensors.h>
    
    void setup()
    {
    	// Setup locally attached sensors
    }
    
    void presentation()
    {
    	// Present locally attached sensors here
    }
    
    void loop()
    {
    	// Send locally attached sensors data here
    }
    

    I am using Arduino IDE 1.8.4, Boards 1.6.23, and MySensors 2.3.1.

    I have tried older versions of Boards and MySensors to no avail.

    Please help.

    Troubleshooting

  • 💬 Easy/Newbie PCB for MySensors
    E ElCheekytico

    Hey, @sundberg84 , I am trying to order the rfm69 version from ITEAD and their M.Rev1 file I downloaded looks to be your v9. Can you upload the v10 to them so I may place an order?

    OpenHardware.io mysensors battery easy newbie pcb mysx
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular