Saltar al contenido ForoHackers

Firmware: start here

Firmware
#2949 · · Citar · Denunciar

Firmware is the software that lives in a device's non-volatile memory and makes the hardware work: in a keyboard, a disk, a phone's modem, a car's controller. It is written close to the hardware, it is hard to update, and its bugs outlive its authors.

Key concepts

  • Hardware first: datasheets, schematics and errata decide what the code must do.
  • Startup: vectors, clock setup, memory initialisation, then main.
  • Robustness: watchdogs, brown-out handling, defensive defaults and a safe state.
  • Updates: signed images, rollback protection and a recovery path when an update fails.
  • Testing on and off target: unit tests on the host, hardware-in-the-loop on the bench.

Vocabulary

  • Image: the binary written to flash, often with a header, a version and a signature.
  • Errata: the vendor's list of how the chip differs from its datasheet.
  • OTA: over-the-air update.
  • Option bytes, fuses: one-time or protected settings such as read-out protection.

What to study, in order

  1. Microcontroller basics: registers, interrupts, peripherals.
  2. Read a schematic and follow a signal from the pin to the connector.
  3. Write a driver for a sensor from its datasheet alone.
  4. Add a bootloader and a signed, rollback-safe update.
  5. Test on the host with mocks, then on the bench with the real board.

Related tags

#microcontrollers #bootloaders #firmware-analysis #hw-sw-integration

No has iniciado sesión, así que esto se publica como anónimo: no se guarda con ello ninguna cuenta, nombre ni dirección, y no puede llevar enlaces ni imágenes. Inicia sesión o únete para publicar con tu nombre. Los registros de nuestro servidor web guardan la dirección y la hora de cada petición hasta 14 días; para que la tuya no quede en ellos, usa Tor. Para escribir al equipo de forma confidencial, usa el buzón. Firmar como fuente habitual (una clave guardada solo en este navegador)

Enviar tarda unos segundos aquí: tu navegador resuelve antes una prueba de trabajo contra el spam.

Responder