versadac  1
versadac - Scalable Recorder Firmware
vk.h
1 #ifndef VK_H
2 #define VK_H
3 
4 
5 
6 //
7 // Define the maximum number of digits that can be entered on the numeric VK
8 //
9 #define MAX_VK_NUMERIC_DIGITS 20
10 
11 
12 #if __cplusplus
13 extern "C"
14 {
15 #endif
16 
17 
18 typedef struct
19 {
20  uint8 page;
21  uint8 key;
22  uint8 old_key;
23  uint8 popup_return_key;
24  uint8 popup_return_page;
25 
26  struct
27  {
28  uint8 overwrite : 1;
29  uint8 upper_case : 1;
30  uint8 select_popup_character : 1;
31  uint8 select_armed : 1;
32  uint8 at_low_limit : 1; // On entry to the numeric only VK, this flag gets set if value at low limit and enumerated
33  uint8 show_low_limit_enumeration : 1; // Set to TRUE when the value being shown is the low limit enumeration string
34  } flags;
35 
36  struct
37  {
38  uint16 position;
39  uint8 timeout;
40  uint8 flash;
41  } cursor;
42 
43  uint16 start; // index into the displayed string (which character to start showing from)
44  uint16 end; // index into the displayed string (defines the last character shown)
45  uint16 length; // number of characters in 's'
46  uint8 max_string_length; // Maximum number of characters (as specified in the .uef file for each parameter)
47  unicode_c s[256]; // the string being edited (note the maximum size)
48  unicode_c numeric_old[32]; // keep a copy of the numeric only float string
49 } vk_t;
50 
51 
52 /* Public functions */
53 void virtual_keyboard (update_flags_t z_update);
54 void virtual_numeric_keyboard (update_flags_t z_update);
55 void virtual_keyboard_popup (update_flags_t z_update);
56 
57 
58 #if __cplusplus
59 } /* extern "C" */
60 #endif
61 
62 
63 #endif
Definition: vk.h:18