tell it what ver it is

This commit is contained in:
2026-07-21 20:57:39 +02:00
parent 9419230747
commit 7caef9c744
2 changed files with 25 additions and 2 deletions

View File

@@ -98,9 +98,16 @@ static void *display_thread(void *arg) {
lcd_init(&lcd);
lcd_set_backlight(&lcd, true);
lcd_set_contrast(&lcd, lcd_contrast);
lcd_write_buf(&lcd, 1, 9, "Waiting for sensors..."); // need to center this still
lcd_write_buf(&lcd, 0, 14, "linuxSmartie");
lcd_writef(&lcd, 0, 2, "Ver. hash %s", GIT_HASH);
lcd_writef(&lcd, 0, 3, "Commit no. %s", GIT_COMMITS);
lcd_flush_buf(&lcd);
lcd_clear_buf(&lcd);
struct timespec next;
clock_gettime(CLOCK_REALTIME, &next);
timespec_add_ms(&next, refresh_interval_ms);
clock_nanosleep(CLOCK_REALTIME, TIMER_ABSTIME, &next, nullptr);
/* setup custom chars */
lcd_set_custom_char(&lcd, 0, &(lcd_glyph_t){16, 6, 9, 8, 8, 9, 6, 0}); // celcius
@@ -172,7 +179,7 @@ static void *display_thread(void *arg) {
}
int main(void) {
applog(LOG_START, "linuxSmartie starting");
applog(LOG_START, "linuxSmartie r%s (%s) starting", GIT_COMMITS, GIT_HASH);
applog(LOG_DBG, "Compiled with %s", C_STD);
/* see if another instance is up, quit if it is */