blob: 15fc2a42109d80ca089539790b68d52ef329c896 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
#include <stdint.h>
#include "ubox.h"
#include "aux.h"
/**
* Put a zero terminated string on the screen using tiles.
*
* The font starts on the tileset on tile 128 and the fist char in our has
* ASCII value 31, so it is adjusted so we can use ASCII *uppercase* directly
* in our C code.
*/
void put_text(uint8_t x, uint8_t y, const uint8_t *text)
{
while (*text)
ubox_put_tile(x++, y, *text++ + 128 - 31);
}
/**
* Wait for `frames` frames.
*/
void wait_for(uint8_t frames)
{
while (frames--)
ubox_wait();
}
|