??? 01/18/11 08:04 Read: times |
#180672 - Hardware-specific vs. "good code". Responding to: ???'s previous message |
Joseph Hebert said:
There is one fundamental problem to producing such a library. Embedded code is, by its very nature, very hardware specific. However, many, many aspects of "good" code are not hardware-specific. They're not even language-specific and work all the way down to assembly. It already improves code quality dramatically to incorporate these aspects into ones own code. It's mostly really simple stuff, like keeping functions short (no code sprawl that stretches out over two dozen screens), etc, etc. Of course, such a "quality code" library should be for reference, not for getting ready-made solutions. Maybe contrasting "good" and "bad" code that essentially performs the same function would be a good teaching aid. |