Rev 50 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 50 | Rev 54 | ||
---|---|---|---|
Line 58... | Line 58... | ||
58 | uint16_t int_max) |
58 | uint16_t int_max) |
59 | { |
59 | { |
60 | display.fontSigDigits (small_font, 0, 0, 0, dp_pos, int_min, WHITE); |
60 | display.fontSigDigits (small_font, 0, 0, 0, dp_pos, int_min, WHITE); |
61 | display.gotoxy (0, 8); |
61 | display.gotoxy (0, 8); |
62 | 62 | ||
63 | display.printString (small_font, "Min°", 4, WHITE); |
63 | display.printString (small_font, "Min", 3, WHITE); |
64 | 64 | ||
65 | display.fontSigDigits (small_font, 120, 0, 1, dp_pos, int_max, WHITE); |
65 | display.fontSigDigits (small_font, 120, 0, 1, dp_pos, int_max, WHITE); |
66 | display.gotoxy (110, 8); |
66 | display.gotoxy (110, 8); |
67 | display.printString (small_font, "Max", 3, WHITE); |
67 | display.printString (small_font, "Max", 3, WHITE); |
68 | } |
68 | } |
Line 88... | Line 88... | ||
88 | for (auto i = 0; i < MAX_DISPLAYS; i++) |
88 | for (auto i = 0; i < MAX_DISPLAYS; i++) |
89 | { |
89 | { |
90 | display_t &display = displays[i]; |
90 | display_t &display = displays[i]; |
91 | displayDial_t &dial = dials[i]; |
91 | displayDial_t &dial = dials[i]; |
92 | display.clearDisplay (); |
92 | display.clearDisplay (); |
93 | display.setPixelMode(WHITE); |
93 | display.setPixelMode (WHITE); |
94 | dial.draw_scale (0, 10, 12, 1, 1); |
94 | dial.draw_scale (0, 10, 12, 1, 1); |
95 | dial.draw_limits (); |
95 | dial.draw_limits (); |
96 | display.gotoxy (8, 32); |
96 | display.gotoxy (8, 32); |
97 | display.printString (large_font, "Display ", 8, WHITE); |
97 | display.printString (large_font, "Display ", 8, WHITE); |
98 | display.printString (large_font, i == 0 ? "1" : "2", 1, BLACK); |
98 | display.printString (large_font, i == 0 ? "1" : "2", 1, BLACK); |
Line 193... | Line 193... | ||
193 | context.dial_timer--; |
193 | context.dial_timer--; |
194 | 194 | ||
195 | if (context.dial_timer == 0) |
195 | if (context.dial_timer == 0) |
196 | { |
196 | { |
197 | uint16_t curr_val = dial_pos[dialIndex]; |
197 | uint16_t curr_val = dial_pos[dialIndex]; |
- | 198 | if (curr_val >= 0) // do not write -1 as a setting. |
|
198 | 199 | { |
|
199 | uint32_t addr = (uint32_t) (&dial_nvram[dialIndex]); |
200 | uint32_t addr = (uint32_t) (&dial_nvram[dialIndex]); |
200 | WriteUint16NVRAM (addr, curr_val); |
201 | WriteUint16NVRAM (addr, curr_val); |
201 | 202 | } |
|
202 | } |
203 | } |
203 | } |
204 | } |
204 | } |
205 | } |
205 | 206 | ||
206 | } |
207 | } |