Mysensors orange Pi SPI gateway



  • This post is deleted!

  • Mod

    Domoticz has mqtt support for MySensors, but id to make a proper mqtt mysensors gateway just to exclude something wrong in your chain. Do you have any spare esp8266 to use?



  • @gohan Now Ive changed my hardware to SPI according with this guide
    I have connected my NRF24 module (already checked on arduino) through SPI0 iface but something goes wrong again

    root@orangepipcplus:/MySensors#  ./bin/mysgw -d
    mysgw: Starting gateway...
    mysgw: Protocol version - 2.2.0
    mysgw: Serial port /dev/ttyUSB020 (115200 baud) created
    mysgw: MCO:BGN:INIT GW,CP=RNNGL---,VER=2.2.0
    mysgw: TSF:LRT:OK
    mysgw: TSM:INIT
    mysgw: TSF:WUR:MS=0
    mysgw: TSM:INIT:TSP OK
    mysgw: TSM:INIT:GW MODE
    mysgw: TSM:READY:ID=0,PAR=0,DIS=0
    mysgw: MCO:REG:NOT NEEDED
    mysgw: MCO:BGN:STP
    mysgw: MCO:BGN:INIT OK,TSP=1
    mysgw: TSF:MSG:READ,0-0-0,s=0,c=0,t=0,pt=0,l=0,sg=0:
    mysgw: !TSF:MSG:LEN,0!=7
    mysgw: TSF:MSG:READ,0-0-0,s=0,c=0,t=0,pt=0,l=0,sg=0:
    mysgw: !TSF:MSG:LEN,0!=7
    mysgw: TSF:MSG:READ,0-0-0,s=0,c=0,t=0,pt=0,l=0,sg=0:
    mysgw: !TSF:MSG:LEN,0!=7
    mysgw: TSF:MSG:READ,14-14-0,s=0,c=0,t=14,pt=0,l=1,sg=1:
    mysgw: !TSF:MSG:LEN,14!=32
    mysgw: TSF:MSG:READ,14-14-0,s=0,c=0,t=14,pt=0,l=1,sg=1:
    mysgw: !TSF:MSG:LEN,0!=32
    

    NRF24 link looks like working properly but next I see
    infinite messages LEN,0! that going very fast

    root@orangepipcplus:/MySensors# ./configure --spi-spidev-device=/dev/spidev0.0 --my-transport=nrf24 --my-rf24-ce-pin=6 
    --my-rf24-cs-pin=10 --my-gateway=serial --my-serial-is-pty --my-serial-pty=/dev/ttyUSB020 --my-rf24-irq-pin=5
    [SECTION] Detecting target machine.
      [OK] machine detected: SoC=unknown, Type=unknown, CPU=armv7l.
    [SECTION] Checking GPIO Sysfs.
      [OK] /sys/class/gpio/export found
    [SECTION] Detecting SPI driver.
      [OK] SPI driver detected:SPIDEV.
    [SECTION] Detecting init system.
      [OK] init system detected: systemd.
    [SECTION] Saving configuration.
    [SECTION] Cleaning previous builds.
    [OK] Finished.
    

    alt text
    Sure I know that GPIO H2 and H3 are different
    When I connecting IRQ wire - log has been ended at mysgw: MCO:BGN:INIT OK,TSP=1 and nothing more
    I have tried to change CE/CS pins numbers to wrong but log still the same. As if gpio not working


  • Mod

    Did you put a capacitor on nrf24 radio? Try the gw without -my-rf24-irq-pin=5
    I have no experience on the OrangePi platform, so I can't help much, that is why I was asking for ESP8266



  • @gohan of course I have capacitor connected 100uF (even 1000uF)
    I will try aftermorrow because my esp shield in my office
    Anyway its not a solution, only for testing...

    Without IRQ I have
    mysgw: TSF:MSG:READ,0-0-0,s=0,c=0,t=0,pt=0,l=0,sg=0:
    mysgw: !TSF:MSG:LEN,0!=7
    mysgw: TSF:MSG:READ,0-0-0,s=0,c=0,t=0,pt=0,l=0,sg=0:
    mysgw: !TSF:MSG:LEN,0!=7
    mysgw: TSF:MSG:READ,0-0-0,s=0,c=0,t=0,pt=0,l=0,sg=0:
    mysgw: !TSF:MSG:LEN,0!=7


  • Mod

    100uF is quite big, I bought a bag of 10uF ceramics and they work perfectly.



  • @gohan 10uF ceramic does not help


  • Mod


Log in to reply
 

Suggested Topics

37
Online

11.4k
Users

11.1k
Topics

112.6k
Posts