Exemplo n.º 1
0
void _tdispInit(void) {
	MUTEX_INIT();

	MUTEX_ENTER();
	tdisp_lld_init();
	MUTEX_LEAVE();
}
Exemplo n.º 2
0
void tdispSetBacklight(uint16_t percentage) {
	if (percentage > 100)
	  percentage = 100;
	MUTEX_ENTER();
	tdisp_lld_set_backlight(percentage);
	MUTEX_LEAVE();
}
Exemplo n.º 3
0
void tdispCreateChar(uint8_t address, uint8_t *charmap) {
	/* make sure we don't write somewhere we're not supposed to */
	if (address < TDISP.maxCustomChars) {
		MUTEX_ENTER();
		tdisp_lld_create_char(address, charmap);
		MUTEX_LEAVE();
	}
}
Exemplo n.º 4
0
void tdispSetCursor(coord_t col, coord_t row) {
	/* Keep the input range valid */
	if (row >= TDISP.rows)
		row = TDISP.rows - 1;
	MUTEX_ENTER();
	tdisp_lld_set_cursor(col, row);
	MUTEX_LEAVE();
}
Exemplo n.º 5
0
Arquivo: tdisp.c Projeto: DaviWei/uGFX
bool_t tdispInit(void) {
	bool_t		res;

	MUTEX_INIT();

	MUTEX_ENTER();
	res = tdisp_lld_init();
	MUTEX_LEAVE();

	return res;
}
Exemplo n.º 6
0
void tdispScroll(uint16_t direction, uint16_t amount, uint16_t delay) {
	MUTEX_ENTER();
	tdisp_lld_scroll(direction, amount, delay);
	MUTEX_LEAVE();
}
Exemplo n.º 7
0
void tdispControl(uint16_t what, uint16_t value) {
	MUTEX_ENTER();
	tdisp_lld_control(what, value);
	MUTEX_LEAVE();
}
Exemplo n.º 8
0
void tdispDrawString(char *s) {
	MUTEX_ENTER();
	while(*s)
		tdisp_lld_draw_char(*s++);
	MUTEX_LEAVE();
}
Exemplo n.º 9
0
void tdispDrawChar(char c) {
	MUTEX_ENTER();
	tdisp_lld_draw_char(c);
	MUTEX_LEAVE();
}
Exemplo n.º 10
0
void tdispHome(void) {
	MUTEX_ENTER();
	tdisp_lld_set_cursor(0, 0);
	MUTEX_LEAVE();
}
Exemplo n.º 11
0
void tdispClear(void) {
	MUTEX_ENTER();
	tdisp_lld_clear();
	MUTEX_LEAVE();
}