85 points · by _qc3o · 12y ago · 71 comments
The last thing I want is a layer of software and an IDE developed by a team that I can only assume has 0 embedded experience (judging by team page they are all architects or academics).
Secondly, if I handed off a work for hire implemented in this language I would not get a next assignment. There is no room for fad modelling in the established engineering trade and unfortunately I don't have the pull to start the disruption if I truly believed in it.
Ask my clients how much of a problem I am and then ask them how many problems I solve. And no, I don't solve them all with C.
The thing about these systems is they attempt to prevent you from shooting your own foot by not letting you aim. Some operations (such as erasing and writing flash) require you to do dangerous things like relocating code to SRAM and running from there while your flash operation completes. The details of each platform vary: ARM code is generated in a position dependent fashion; MSP430 is not.
I am certainly not calling C the end-all be all, but it's a tough system to beat. You could convince managers that mbedder may be the way to go, but it would be an absolute boondoggle to get existing engineers to use it. (They couldn't even convince the Park-o-matic folks to rewrite their code to use it). To a "C simpleton" like me, I would not call mbedder obviously better.
1. They are using MPS [0] from JetBrains, a system for constructing tooling around Domain Specific Languages.
2. Markus Voelter is a huge proponent of DSLs and a very level headed fellow. Loved his interview with Laurence Tratt [1] about compile time metaprogramming [2].
This brings benefits of Ada and Lisp with a modern JetBrains style IDE while targeting a C99 runtime. I think being able to sculpt the language to the project can greatly compact the abstraction distance from the problem domain to the code.
[0] http://www.jetbrains.com/mps/ [1] http://tratt.net/laurie/ [2] http://www.se-radio.net/2007/05/episode-57-compile-time-meta...
Most embedded programming isn't that bug-sensitive, but quite a lot is and I'd wager they'd love something like this.
I know I'd use it if I were writing safety-critical code.
Coming back to embedded applications not being that complicated, now you also need to get your developers to learn another framework and IDE while they are already under pressure to develop their current feature set.
Like codehero states elsewhere it only adds another abstraction layer between you and the silicon, in a field where exact control of the silicon is paramount (Low power, response latency in real time, limited resources etc).
Furthermore what guarantee do you have that Mbeddr will support the latest processor you are working on. At least with C being a defacto standard in the industry you have that guarantee. Furthermore most processor manufacturers supplies demonstration code to use their latest processor features, how easy is it to pull that into Mbeddr?
I'm afraid this is a very fancy and polished solution looking for a problem.
Your comment reminds me what people were saying when assemblers were first developed. Real programmers did not use assemblers because it was too high level or too far removed from the hardware or any number of other excuses. The fact is that plain C is inadequate for delivering correct software in high assurance environments. This tool addresses that problem and then some.
*whatever that means in context...
As we say - "doctor, doctor it hurts when I do that!" "Well, don't do that!"
Tools like this simply automate or add leverage to that process.
And unless there's considerable community support for the use of something like this, it'll remain a smaller thing than raw 'C'. But many embedded projects are small enough that there's little pain in reinventing the wheel.
I am slightly concerned by the DSL thing, because I don't want each embedded projects to have specific dialects like we can see on LISP projects.
But, on the average, gains are high: modules ! tests ! Inline contracts and model checking ! Very nice state machines ! I like that !
Also, why C99 ? There's hardware where only C89 compilers are available...
Moreover, embedded development is conservative by nature and I know a lot of teams which prefers to run projects on known hardware when possible, even if we have to suffer of the tooling.
Also, don't forget the licencing. We already have to downgrade our targeted platform because we couldn't afford to pay the whole tooling where OSS was only compatible with the previous version.
NOPE.
From my cold, dead hands.
#ifdef HW_REVISION_1
#ifdef HW_REVISION_2
etc
You shouldn't clutter your code with ifdef. It makes it hard to think with.
Regardless, MPS has support for things like version control merging/diffing and so on. It's a pretty mind blowing tool all round.
Which is also an online embedded software toolchain from IDE to linker.
looking through them comments in an earlier HN post https://news.ycombinator.com/item?id=6268291 on running rust on the arduino DUE they link to zero.rs that should make it possible to run without any runtime
Since tricorders will most likely run linux, by default, they will have lots of C.