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

    Where to start learning modern C++

    Scheduled Pinned Locked Moved
    Firmware developers
    3
    3
    311
    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.
    • DDDundefined
      DDD
      last edited by

      Hi Devs,

      I used to program in C and a bit more in C++ some 20 years ago. Some of the basics are there but my experience ended in object-oriented coding. I'm asking for your recommendations on literature/courses/tutorials on how to restart my coding skills in order to make some firmware modifications for the Duet 3 family. Any advice will be appreciated.

      dc42undefined 1 Reply Last reply Reply Quote 1
      • mikeabuilderundefined
        mikeabuilder
        last edited by

        This may sound like an odd suggestion, but I'd recommend you start by purchasing a small microprocessor like a raspberry pi pico or an an ESP32 (I like the pico better myself) and start your C refresh programming for that. These things are cheap, cheap cheap. They give you access and experience dealing with the hardware more directly than playing with programming for windows.

        I'd set up a development environment using microsoft's VScode. It's free and has a lot of good features.

        I speak from near-experience. I'm a mechanical engineer and learned to code way back when Fortran was the top dog and punch cards were turned in for the professor to review your work. I eventually learned python and when I decided I should see what the big deal was with C, I took the microprocessor path. I never followed through after someone suggested I needed to write my own file system to write to an SD card (in hindsight, probably not true). Then I got into programming micros with micropython. But if/when I decide to take a crack at header files, make files, compiling and all that, I'll definitely do it by programming for a small microprocessor.

        1 Reply Last reply Reply Quote 2
        • dc42undefined
          dc42 administrators @DDD
          last edited by

          @DDD bear in mind that C++ for embedded processors is not the same as C++ for desktop machines and servers. In particular, use of dynamic memory is minimised, so most of the STL classes are avoided.

          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