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

Help me find "linker script" in source code

Scheduled Pinned Locked Moved
Firmware developers
6
14
667
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.
  • undefined
    arhi @bot
    last edited by 10 Jul 2020, 21:27

    @bot said in Help me find "linker script" in source code:

    Where can I find the linker script? What is its filename and location?

    not that simple for project as complex with so many targets

    e.g. for duet2ethernet linker scripts are (flash.ld is what you want to look at):

    https://github.com/Duet3D/CoreNG/tree/master/variants/duetNG/linker_scripts/gcc

    1 Reply Last reply Reply Quote 1
    • undefined
      arhi @A Former User
      last edited by 10 Jul 2020, 21:30

      @bearer said in Help me find "linker script" in source code:

      i was under the impression eclipse generate that on the fly behind the scenes?

      not really 🙂
      there are are some "default" linker scripts that come with "chip support" and some tools can create the linker script using input (what cpu, do you have external sram etc etc) but usually you have to deal with it yourself (I must say I'm far from master wrt that 😞 but I dabble)

      1 Reply Last reply Reply Quote 0
      • undefined
        bot @oliof
        last edited by bot 7 Oct 2020, 22:14 10 Jul 2020, 22:03

        @oliof said in Help me find "linker script" in source code:

        I assume you already did read through https://github.com/Duet3D/RepRapFirmware/blob/dev/BuildInstructions.md and have a working build setup?

        Lol. No. Not at that point yet. I'm just learning about everything first. Like, introductory courses in C and embedded C. In these courses they mentioned linker scripts. I then searched the codebase on GitHub for linker script, and found comments referencing it but alas found no "linker script."

        At the moment, I'm just curious about what would be in there, and how the memory is mapped for the different boards. I'm getting the sense that these scripts are built at compile time automatically?

        @arhi said in Help me find "linker script" in source code:

        @bearer said in Help me find "linker script" in source code:

        i was under the impression eclipse generate that on the fly behind the scenes?

        not really 🙂
        there are are some "default" linker scripts that come with "chip support" and some tools can create the linker script using input (what cpu, do you have external sram etc etc) but usually you have to deal with it yourself (I must say I'm far from master wrt that 😞 but I dabble)

        @arhi said in Help me find "linker script" in source code:

        @bot said in Help me find "linker script" in source code:

        Where can I find the linker script? What is its filename and location?

        not that simple for project as complex with so many targets

        e.g. for duet2ethernet linker scripts are (flash.ld is what you want to look at):

        https://github.com/Duet3D/CoreNG/tree/master/variants/duetNG/linker_scripts/gcc

        Well, thank you!! I will check these out. [edit: these are exactly what I was looking for, thank you!]

        I wish that GitHub repos were more noob-friendly, with a "description" in the directory/file tree structure, rather than just commit messages.

        [edit: I get it now. I was looking in the RRF repo. That's an abstraction layer. I wanted to be looking at CoreNG, which is the... part that comes before the OS? Or the part that comes after the OS? Or whatever it's not RRF! 😛 ]

        undefined 1 Reply Last reply 10 Jul 2020, 22:50 Reply Quote 0
        • undefined
          arhi @bot
          last edited by 10 Jul 2020, 22:50

          @bot said in Help me find "linker script" in source code:

          I wanted to be looking at CoreNG, which is the... part that comes before the OS? Or the part that comes after the OS? Or whatever it's not RRF! 😛 ]

          The structure of the whole RRF is not to my liking (nothing wrong with it, just not what I am used to. For example, smoothieware, while waaaaaaaaaaaaaay less powerful than RRF, has the structure that's something I'm used to) and that's the main reason I was delaying my move to RRF for many years... but I bit the bullet and I didn't regret it. I'm still not fully clear on the RRF structure myself. I can build the firmware and make small adjustments but that's it. Still more time needed till I fully grasp the structure.

          It would be cool if a document explaining the RRF structure existed, but it's not a simple thing to write, even harder to maintain, if not done by the firmware developer. And takes a huge amount of time from the firmware developer so... and I guess we all prefer bugfixes and new features to documentation 😄 😄 😄

          IMHO the best way to understand embedded development and how RRF work is to make this documentation 😄 .. bug dc42 trough PP/Forum/email/phone to gather info and than articulate it into a wiki :). Starting point can be

          • readme.md from all the projects
          • https://github.com/Duet3D/RepRapFirmware/blob/dev/BuildInstructions.md
          • https://github.com/Duet3D/RepRapFirmware/blob/dev/RTOS_notes.md
          • https://github.com/Duet3D/RepRapFirmware/blob/dev/AddingNewKinematics.md
          undefined undefined 2 Replies Last reply 10 Jul 2020, 23:20 Reply Quote 1
          • undefined
            bot @arhi
            last edited by bot 7 Oct 2020, 23:20 10 Jul 2020, 23:20

            This post is deleted!
            1 Reply Last reply Reply Quote 0
            • undefined
              jazbaatbadalgaye @arhi
              last edited by 17 Sept 2021, 21:55

              This post is deleted!
              undefined 1 Reply Last reply 19 Sept 2021, 10:15 Reply Quote 0
              • undefined
                arhi @jazbaatbadalgaye
                last edited by 19 Sept 2021, 10:15

                @jazbaatbadalgaye each of those links show you where the page moved?!

                https://github.com/Duet3D/RepRapFirmware/wiki/Building-RepRapFirmware
                https://github.com/Duet3D/RepRapFirmware/wiki/Notes-on-using-FreeRTOS
                https://github.com/Duet3D/RepRapFirmware/wiki/Adding-New-Kinematics

                @dc42 there's an issue with https://github.com/Duet3D/RepRapFirmware/wiki/Notes-on-using-FreeRTOS does not allow me to view it

                undefined 1 Reply Last reply 19 Sept 2021, 12:57 Reply Quote 0
                • undefined
                  dc42 administrators @arhi
                  last edited by 19 Sept 2021, 12:57

                  @arhi said in Help me find "linker script" in source code:

                  @dc42 there's an issue with https://github.com/Duet3D/RepRapFirmware/wiki/Notes-on-using-FreeRTOS does not allow me to view it

                  Where did you find that link?

                  Duet WiFi hardware designer and firmware engineer
                  Please do not ask me for Duet support via PM or email, use the forum
                  http://www.escher3d.com, https://miscsolutions.wordpress.com

                  undefined 1 Reply Last reply 19 Sept 2021, 20:04 Reply Quote 0
                  • undefined
                    oliof @dc42
                    last edited by 19 Sept 2021, 20:04

                    @dc42 said in Help me find "linker script" in source code:

                    Where did you find that link?

                    It's linked at https://github.com/Duet3D/RepRapFirmware/blob/dev/RTOS_notes.md

                    <>RatRig V-Minion Fly Super5Pro RRF<> V-Core 3.1 IDEX k*****r <> RatRig V-Minion SKR 2 Marlin<>

                    undefined 1 Reply Last reply 20 Sept 2021, 08:22 Reply Quote 0
                    • undefined
                      dc42 administrators @oliof
                      last edited by 20 Sept 2021, 08:22

                      @oliof thanks, I've added that page.

                      Duet WiFi hardware designer and firmware engineer
                      Please do not ask me for Duet support via PM or email, use the forum
                      http://www.escher3d.com, https://miscsolutions.wordpress.com

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