Author Topic: Standardized (Nicely Organized) Embedded System Programming Library/API  (Read 11758 times)

0 Members and 1 Guest are viewing this topic.

Offline westfw

  • Super Contributor
  • ***
  • Posts: 4199
  • Country: us
Quote
yes [Arduino subtraction of "Pin"] is brilliant albeit not new (c/c++ abstraction already existed for decades)
Oh, "abstraction" has been around forever.  My point is that programmers (and in particular library authors) still need to pick good things and good ways to create the abstraction.  All too often, they fail :-(  (implementing "sbi()" in avr-gcc is an example that came up recently in another thread.  Logical, useful, efficient; but a terrible example of abstraction.)

Quote
except its specific to avr chip family
No, it's not.  It's also been implemented on ARM, MSP430, and PIC32 (at least!)  Implementing it on your favorite CPU is a good learning experience, because there is more to it than it looks like at first glance.

Quote
and the implementation is really inefficient (for that simple IO toggling).
Eh, it's not so bad, for what it is documented to do.  It's a bit much when it comes to setting a constant pin number to a constant value (which is pretty common.)  That's been solved, too, in at least three different ways, while keeping the "abstraction" part quite similar.  (but getting the new code back into Arduino is tougher.  I think they're worried that having digitalWrite suddenly become 20x faster for SOME cases might be dangerous.  This is probably a valid concern.)
 

Online MechatrommerTopic starter

  • Super Contributor
  • ***
  • Posts: 11635
  • Country: my
  • reassessing directives...
i quick read the stm32 embedded gui library... the so claimed cmsis compliant (whatever that is). the documentation... i prefer to print the whole source code is better, alot better making my own. its like robot generated documentation i'm clueless where to start. i dont get it why and what they have in mind, what a waste >:(.
Nature: Evolution and the Illusion of Randomness (Stephen L. Talbott): Its now indisputable that... organisms “expertise” contextualizes its genome, and its nonsense to say that these powers are under the control of the genome being contextualized - Barbara McClintock
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf