-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdodisplay.c
48 lines (34 loc) · 881 Bytes
/
dodisplay.c
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#include "dodisplay.h"
#include <stdio.h>
// Mostly just a list of things to do in order.
void do_main_display(lcd_device *lcdfd,int presence,int hits[4],int deskid)
{
char buf[64];
lcd_clear(lcdfd);
lcd_gotoxy(lcdfd,0,0);
snprintf(buf,64,"Wht Grn Ylo Red Here:%2d",presence);
lcd_puts(lcdfd,buf);
lcd_gotoxy(lcdfd,0,1);
snprintf(buf,64,"%3d %3d %3d %3d D:%c",
hits[0],
hits[1],
hits[2],
hits[3],
deskid==1 ? 'A':'B');
lcd_puts(lcdfd,buf);
}
void do_init_display(lcd_device *lcdfd)
{
lcd_clear(lcdfd);
lcd_gotoxy(lcdfd,0,0);
lcd_puts(lcdfd,"Help Desk Stats for ALL!");
// Read initial button and presence state.
lcd_force_button_update(lcdfd);
lcd_gotoxy(lcdfd,0,1);
lcd_puts(lcdfd,"Waiting for server...");
}
void do_network_activity(lcd_device *lcdfd)
{
lcd_gotoxy(lcdfd,21,1);
lcd_puts(lcdfd,"\n\t");
}