Embedded Wednesdays: Logic in C Part I

Andrei drew the short straw. His punishment was to write a blog post on boolean logic and bit manipulations. That way Elecia and Chris Svec could refer to the post rather than having to explain it themselves.

This first part is a useful review of boolean logic. If you find it useful, please buy Chris Gammell a beer. 

Read More

ESE101: Building an Assembly Language Playground

A wise man once said:

Take a kid to a playground and he’ll play for a day. Teach a kid to build a playground and he’ll get frustrated, bored, and wander off.

Today I’m going to teach you to build an assembly language playground. If that sounds fun, read on! If not, then feel free to wander off.

Read More

Embedded Wednesdays: Functions Part 2

In the final serving of the Embedded Wednesdays crash course in C, Andrei gives a bowlful of function goodness. Parameters, return values, headers, and prototypes. Sprinkle some prototypes, add #includes on top, then add some Good Habits for keeping you regular. But you can't have all of this wholesome goodness without talking about the inevitable void.

In French, the Rice Krispie guys Snap, Crackle, and Pop are known as Crik, Crak, and Crok. All of those names start with C. Coincidence, I don't think so. Pull up a chair and grab a heaping helping of C functions.  (Corny? No, I Oat to know how that is Spelt)

Read More

ESE101: Microcontroller Peripherals, GPIOs, and Blinking Lights: Part 3

This week we complete our three-part look introduction to peripherals, GPIOs, and blinking lights.

By the end of this post you’ll understand how to bend physics to your will with a little bit of typing and mouse clicking. We’ll alter the flow of electrons on a circuit board and make electricity flow through an LED and turn a light on.

This is kind of magical, people, so check it out.

Read More

Embedded Wednesdays: Characters.

This week Andrei gives an overview of the char type in the C language. C has some issues with character strings and Andrei goes into buffer overflow problems and missing terminators in the strcpy function. This a post that should be read all of the way through by all C programmers. Make sure you can spot the bugs in the code.

Read More

Karaoke Plays Music

I started with simple state machines last week. This week I want to talk about more complex state machines and interrupts. These are software topics but we’ll get back to the hardware soon.

The karaoke buttons that control music playback are far more complicated than either its disco button or the quadcopter’s power on sequence; if you press play on the karaoke, what happens? What if the door is open? What if there is no CD? What if it is already playing?

Read More