3 ms·
They're such a nice starting place for embedded dev! I'd messed around with Arduino things for a long time, and recently started messing with the chip itself wi
by ericwood 5y ago
They're such a nice starting place for embedded dev! I'd messed around with Arduino things for a long time, and recently started messing with the chip itself without the abstraction. The ATTINY series is powerful enough for many things while having a relatively small and easy to work with footprint (from a physical and register standpoint). It's actually possible to go through the entire datasheet and understand it, then poke all the right registers. It's also satisfying to be able to plop it onto a breadboard!
I'm excited for the Rust + AVR world to move forward a bit so I can keep playing with it without the currently required hacks :)
- auxym 5y agoIn case you're interested, there's a new project underway that aims to make running Nim on AVR (and eventually other micros through BSPs) as easy (but leaner and more performant) as Arduino: ratel.peterme.net Nim can already run on most MCUs (I've experimented with samd21 and rp2040), it just requires a few compiler flags or linking steps that are not super well documented. Ratel aims to automate that and provide some high level interfaces for hardware access (gpios, etc).
- girvo 5y agoNice work! I've been trying to stand up nesper/nephyr, the Nim overlays for ESP32 and Zephyr, but had quite a few issues (not all of which are those library's fault, the ESP-IDF toolchain is horrid in a lot of ways). I wonder how difficult it would be to extend Ratel over to ESP32 if I have a working toolchain already. I might have a crack at it, we're big on Nim at work and are trying to get away from C++ for our firmware development wherever possible.
- auxym 5y agoTo be clear: Ratel isn't my project, just something I'm following due to interest. In the interest of shameless self promotion :), my own experimentations are : https://github.com/EmbeddedNim/svd2nim https://github.com/EmbeddedNim/svd2nim https://github.com/auxym/nim-on-samd21 https://github.com/auxym/nim-on-samd21 And I've used and contributed to picostdlib (https://github.com/beef331/picostdlib https://github.com/beef331/picostdlib), the rp2040 support library. All just as a hobby, but it's interesting to learn that some companies are actually looking into Nim for firmware! Embedded seems like such a slow moving industry. I believe the author of Nesper and Nephyr also developed them for professional work.
- girvo 5y agoAs an update, after ditching the project/build tooling setup that Nesper required, I got Nim working wonderfully (with Nesper's library itself as a dependency) within PlatformIO and ESP-IDF on an ESP32 :) I even have hardware UART support and have a working SIM7000 modem connection going (though only with AT commands, not PPPoS yet, though I'm planning on that next). Nim is the future of firmware development, of that I am sure.
- girvo 5y agoIncredibly slow moving, buggy and badly documented! Embedded is a fun challenge but rough. Nim I believe is an answer to it though, and embedded being slow moving with a C target is perfect for it!