Duet3D Logo Duet3D
    • Tags
    • Documentation
    • Order
    • Register
    • Login

    RRF install failure with Hardkernel Odroid C4 as the SBC

    Scheduled Pinned Locked Moved Solved
    Firmware installation
    3
    13
    841
    Loading More Posts
    • 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.
    • Nurgelrotundefined
      Nurgelrot @Nurgelrot
      last edited by Nurgelrot

      @nurgelrot Talking to myself here.. running DuetControlServer -l trace tells me it's the GPIO transfer ready pin. But man I wish I understood how to pass it the right values. The "6" value above would only work if I'd compiled DCS linking to the WiringPI wrapper library. But '478' which is how the Odriod thinks of it doesn't work either so maybe this is a lost cause...

      1 Reply Last reply Reply Quote 0
      • Nurgelrotundefined
        Nurgelrot
        last edited by

        I got it... I love it when a plan comes together... Found the correct GPIO pin:

        #68 located in device /dev/gpiochip1

        thanks for putting up with my noise everyone 🙂

        If you have one of these SBC's feel free to hit me up if you run into issues.

        o_lampeundefined joekoundefined 2 Replies Last reply Reply Quote 2
        • o_lampeundefined
          o_lampe @Nurgelrot
          last edited by o_lampe

          @nurgelrot
          A while ago I asked about Odroid support and was linked to a readme file where all supported MPUs were listed. Odroid N2 was not.
          Did that change over time? Or did you make your own DSC image?

          Nurgelrotundefined 1 Reply Last reply Reply Quote 0
          • Nurgelrotundefined
            Nurgelrot @o_lampe
            last edited by Nurgelrot

            @o_lampe No I have it working now with both the Hardkernel Ubuntu release and the Armbian release for the C4. No extra compiling required. Just followed the guide on setting up an SBC for Duet and improvising as needed. Getting the buffersize for SPI is a little tricky as it wont pick it up from modprobe. you have to pass it as a boot time param in the bootargs of the kernel (spidev.bufsiz=8192)

            I'm really liking this board so far. Almost the same form factor as the pi3 just the HDMI port is moved and the power connector is different. Its 12v instead of 5 runs 15c cooler than the pi4 but still has the standard 5v outputs. Also has separate input for the tty console (in addition to UARTs on the 40pin) has option to hardwire to a PSU rather than the bulky barrel connector.

            No WiFi/BT though, but given my experiences with the WiFi in the Pi that might actually be a benefit... 4 USB3 ports so a wifi dongle is no big deal and works better than a built in one anyway. Has the option to run of an eMMC chip or an SD card so "disk" IO isn't an issue.

            Now I just have to run it for awhile and see if RRF play's nice with it.

            https://www.cnx-software.com/2020/04/24/raspberry-pi-4-vs-odroid-c4-features-comparison/

            1 Reply Last reply Reply Quote 0
            • joekoundefined
              joeko @Nurgelrot
              last edited by

              @nurgelrot said in RRF install failure with Hardkernel Odroid C4 as the SBC:

              I got it... I love it when a plan comes together... Found the correct GPIO pin:

              #68 located in device /dev/gpiochip1

              thanks for putting up with my noise everyone 🙂

              If you have one of these SBC's feel free to hit me up if you run into issues.

              hallo,
              i am going to do the same with a duet3 mini and a odroid c4. how you did this ? did you modify the cable or create an new one ?
              you wrote that gpio pin #64 is right. why is this the right pin ? i cant find this pin on the odroid wiki.

              Nurgelrotundefined 1 Reply Last reply Reply Quote 0
              • Nurgelrotundefined
                Nurgelrot @joeko
                last edited by Nurgelrot

                @joeko I find its easiest to use a linux distro that is still using the version 4.9 kernels. And you do not need any custom cable the one that comes with the Duet works fine.

                First install/configure your OS and then add the gpiod package. Then run gpioinfo and you will see how the Odroid is maping the standard Pi gpio pins. The SPI stuff should be fine by default but you need to find where PI pin 22 goes. pin 22 on the standard Pi gpio header maps on the Odroid C4 as below on ubuntu focal or debian bullsye based installs:

                root@# gpioinfo 
                gpiochip0 - 16 lines:
                        .
                        .
                        .
                
                gpiochip1 - 86 lines:
                        .
                        .
                        .
                
                        line  68:     "PIN_22"       unused   input  active-high 
                             .
                             .
                             .
                

                So install the duet software as normal and it will error out due to the config being wrong. Then edit
                /opt/dsf/conf/config.json
                and replace the lines for:

                "GpioChipDevice": "/dev/gpiochip1",
                  "TransferReadyPin": 68,
                

                Your's may be diffrent depending on what the output of gpioinfo was. then reinstall the duet software and it should make the connection the board and start up.

                You'll also have to adjust the SPI Buffer by adding

                options spidev bufsiz=8192
                

                to
                /etc/modprobe.d/spidev.conf

                Reboot the Odroid and all should work just like the Pi. If for some reason the Duet software is messed up from the failed install just reinstall.

                joekoundefined 1 Reply Last reply Reply Quote 0
                • joekoundefined
                  joeko @Nurgelrot
                  last edited by

                  @nurgelrot said in RRF install failure with Hardkernel Odroid C4 as the SBC:

                  @joeko I find its easiest to use a linux distro that is still using the version 4.9 kernels. And you do not need any custom cable the one that comes with the Duet works fine.

                  First install/configure your OS and then add the gpiod package. Then run gpioinfo and you will see how the Odroid is maping the standard Pi gpio pins. The SPI stuff should be fine by default but you need to find where PI pin 22 goes. pin 22 on the standard Pi gpio header maps on the Odroid C4 as below on ubuntu focal or debian bullsye based installs:

                  root@# gpioinfo 
                  gpiochip0 - 16 lines:
                          .
                          .
                          .
                  
                  gpiochip1 - 86 lines:
                          .
                          .
                          .
                  
                          line  68:     "PIN_22"       unused   input  active-high 
                               .
                               .
                               .
                  

                  So install the duet software as normal and it will error out due to the config being wrong. Then edit
                  /opt/dsf/conf/config.json
                  and replace the lines for:

                  "GpioChipDevice": "/dev/gpiochip1",
                    "TransferReadyPin": 68,
                  

                  Your's may be diffrent depending on what the output of gpioinfo was. then reinstall the duet software and it should make the connection the board and start up.

                  You'll also have to adjust the SPI Buffer by adding

                  options spidev bufsiz=8192
                  

                  to
                  /etc/modprobe.d/spidev.conf

                  Reboot the Odroid and all should work just like the Pi. If for some reason the Duet software is messed up from the failed install just reinstall.

                  yes i got it 🙂
                  thx
                  but on odroid buster i cant find
                  /etc/modprobe.d/spidev.conf

                  i set "spidev bufsiz=8192" in the boot.ini (bootsarg)
                  is this o or should i create the spidev.conf ?

                  Nurgelrotundefined 1 Reply Last reply Reply Quote 0
                  • Nurgelrotundefined
                    Nurgelrot @joeko
                    last edited by

                    @joeko Setting it as an argument to boot is fine too if that's working for you.

                    joekoundefined 1 Reply Last reply Reply Quote 0
                    • joekoundefined
                      joeko @Nurgelrot
                      last edited by

                      @nurgelrot said in RRF install failure with Hardkernel Odroid C4 as the SBC:

                      @joeko Setting it as an argument to boot is fine too if that's working for you.

                      thank you 🙂
                      i like odroid sbc. running with emmc and with Exec On MCode setting i shut down the sbc with M7722

                      o_lampeundefined 1 Reply Last reply Reply Quote 0
                      • o_lampeundefined
                        o_lampe @joeko
                        last edited by

                        @joeko said in RRF install failure with Hardkernel Odroid C4 as the SBC:

                        with Exec On MCode setting i shut down the sbc with M7722

                        Shut down isn't hard, but how do you restart it? I have an remote controlled mains adapter to switch the odroid powersupply off/on to restart...

                        Nurgelrotundefined joekoundefined 2 Replies Last reply Reply Quote 0
                        • Nurgelrotundefined
                          Nurgelrot @o_lampe
                          last edited by

                          @o_lampe Simple I never turn mine off 🙂 use the odroid and Node-RED to run all the relays to start the printers/cameras etc... So at least one SBC is always on- usually just leave them all on and power down the printers.

                          1 Reply Last reply Reply Quote 0
                          • joekoundefined
                            joeko @o_lampe
                            last edited by

                            @o_lampe said in RRF install failure with Hardkernel Odroid C4 as the SBC:

                            @joeko said in RRF install failure with Hardkernel Odroid C4 as the SBC:

                            with Exec On MCode setting i shut down the sbc with M7722

                            Shut down isn't hard, but how do you restart it? I have an remote controlled mains adapter to switch the odroid powersupply off/on to restart...

                            you can restart the sbc also on this way. create an new service and call him reboot. modify the lines from poweroff to reboot andfrom M7722 to M7723 and than you can reboot with M7723. also updates over the sbc should be possible

                            1 Reply Last reply Reply Quote 0
                            • First post
                              Last post
                            Unless otherwise noted, all forum content is licensed under CC-BY-SA