Skip to Content
Hands-On RTOS with Microcontrollers
book

Hands-On RTOS with Microcontrollers

by Brian Amos
May 2020
Intermediate to advanced
496 pages
13h 54m
English
Packt Publishing
Content preview from Hands-On RTOS with Microcontrollers

Developing an LED interface

To illustrate the initial concept in detail, let's take a look at a simple driver that we've been using since the first examples introduced in this book—an LED driver. A simplified version of an interface to drive the LEDs on our Nucleo board has been used since the very first examples in earlier chapters. This interface is located at BSP\Nucleo_F767ZI_GPIO.c/h. This code fully abstracted the LEDs from the underlying hardware with a struct named LED. The LED struct has two function pointers: On and Off. As expected, the intention of these two functions is to turn an LED on and off. The beauty of this is that the calling code doesn't need to be concerned with the implementation of the LED at all. Each LED could ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Hands-On RTOS with Microcontrollers - Second Edition

Hands-On RTOS with Microcontrollers - Second Edition

Jim Yuill, Penn Linder

Publisher Resources

ISBN: 9781838826734Supplemental Content