Before you apply power
Inspect the board under magnification. Look for solder bridges, especially on fine-pitch QFN and QFP packages, two flat package types. A solder bridge is an accidental blob that joins two pads. Fine-pitch means the pins are close together. Look for tombstoned passives, small parts such as resistors where one end lifts off its pad. Check polarity on diodes, LEDs and electrolytic capacitors. Polarity means which way the part must face. An electrolytic capacitor is a can-shaped part. Check that the right part sits in every footprint. A footprint is the copper shape and holes a part needs on the board. Then check resistance with the board unpowered. There must be no short between each rail and ground. A short is an unintended direct connection. This five-minute ritual has saved more boards than any debugger.
The bring-up order
- Power rails: power up with a current-limited supply, a supply with a current cap, the first time. Measure every rail at the load, not at the regulator. A rail is one supply voltage. A regulator holds that voltage steady. Wrong voltage, or a rail that collapses under load, stops everything below.
- Clock: confirm the oscillator runs at the right frequency. An oscillator is the part that sets the chip's timing, often a crystal, a small quartz part. Scope the crystal or check the clock output pin. A scope is an instrument that shows a voltage over time. A surprising number of "dead MCU" cases are clock cases. An MCU (microcontroller) is the small computer inside the device.
- Reset: verify the reset line releases cleanly and the MCU starts. Current draw should jump from microamps to milliamps. A microamp is one millionth of an amp. A milliamp is one thousandth of an amp.
- Debugger connection: get SWD or JTAG talking before anything else. Those are the standard debug connections to a chip. If the debugger cannot see the core, the main processing part of the chip, nothing else matters. Check power, clock, reset and the debug pin wiring, in that order.
- Debug UART first: the first firmware you load should print "hello" over UART. Firmware is the software that runs on the chip. UART is a simple serial connection. A working debug console turns every later problem from a mystery into a log message.
- Peripherals one at a time: GPIO, then timers, then I²C, SPI or UART to each sensor. A peripheral is a built-in function such as a timer or a bus. I²C and SPI are two common buses, shared sets of wires for data. GPIO is a pin that can read or send a simple signal. Give each one a tiny test that proves it before you move on. Never bring up three new peripherals in one firmware program.
- Application logic last: the code that does the product's job comes only when every peripheral is proven on its own.
Multi-board systems
BLE (Bluetooth Low Energy) is the low-power version of Bluetooth. When boards talk to each other, as in the glasses-and-ring system, bring up each board alone first. Then bring up the link. Define the protocol before you write either side's firmware. A protocol is the agreed format and order of messages. It covers message formats, who starts, timeouts and retries. Two firmware programs written against a shared protocol document integrate in hours. Two written against assumptions integrate in weeks.
What MICA generates today
A placeholder, compiled and tested on your computer only
MICA generates placeholder firmware. It compiles the code with
-Werror, which treats every compiler warning as an error, and runs its tests on your computer against a simulated register map. -Werror is true of that host build only. It does not prove anything about a real chip, and this firmware must not be flashed. This checklist is general advice for any new board. No MICA board has been built, so nobody has run it on one.