Functions which handle the display. More...
Modules | |
| Advanced informations | |
Functions | |
| void | lcdout (uint8_t data) |
| Writes one byte to the display. More... | |
| void | lcdstr (const char *send_data) |
| Writes a string located in the RAM to the display. More... | |
| void | lcdstr_p (const char *send_data) |
| Writes a string located in the flash to the display. More... | |
| void | lcdclr (void) |
| Clears the display. More... | |
| void | lcdxy (uint8_t x, uint8_t y) |
| Moves the cursor to a postion on the display. More... | |
Additional Functions (printf-style) | |
| void | lcdfout (const char *format,...) |
| Display formated text. More... | |
Functions which handle the display.
| void lcdclr | ( | void | ) |
Clears the display.
| void lcdfout | ( | const char * | format, |
| ... | |||
| ) |
Display formated text.
To use this function, include tucbot_additionals/fout.h into your code.
#include <tucbot_additionals/fout.h>
int main(void) {
init_tucbot(0xFF);
battery_request(kRequestWait);
while (1) {
lcdclr();
lcdfout("V=%d",battery_get());
mdelay(1000);
}
}| format | Format string.
| ||||||||||||
| ... | For each place holder, a variable has to be added as parameter of the function |
| void lcdout | ( | uint8_t | data | ) |
Writes one byte to the display.
| data | 8-bit unsigned integer |
| void lcdstr | ( | const char * | send_data | ) |
Writes a string located in the RAM to the display.
This function loads the referenced string character by character and writes those using the lcdout() function until a terminating \ 0-character is found.
| *send_data | 16-bit pointer to a character located in the RAM |
| void lcdstr_p | ( | const char * | send_data | ) |
Writes a string located in the flash to the display.
This function loads the referenced string character by character and writes those using the lcdout() function until a terminating \ 0-character is found.
| *send_data | 16-bit pointer to a character located in the flash |
| void lcdxy | ( | uint8_t | x, |
| uint8_t | y | ||
| ) |
Moves the cursor to a postion on the display.
The column is set by the x parameter and can be between 0 and 15.
The row is set by the y parameter and can be between 0 and 1.
| x | 8-bit unsigned integer (0..15) 0 is the most left character. 15 is the most right character. |
| y | 8-bit integer. (0..1) 0 is the upper line. 1 is the lower line. |
1.8.17