78#define PROG_REG_NO_PORT 0xFFu
80#define PROG_REG_NO_PIN 0xFFu
83#define PROG_REG_PORTS 4u
86#define PROG_REG_TESTER_PORT 0xFEu
94#if defined(__GNUC__) && !defined(__clang__)
95#define PROG_ONE_CALL __attribute__((noinline, noclone))
97#define PROG_ONE_CALL __attribute__((noinline))
107#define PROG_FULL_STRIP_X 12
108#define PROG_FULL_STRIP_Y 4
109#define PROG_FULL_STRIP_H 20
110#define PROG_FULL_Y 28
111#define PROG_FULL_STRIP_FONT (&gfx_font_10x20)
114#define PROG_FULL_STRIP_CELLS 100
117#define PROG_LIST_SEARCH_OVER 9
118#define PROG_LIST_HEADINGS_OVER 8
119#define PROG_LIST_MAX 48
121#define PROG_LIST_QUERY_MAX 16
135 bool (*is_open)(void);
147 void (*tick)(
float dt_s);
148 bool (*has_press)(uint8_t id);
283 size_t i, uint16_t caps);
308 uint16_t caps,
char *out,
size_t size);
336 uint8_t device, uint8_t task,
const char *query);
350#define PROG_VIEW_PAD 10
351#define PROG_VIEW_BAR_H 48
352#define PROG_VIEW_ROW_H 48
353#define PROG_VIEW_ROW_P 56
354#define PROG_VIEW_HEAD_H 28
355#define PROG_VIEW_HEAD_P 32
356#define PROG_VIEW_SEARCH_W 260
357#define PROG_VIEW_KEY_W 56
358#define PROG_VIEW_FONT (&gfx_font_10x20)
361enum { PROG_VIEW_P_NONE = -1, PROG_VIEW_P_SEARCH = -2, PROG_VIEW_P_UP = -3,
362 PROG_VIEW_P_DOWN = -4 };
gfx: an RGB565 (16-bit red, green, blue) rasteriser with no dependencies.
#define k
Short name for kst_panel_k inside the overlay's seven files.
Definition kst_panel_int.h:238
const prog_reg_row_t * prog_registry(size_t *count)
Definition prog_registry.c:87
void prog_view_top(prog_view_t *v)
Definition prog_registry.c:478
gfx_rect_t prog_view_up_rect(const prog_view_t *v, const prog_list_t *l)
"^" on the bar, PROG_VIEW_KEY_W wide, 8px left of "v".
Definition prog_registry.c:593
#define PROG_LIST_QUERY_MAX
Definition prog_registry.h:121
bool prog_reg_servo_holds(void)
Whether a servo programmer holds a port: the KST programmer's session, or the Hitec programmer's,...
Definition prog_registry.c:82
bool prog_view_has_bar(const prog_view_t *v, const prog_list_t *l)
Definition prog_registry.c:514
prog_device_t
Definition prog_registry.h:71
void prog_list_build(prog_list_t *l, const prog_reg_row_t *rows, size_t n, uint8_t device, uint8_t task, const char *query)
Definition prog_registry.c:418
const char * prog_reg_cap_name(uint16_t bit)
Definition prog_registry.c:362
int prog_view_shown(const prog_view_t *v, const prog_list_t *l)
Definition prog_registry.c:544
gfx_rect_t prog_view_down_rect(const prog_view_t *v, const prog_list_t *l)
"v" on the bar, PROG_VIEW_KEY_W wide at the right.
Definition prog_registry.c:604
void prog_registry_use(const prog_reg_row_t *rows, size_t count)
Definition prog_registry.c:95
prog_view_ev_t
Definition prog_registry.h:373
@ PROG_VIEW_NONE
Definition prog_registry.h:374
@ PROG_VIEW_SEARCH
Definition prog_registry.h:377
@ PROG_VIEW_ROW
Definition prog_registry.h:376
@ PROG_VIEW_TAKEN
Definition prog_registry.h:375
int prog_reg_sets(uint8_t device, const prog_page_set_t *out[PROG_LIST_MAX])
Definition prog_registry.c:182
gfx_rect_t prog_view_entry_rect(const prog_view_t *v, const prog_list_t *l, int k)
Definition prog_registry.c:558
prog_row_state_t
Definition prog_registry.h:275
@ PROG_ROW_NO_CAP
Definition prog_registry.h:277
@ PROG_ROW_LIVE
Definition prog_registry.h:276
@ PROG_ROW_PORT_BUSY
Definition prog_registry.h:278
uint16_t prog_reg_missing(const prog_reg_row_t *row, uint16_t caps)
Definition prog_registry.c:312
void prog_view_render(const prog_view_t *v, const prog_list_t *l, const prog_reg_row_t *rows, size_t n, uint16_t caps, const char *query, gfx_canvas_t *c)
Draws the list in PROG_VIEW_FONT: query in the SEARCH box ("SEARCH" while empty), each row's name and...
Definition prog_registry.c:711
prog_reg_fault_t prog_reg_check(const prog_reg_row_t *rows, size_t n, size_t *at)
Definition prog_registry.c:129
prog_view_ev_t prog_view_event(prog_view_t *v, const prog_list_t *l, const touch_event_t *evt, uint8_t *row)
Definition prog_registry.c:649
void prog_registry_set_ports(uint8_t tester_port, uint8_t held)
Definition prog_registry.c:64
bool prog_reg_full_width(const prog_page_set_t *ps)
Definition prog_registry.c:202
prog_reg_fault_t
Definition prog_registry.h:213
@ PROG_REG_NO_GROUP
Definition prog_registry.h:218
@ PROG_REG_BAD_DEVICE
Definition prog_registry.h:215
@ PROG_REG_NO_NAME
Definition prog_registry.h:217
@ PROG_REG_BAD_PORT
Definition prog_registry.h:220
@ PROG_REG_NO_TRANSPORT
Definition prog_registry.h:219
@ PROG_REG_NO_PAGE_SET
Definition prog_registry.h:221
@ PROG_REG_BAD_WIDTH
Definition prog_registry.h:226
@ PROG_REG_TOO_MANY
Definition prog_registry.h:223
@ PROG_REG_SAME_NAME
Definition prog_registry.h:222
@ PROG_REG_BAD_TASK
Definition prog_registry.h:216
gfx_rect_t prog_view_search_rect(const prog_view_t *v, const prog_list_t *l)
SEARCH on the bar, PROG_VIEW_SEARCH_W wide from the left.
Definition prog_registry.c:578
void prog_view_cancel(prog_view_t *v)
Definition prog_registry.c:704
prog_row_state_t prog_reg_state(const prog_reg_row_t *rows, size_t n, size_t i, uint16_t caps)
Definition prog_registry.c:321
uint8_t prog_reg_port(const prog_reg_row_t *r)
Definition prog_registry.c:71
bool prog_reg_detail(const prog_reg_row_t *rows, size_t n, size_t i, uint16_t caps, char *out, size_t size)
The text right of row i's name: for a live row on a port its number and the session's pin ("PROG PORT...
Definition prog_registry.c:373
Definition prog_registry.h:313
uint8_t row
Definition prog_registry.h:314
Definition prog_registry.h:318
bool search
Definition prog_registry.h:322
bool headings
Definition prog_registry.h:323
uint8_t rows
Definition prog_registry.h:320
uint8_t total
Definition prog_registry.h:319
uint8_t count
Definition prog_registry.h:321
Definition prog_registry.h:129
void(*) init(gfx_rect_t area)
Definition prog_registry.h:131
bool(*) holds_port(void)
Definition prog_registry.h:144
bool(*) safe_at(int x, int y)
Definition prog_registry.h:165
void(*) leave(void)
Definition prog_registry.h:157
uint32_t(*) hold_revision(void)
Definition prog_registry.h:154
uint32_t(*) revision(void)
Definition prog_registry.h:152
void(*) back(void)
Definition prog_registry.h:141
void(*) armed(bool armed)
Definition prog_registry.h:146
void(*) entry(void)
Definition prog_registry.h:133
void(*) cancel(void)
Definition prog_registry.h:159
uint8_t(*) pin(void)
Definition prog_registry.h:161
Definition prog_registry.h:168
bool full_width
Definition prog_registry.h:179
uint8_t port
Definition prog_registry.h:174
uint16_t needs_capability
Definition prog_registry.h:175
uint8_t task
Definition prog_registry.h:170
uint8_t device
Definition prog_registry.h:169
Definition prog_registry.h:364
int pressed
Definition prog_registry.h:367
uint8_t id
Definition prog_registry.h:368
char query[PROG_LIST_QUERY_MAX+1]
Definition prog_registry.h:370
int top
Definition prog_registry.h:366
A DOWN, MOVE or UP of one contact.
Definition touch_types.h:69
Plain data types shared by the touch controller driver, the coordinate mapper and the event tracker....
The interface's words, one table per language.
ui_text_id_t
The screens' strings, TX_<ID> for each UI_TEXT() of ui_text.def.
Definition ui_text.h:43
A workbench's task strip: one device, its tasks as tabs under the band.