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
  1. Home
  2. General Discussion
  3. Orange PI zero. Problem running the gateway

Orange PI zero. Problem running the gateway

Scheduled Pinned Locked Moved General Discussion
9 Posts 3 Posters 3.1k Views 3 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    moskovskiy82
    wrote on last edited by
    #1

    Have followed the instructions on creating the orange pi zero gateway.
    The only difference - i am running a dietPi OS (couldn't install armbian).
    Wired all as recommended and also have added the IRQ pin (GPIO10)

    Strangely enough didn't have to alter the bin2fex /boot/script.bin /tmp/orange.fex as it already contained the necessary information.

    Ran the config with the following options
    ./configure --spi-spidev-device=/dev/spidev1.0 --my-transport=nrf24 --my-rf24-ce-pin=2 --my-rf24-cs-pin=13 --my-rf24-irq-pin=10 --my-gateway=ethernet --my-port=5003

    Everything compiled but upon launching got the

    # sudo ./bin/mysgw -d
    mysgw: Starting gateway...
    mysgw: Protocol version - 2.2.0-beta
    mysgw: MCO:BGN:INIT GW,CP=RNNG--Q-,VER=2.2.0-beta
    mysgw: TSF:LRT:OK
    mysgw: TSM:INIT
    mysgw: TSF:WUR:MS=0
    mysgw: Could not open /sys/class/gpio/gpio10/direction
    

    Tried

    #echo "10" |sudo tee /sys/class/gpio/export
    10
    tee: /sys/class/gpio/export: Device or resource busy
    

    Any ideas on this would be much appreciated...

    1 Reply Last reply
    0
    • M Offline
      M Offline
      moskovskiy82
      wrote on last edited by
      #2

      Tried to compile without IRQ pin. So there is no communication with the radio (tried different radio modules).
      Seems some problem with GPIO pins on DietPI?

      1 Reply Last reply
      0
      • M Offline
        M Offline
        moskovskiy82
        wrote on last edited by
        #3
        # gpio readall
         +-----+-----+----------+------+---+-Orange Pi+---+---+------+---------+-----+--+
         | BCM | wPi |   Name   | Mode | V | Physical | V | Mode | Name     | wPi | BCM |
         +-----+-----+----------+------+---+----++----+---+------+----------+-----+-----+
         |     |     |     3.3v |      |   |  1 || 2  |   |      | 5v       |     |     |
         |  12 |   8 |    SDA.0 | ALT5 | 0 |  3 || 4  |   |      | 5V       |     |     |
         |  11 |   9 |    SCL.0 | ALT5 | 0 |  5 || 6  |   |      | 0v       |     |     |
         |   6 |   7 |   GPIO.7 | ALT3 | 0 |  7 || 8  | 1 | OUT  | TxD3     | 15  | 13  |
         |     |     |       0v |      |   |  9 || 10 | 0 | ALT5 | RxD3     | 16  | 14  |
         |   1 |   0 |     RxD2 | ALT5 | 0 | 11 || 12 | 0 | ALT3 | GPIO.1   | 1   | 110 |
         |   0 |   2 |     TxD2 | ALT5 | 0 | 13 || 14 |   |      | 0v       |     |     |
         |   3 |   3 |     CTS2 | ALT3 | 0 | 15 || 16 | 0 | ALT3 | GPIO.4   | 4   | 68  |
         |     |     |     3.3v |      |   | 17 || 18 | 0 | ALT3 | GPIO.5   | 5   | 71  |
         |  64 |  12 |     MOSI | ALT4 | 0 | 19 || 20 |   |      | 0v       |     |     |
         |  65 |  13 |     MISO | ALT4 | 0 | 21 || 22 | 0 | OUT  | RTS2     | 6   | 2   |
         |  66 |  14 |     SCLK | ALT4 | 0 | 23 || 24 | 0 | ALT4 | CE0      | 10  | 67  |
         |     |     |       0v |      |   | 25 || 26 | 0 | ALT3 | GPIO.11  | 11  | 21  |
         |  19 |  30 |    SDA.1 | ALT4 | 0 | 27 || 28 | 0 | ALT4 | SCL.1    | 31  | 18  |
         |   7 |  21 |  GPIO.21 | ALT3 | 0 | 29 || 30 |   |      | 0v       |     |     |
         |   8 |  22 |  GPIO.22 | ALT3 | 0 | 31 || 32 | 0 | ALT3 | RTS1     | 26  | 200 |
         |   9 |  23 |  GPIO.23 | ALT3 | 0 | 33 || 34 |   |      | 0v       |     |     |
         |  10 |  24 |  GPIO.24 |  OUT | 1 | 35 || 36 | 0 | ALT3 | CTS1     | 27  | 201 |
         |  20 |  25 |  GPIO.25 |  OUT | 1 | 37 || 38 | 0 | ALT5 | TxD1     | 28  | 198 |
         |     |     |       0v |      |   | 39 || 40 | 0 | ALT5 | RxD1     | 29  | 199 |
         +-----+-----+----------+------+---+----++----+---+------+----------+-----+-----+
         | BCM | wPi |   Name   | Mode | V | Physical | V | Mode | Name     | wPi | BCM |
         +-----+-----+----------+------+---+-Orange Pi+---+------+----------+-----+-----+
        
        1 Reply Last reply
        0
        • gohanG Offline
          gohanG Offline
          gohan
          Mod
          wrote on last edited by
          #4

          try reinstalling wiringPi if you have updated the firmware after it was installed

          1 Reply Last reply
          0
          • M Offline
            M Offline
            moskovskiy82
            wrote on last edited by moskovskiy82
            #5

            I took the plunge. And now ready to give up.

            Got out another sd card. Installed fresh armbian.

            Ubuntu server – legacy kernel

            Did nothing else to the installation. Than followed the guide step by step. No deviations. The only part that it is not clear in the manual - about configure options. I believe some will first run
            ./configure --spi-spidev-device=/dev/spidev1.0 --my-transport=nrf24 --my-rf24-ce-pin=2 --my-rf24-cs-pin=13

            and then run
            ./configure --my-gateway=ethernet --my-port=5003

            Won't this overwrite the first config file? So just ran the first one.

            And no success.

            mysgw: Starting gateway...
            mysgw: Protocol version - 2.2.0-beta
            mysgw: MCO:BGN:INIT GW,CP=RNNG----,VER=2.2.0-beta
            mysgw: TSF:LRT:OK
            mysgw: TSM:INIT
            mysgw: TSF:WUR:MS=0
            mysgw: !TSM:INIT:TSP FAIL
            mysgw: TSM:FAIL:CNT=1
            mysgw: TSM:FAIL:DIS
            mysgw: TSF:TDI:TSL
            mysgw: TSM:FAIL:RE-INIT
            mysgw: TSM:INIT
            mysgw: !TSM:INIT:TSP FAIL
            mysgw: TSM:FAIL:CNT=2
            mysgw: TSM:FAIL:DIS
            mysgw: TSF:TDI:TSL
            ^Cmysgw: Received SIGINT
            

            Put some more solder on the connectors of OrangePi. No success. Put a 10uF 50V capacitor on the nrf24 - no success.
            Maybe something has change in the inner workings?

            P.S. On fresh armbian
            root@orangepizero:~/MySensors# gpio readall
            -bash: gpio: command not found

            1 Reply Last reply
            0
            • gohanG Offline
              gohanG Offline
              gohan
              Mod
              wrote on last edited by
              #6

              you have to enable SPI in the dietconfig I think, the ./configure needs to be one single command and you need to add wiringPi in the dietpi-software

              M 1 Reply Last reply
              0
              • gohanG gohan

                you have to enable SPI in the dietconfig I think, the ./configure needs to be one single command and you need to add wiringPi in the dietpi-software

                M Offline
                M Offline
                moskovskiy82
                wrote on last edited by
                #7

                @gohan Thanks for helping out. Is SPI supposed to be enabled? Doesn't state it anywhere. Will try it out.
                Yes i also believe ./configure shoul be one line - it's just that documentation is not that clear for not tech guys like me. So if maintainer of the page is reading this - it should be better done like for the Raspberry gateway page. It's more clear.

                Will try the SPI - hope it helps.

                P.S. Have just reconnected the radio to my RPi3... So it's not necessary problem with myself ;) Will try to update the topic with OrangePi struggle

                RPI3 output

                sudo ./bin/mysgw -d
                mysgw: Config file /etc/mysensors.dat does not exist, creating new config file.
                mysgw: Starting gateway...
                mysgw: Protocol version - 2.2.0-beta
                mysgw: MCO:BGN:INIT GW,CP=RNNG----,VER=2.2.0-beta
                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: Listening for connections on 0.0.0.0:5003
                mysgw: MCO:BGN:STP
                mysgw: MCO:BGN:INIT OK,TSP=1
                
                mfalkviddM 1 Reply Last reply
                0
                • gohanG Offline
                  gohanG Offline
                  gohan
                  Mod
                  wrote on last edited by
                  #8

                  Since you are using a SPI device, you need to enable SPI on the operating system, that's what I did for my rpi3 so I'm expecting the same for the orange pi

                  1 Reply Last reply
                  1
                  • M moskovskiy82

                    @gohan Thanks for helping out. Is SPI supposed to be enabled? Doesn't state it anywhere. Will try it out.
                    Yes i also believe ./configure shoul be one line - it's just that documentation is not that clear for not tech guys like me. So if maintainer of the page is reading this - it should be better done like for the Raspberry gateway page. It's more clear.

                    Will try the SPI - hope it helps.

                    P.S. Have just reconnected the radio to my RPi3... So it's not necessary problem with myself ;) Will try to update the topic with OrangePi struggle

                    RPI3 output

                    sudo ./bin/mysgw -d
                    mysgw: Config file /etc/mysensors.dat does not exist, creating new config file.
                    mysgw: Starting gateway...
                    mysgw: Protocol version - 2.2.0-beta
                    mysgw: MCO:BGN:INIT GW,CP=RNNG----,VER=2.2.0-beta
                    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: Listening for connections on 0.0.0.0:5003
                    mysgw: MCO:BGN:STP
                    mysgw: MCO:BGN:INIT OK,TSP=1
                    
                    mfalkviddM Offline
                    mfalkviddM Offline
                    mfalkvidd
                    Mod
                    wrote on last edited by
                    #9

                    @moskovskiy82 said in Orange PI zero. Problem running the gateway:

                    Yes i also believe ./configure shoul be one line - it's just that documentation is not that clear for not tech guys like me. So if maintainer of the page is reading this - it should be better done like for the Raspberry gateway page. It's more clear.

                    I've updated the Orange Pi page. Thanks for catching this.

                    1 Reply Last reply
                    0

                    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
                    Reply
                    • Reply as topic
                    Log in to reply
                    • Oldest to Newest
                    • Newest to Oldest
                    • Most Votes


                    9

                    Online

                    12.0k

                    Users

                    11.2k

                    Topics

                    113.4k

                    Posts


                    Copyright 2025 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
                    • Login

                    • Don't have an account? Register

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