Programming in Nim actually "feels" quite different from python to me, due to things like a much lighter OOP system (that is somewhat discouraged), the type system, and UFCS, though it "looks" like python at first glance.
2,296 karma · joined May 2, 2014
Get in touch:
frtherien@gmail.com github.com/auxym
Programming in Nim actually "feels" quite different from python to me, due to things like a much lighter OOP system (that is somewhat discouraged), the type system, and UFCS, though it "looks" like python at first glance.
Fun/easy reading: Skunk Works: A Personal Memoir of My Years of Lockheed (Ben R. Rich)
Textbook:
Shigley's Mechanical Design (recent editions are by Budynas/Nisbett by older editions with Shigley as an author are just as good as an intro)
For comparison, Microchip (formerly atmel) SAMD21 (also Cortex-M0+, of Arduino Zero fame) is about 3-4 $, single core, less RAM.
Matlab also historically was really bad for abstraction and code architecture in general. For example, the hard "1 function per file" rule, which encouraged people to not use functions at all, or if you really had to, write 2 or 3 really huge functions (in separate files). Only in recent years (the past 5 or 10 years) did matlab get OOP stuff (classes) and the option for multiple (private) functions in a single script file (still only one public/exported function is possible per file, because the file name is the function name and matlab uses path-based resolution).
Are we at the point where all developers, or all GUI developers, are expected to be familiar with HTML/CSS/JS/DOM concepts?
The QT stuff is familiar to me (from python mostly), but I have only very barebones knowledge of HTML/JS and almost none of the DOM and CSS.
Bit disapointed by the support in general though. I expected the Pine stuff to be better than "random boards from no name companies on Aliexpress" in terms of HW documentation and software support, but it wasn't that great. Software support is totally left in the hands of the community, and I couldn't get the spec for the uFL-like on-board antenna connector anywhere, total silence on their forums for months.
I mean, it works well overall (running Armbian), but I also had random aliexpress boards that had to be fully reverse engineered work pretty well.
https://github.com/raspberrypi/pico-examples/tree/master/pio
In fact, the rp2040 examples and SDK docs are very, very good compared to most traditional manufacturer's documentation and by itself makes it a very good value proposition for hobbyists.
To my knowledge it's been demonstrated on AVR, ARM Cortex-M and ESP32.
It's macro system comes in handy for embedded, too, as you can precompute so much stuff at compile time.
In the interest of shameless self promotion :), my own experimentations are :
https://github.com/EmbeddedNim/svd2nim
https://github.com/auxym/nim-on-samd21
And I've used and contributed to 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.
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).
Unless you have a USB bootloader programmed on the chip, but you still need the adapter to flash the bootloader in the first place.
I've seen a materials testing machine whose method to script custom test sequences was a "programming language" that was displayed as text but you couldn't actually type things in. You'd have to select constructs such as a for loop or conditional from a drop down box, then a dialog would appear asking you for the parameters of the loop (start, end, etc).
Actually, I think I even prefer Tcl to Excel's VBA.
Most people use dicts on modern TCL instead.
But consider this: say you were a licensed engineer, and writing shoddy code you would face the risk of losing said license and not being able to practice in the future. Yes, even if "your boss told you to do it". You are the engineer, you are the professional, it's your ass on the line if lives are lost or damaged. Then your choice is either pushing back and risk to get fired, or don't push back but risk to lose your license.
It's somewhat mind boggling.
They have replaceable "bulbs", but HD doesn't sell them, "because they are never supposed to break".
Found replacements that sort of work (different shade of white) a another store for some of the strings, but not for others, and had to throw them away. Very sour with the experience.