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

    Compiling/Building PanelDue Firmware

    Scheduled Pinned Locked Moved
    Firmware developers
    2
    12
    1.5k
    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.
    • jmlundefined
      jml
      last edited by

      In Settings > C/C++ Build, I changed "Builder Type" to Internal Builder. And now it has built. Testing now.

      1 Reply Last reply Reply Quote 0
      • gtj0undefined
        gtj0
        last edited by

        Yeah, It's hard coded for Windows paths and the Windows "copy" command. This step is the final step that adds the logo to the bin file. If you don't need the logo, you can just load the *-nologo.bin file to the panel.

        If you want to keep the logo, you can change it to *nix paths and the "cat" command by replacing "& copy" and everything after with...

        && cat "${BuildArtifactFileBaseName}-nologo.bin" "../SplashScreens/SplashScreen-Escher3D-800x480.bin" > "${BuildArtifactFileBaseName}.bin"
        

        You do this by going to Project, Settings, C++ Build, Settings, then select the configuration you wish to build, click the "Build Steps" tab and update the
        "Post build steps" "Command".

        jmlundefined 1 Reply Last reply Reply Quote 1
        • jmlundefined
          jml @gtj0
          last edited by

          @gtj0 I tested my build, and the screen is yellow tinted, upside down, and mirrored from what it should be. What is going on?

          I'll use it with no logo for now. The only bin file generated is PanelDue-v3-7.0-nologo.bin, so that is what I loaded onto the panel using the instructions here:
          https://miscsolutions.wordpress.com/paneldue/

          1 Reply Last reply Reply Quote 0
          • gtj0undefined
            gtj0
            last edited by

            That's odd. You may want to go to settings and do a "Clear settings" and see if that fixes it. Are you using the latest version (1.21.3)? If you load the pre-built -nologo.bin file, it works OK?

            1 Reply Last reply Reply Quote 0
            • jmlundefined
              jml
              last edited by jml

              The latest pre-built nologo.bin file worked great - I got it to display a custom logo too. But I need some custom buttons, so thats what I'm editing the paneldue firmware.

              Where do I "clear settings" ? Is that the same as "Clean Project" ?

              I think I'm using the latest version, let me try to find that out.

              jmlundefined 1 Reply Last reply Reply Quote 0
              • jmlundefined
                jml @jml
                last edited by

                @jml Yes I was using the latest version

                1 Reply Last reply Reply Quote 0
                • jmlundefined
                  jml
                  last edited by jml

                  The pre-built was Panel Due firmware version 1.21.3(13b1) as shown in the "setup" screen on the paneldue. I just uploaded it to the paneldue again and it works fine.

                  When I upload the bin file that I build in eclipse, the firmware version shown on the setup screen on the paneldue is the exact same number.

                  For some reason, the color blue is just not being rendered, thats why it appears yellow tinted. And its upside-down and backwards.

                  jmlundefined 1 Reply Last reply Reply Quote 0
                  • jmlundefined
                    jml @jml
                    last edited by

                    Oops, I've been using the wrong bin entirely, I should be using and building PanelDue-5.0i-7.0i.bin instead of the V3 version! That should fix it... will update soon.

                    1 Reply Last reply Reply Quote 0
                    • jmlundefined
                      jml
                      last edited by

                      @gtj0 Yep that was the problem, I was using the wrong bin. Loading a built bin now works.

                      If I want to add my own logo during the build process, I should do what you mentioned above. I'm not sure what you mean though. I get an ignored error: make[1]: [post-build] Error 1 (ignored)

                      	arm-none-eabi-objcopy -O binary "${ProjDirPath}/${ConfigName}/${BuildArtifactFileBaseName}.elf" "${ProjDirPath}/${ConfigName}/${BuildArtifactFileBaseName}-nologo.bin" & copy /B /Y "${ProjDirPath}\\${ConfigName}\\${BuildArtifactFileBaseName}-nologo.bin"+"${ProjDirPath}\SplashScreens\SplashScreen-Duet3D-800x480.bin" "${ProjDirPath}\\${ConfigName}\\${BuildArtifactFileBaseName}.bin"
                      

                      with

                      	arm-none-eabi-objcopy -O binary "${ProjDirPath}/${ConfigName}/${BuildArtifactFileBaseName}.elf" "${ProjDirPath}/${ConfigName}/${BuildArtifactFileBaseName}-nologo.bin" arm-none-eabi-objcopy -O binary "${ProjDirPath}/${ConfigName}/${BuildArtifactFileBaseName}.elf" "${ProjDirPath}/${ConfigName}/${BuildArtifactFileBaseName}-nologo.bin" && cat "${BuildArtifactFileBaseName}-nologo.bin" "../SplashScreens/SplashScreen-Escher3D-800x480.bin" > "${BuildArtifactFileBaseName}.bin"
                      

                      But it gives that error at the end.

                      gtj0undefined 1 Reply Last reply Reply Quote 0
                      • gtj0undefined
                        gtj0 @jml
                        last edited by gtj0

                        @jml said in Compiling/Building PanelDue Firmware:

                        @gtj0 Yep that was the problem, I was using the wrong bin. Loading a built bin now works.

                          arm-none-eabi-objcopy -O binary "${ProjDirPath}/${ConfigName}/${BuildArtifactFileBaseName}.elf" "${ProjDirPath}/${ConfigName}/${BuildArtifactFileBaseName}-nologo.bin" arm-none-eabi-objcopy -O binary "${ProjDirPath}/${ConfigName}/${BuildArtifactFileBaseName}.elf" "${ProjDirPath}/${ConfigName}/${BuildArtifactFileBaseName}-nologo.bin" && cat "${BuildArtifactFileBaseName}-nologo.bin" "../SplashScreens/SplashScreen-Escher3D-800x480.bin" > "${BuildArtifactFileBaseName}.bin"
                        

                        But it gives that error at the end.

                        You've got a duplicated arm-none-eabi-objcopy command in there.

                        There should be one arm-none-eabi-objcopy command to take the .elf file and produce the -nologo.bin file then the "&&" and "cat" commands to concatenate the -nologo.bin file and the splash screen file into the .bin file.

                        Make sure you switch back to the external builder as well.

                        Like so:

                        arm-none-eabi-objcopy -O binary "${ProjDirPath}/${ConfigName}/${BuildArtifactFileBaseName}.elf" "${ProjDirPath}/${ConfigName}/${BuildArtifactFileBaseName}-nologo.bin" && cat "${BuildArtifactFileBaseName}-nologo.bin" "../SplashScreens/SplashScreen-Escher3D-800x480.bin" > "${BuildArtifactFileBaseName}.bin"
                        

                        Since that command is actually run in the Release-* directories, you can shorten it as follows...

                        arm-none-eabi-objcopy -O binary "${BuildArtifactFileBaseName}.elf" "${BuildArtifactFileBaseName}-nologo.bin" && cat "${BuildArtifactFileBaseName}-nologo.bin" "../SplashScreens/SplashScreen-Escher3D-800x480.bin" > "${BuildArtifactFileBaseName}.bin"
                        

                        If you're going to use your own logo, you'll need to compress it with the
                        bmp2c program in the Tools directory. Unfortunately, this is a Windows-only tool and won't build under Mac or Linux.

                        jmlundefined 1 Reply Last reply Reply Quote 0
                        • jmlundefined
                          jml @gtj0
                          last edited by

                          @gtj0 Thanks for the advice, I'm able to use the bmp2c program and the other instructions for adding my own logo to the compiled bin program. Its a nice feature! Would be nice if it could load faster, and I would customize the firmware to display it for a shorter amount of time, but these are minor issues.

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