BBC micro:bit specific LED handling.
More...
BBC micro:bit specific LED handling.
- Author
- Hauke Petersen hauke.nosp@m..pet.nosp@m.ersen.nosp@m.@fu-.nosp@m.berli.nosp@m.n.de
Definition in file microbit.h.
#include <stdint.h>
Go to the source code of this file.
◆ microbit_matrix_off()
void microbit_matrix_off |
( |
uint8_t |
row, |
|
|
uint8_t |
col |
|
) |
| |
Turn off a single LED in the LED matrix.
- Parameters
-
[in] | row | row of the LED |
[in] | col | column of the LED |
◆ microbit_matrix_on()
void microbit_matrix_on |
( |
uint8_t |
row, |
|
|
uint8_t |
col |
|
) |
| |
Turn on a single LED in the LED matrix.
- Parameters
-
[in] | row | row of the LED |
[in] | col | column of the LED |
◆ microbit_matrix_set_char()
void microbit_matrix_set_char |
( |
char |
c | ) |
|
Write the given character to the matrix, using the Mineplex font.
- Parameters
-
[in] | c | character to display |
◆ microbit_matrix_set_raw()
void microbit_matrix_set_raw |
( |
const uint8_t * |
buf | ) |
|
Write the given 'image' to the LED matrix.
In the given buffer, each byte represents one LED in the matrix, hence the buffer MUST be at least 25 byte wide. A byte value of 0
turns an LED off, while any other value turns it on.
- Parameters
-
[in] | buf | new data to display, MUST be at least 25 byte |
◆ microbit_matrix_shift_str()
void microbit_matrix_shift_str |
( |
const char * |
str, |
|
|
uint32_t |
delay |
|
) |
| |
Shift the given string through the LED matrix.
- Parameters
-
[in] | str | string do display |
[in] | delay | delay between each step [in us] |