Robot Faces - OLED Kit - List of Hands on Labs
Each lesson is a short, hands-on walkthrough of one idea, with a complete program you can paste onto your microcontroller and a picture of what it draws on a real 128 by 64 display.
Getting Oriented
The Drawing Primitives
These eight lessons cover every drawing command the MicroPython framebuffer offers. Work through them in order and you will have the complete toolkit.
| Lesson |
Command |
| Pixel |
pixel() — the single dot everything else is built from |
| Line |
hline(), vline(), and line() — including the eyebrow rule |
| Rectangle |
rect() and fill_rect(), and how to erase with black |
| Ellipse |
ellipse() and the quadrant fill codes |
| Circle |
Circles as a special case of the ellipse |
| Polygon |
poly() for triangles, stars, and any shape you can list points for |
| Text |
text() and the 8 by 8 font layout math |
| Scroll |
scroll() for sliding the whole buffer at once |
| Blit |
blit() for stamping a finished sprite, with transparency |
Building Faces
Thinking About Your Code
The lessons above teach you how to make the hardware do something. These eight teach you how to
think about the code you just wrote — the four habits that transfer to every program you will
ever write, taught on code you already understand.
Work them in order, and only after you have finished the lessons above. Each one solves a
problem you have already felt, which is what makes it stick.
| Lesson |
Thinking skill |
What you'll learn |
| The Face Module |
Decomposition, abstraction |
Move the duplicated face parts into one shared file |
| The Emotion Table |
Pattern recognition |
Seven emotions become seven rows of data and one function |
| Five Broken Faces |
Debugging |
Five planted bugs, a method for finding them, and a symptom table |
| Trace and Watch |
Debugging by measurement |
An on-screen instrument panel for bugs you cannot photograph |
| Keyframes |
Algorithms |
An animation is a list of poses, and one player runs them all |
| A Face With a Memory |
Abstraction, modeling |
States and transitions as tables, instead of tangled if-statements |
| Only Redraw What Changed |
Decomposition, measurement |
Redraw just the moving part, then measure whether it helped |
| Design Your Own Emotion |
All four |
Invent an expression and test whether a stranger can read it |
| How Fast Is a Face? |
Measurement, algorithms |
Race a hand-written ellipse() against the built-in, and explain the gap |
Kit Packaging & Accessories