3 #include "task_audio.h"
4 #include "task_display.h"
8 #define MENU_CMD_INPUT 'i'
9 #define MENU_CMD_REMOTE 'r'
14 int menu_input_from_isr(int left, int right, int sw)
16 char *p = kx_kmalloc(4);
17 p[0] = MENU_CMD_INPUT;
21 kx_send(MSGBOX_ID_MENU, 4, p);
25 int menu_remote_from_isr(char *signal, int siz)
27 char *p = kx_kmalloc(8);
28 p[0] = MENU_CMD_REMOTE;
36 kx_send(MSGBOX_ID_MENU, 8, p);
40 #define NIJIMASU_GO_LEFT() \
44 display_draw_box(nx + 20, ny, nx + 20, ny + 16, 0); \
45 display_draw_logo(nx, ny, 0); \
46 display_led_write(1, 0); \
47 display_led_toggle(0); \
51 #define NIJIMASU_GO_RIGHT() \
55 display_draw_box(nx + 20, ny, nx + 20, ny + 16, 0); \
56 display_draw_logo(nx, ny, 0); \
57 display_led_write(0, 0); \
58 display_led_toggle(1); \
62 static int menu_cmdproc(char *p)
77 ((uint32)p[4] << 24) |
78 ((uint32)p[5] << 16) |
85 audio_volume(volume, volume);
91 audio_volume(volume, volume);
119 int task_menu(int argc, char *argv[])
122 display_draw_logo( 0, 0, 2);
123 display_draw_box(0, 0, 121, 31, 1);
124 display_draw_text(40, 4, "KOZOS EXPBRD #00");
125 display_draw_logo(nx, ny, 0);
127 audio_volume(volume, volume);
132 kz_recv(MSGBOX_ID_MENU, &size, &p);