What is Embedded C?
C that runs straight on a microcontroller, no operating system — Arduino code is C++ wrapped around the same chip.
Your Arduino code is NOT C… it's C++. 🤯
Embedded C = plain C that runs straight on a microcontroller. No Windows, no Linux, no operating system in between. Nothing sits between your code and the chip.
Arduino gives you easy functions. digitalWrite(13, HIGH) hides 4 steps: look up pin 13 → PORTB bit 5, check its PWM timer, pause interrupts, and only then set the bit.
In Embedded C you set that bit yourself:DDRB |= (1 << DDB5); → pin D13 = outputPORTB |= (1 << PORTB5); → LED ONwhile (1) { } → the chip never stops
avr-gcc turns each of those lines into ONE machine instruction. The whole program is just 138 bytes.
Try it: paste it into the Arduino IDE (a sketch with its own int main() works) or a free online Uno simulator. The L LED turns on.
// EC L01 - Embedded C: plain C, straight on the chip (no OS)
#include <avr/io.h>
int main(void) {
DDRB |= (1 << DDB5); // pin D13 = output
PORTB |= (1 << PORTB5); // LED ON
while (1) { } // chip never stops
}Related lessons
Get new lessons + early access to the full course
One email when new lessons drop. No spam, unsubscribe any time.
✓ You're on the list. Check your inbox to confirm.
By joining you agree to the privacy policy.




