Last change
on this file since 388 was 388, checked in by coas-nagasima, 5 years ago |
Azure IoT Hub Device C SDK を使ったサンプルの追加
|
-
Property svn:eol-style
set to
native
-
Property svn:keywords
set to
Id
-
Property svn:mime-type
set to
text/x-chdr
|
File size:
1.1 KB
|
Rev | Line | |
---|
[388] | 1 | #ifndef usb_hbth_h
|
---|
| 2 | #define usb_hbth_h
|
---|
| 3 |
|
---|
| 4 | #include <sil.h>
|
---|
| 5 | #include "rx630.h"
|
---|
| 6 |
|
---|
| 7 | /*
|
---|
| 8 | * USB HOST ã¿ã¹ã¯ã®ããã®å®æ°
|
---|
| 9 | */
|
---|
| 10 | #define USBHOST_PRIORITY (4)
|
---|
| 11 | #define USBHOST_STACK_SIZE 2048
|
---|
| 12 |
|
---|
| 13 | enum task_event_t {
|
---|
| 14 | TASK_EVENT_START,
|
---|
| 15 | TASK_EVENT_TERMINATE,
|
---|
| 16 | TASK_EVENT_WAKEUP,
|
---|
| 17 | TASK_EVENT_TIMEOUT,
|
---|
| 18 | TASK_EVENT_TICK = 0x80,
|
---|
| 19 | };
|
---|
| 20 |
|
---|
| 21 | struct task_if_t {
|
---|
| 22 | void (*on_start)(struct task_if_t *task, ID tskid);
|
---|
| 23 | void (*on_end)(struct task_if_t *task);
|
---|
| 24 | int (*get_timer)(struct task_if_t *task);
|
---|
| 25 | void (*progress)(struct task_if_t *task, int elapse);
|
---|
| 26 | void (*process)(struct task_if_t *task, enum task_event_t event);
|
---|
| 27 | };
|
---|
| 28 |
|
---|
| 29 | extern struct task_if_t bt_task;
|
---|
| 30 |
|
---|
| 31 | void usbhost_init(ID tskid);
|
---|
| 32 | void usbhost_main(intptr_t exinf);
|
---|
| 33 |
|
---|
| 34 | /*
|
---|
| 35 | * USBå²è¾¼ã¿ãã³ãã©ç»é²ã®ããã®å®æ°
|
---|
| 36 | */
|
---|
| 37 | #define INHNO_USB INT_USB0_USBI0 /* å²è¾¼ã¿ãã³ãã©çªå· */
|
---|
| 38 | #define INTNO_USB INT_USB0_USBI0 /* å²è¾¼ã¿çªå· */
|
---|
| 39 | #define INTPRI_USB -5 /* å²è¾¼ã¿åªå
|
---|
| 40 | 度 */
|
---|
| 41 | #define INTATR_USB (TA_EDGE) /* å²è¾¼ã¿å±æ§ */
|
---|
| 42 |
|
---|
| 43 | void usb_interrupt_handler(void);
|
---|
| 44 | int bt_usb_hbth_bulk_write(unsigned char *packet, int size);
|
---|
| 45 | int bt_usb_hbth_control_write(unsigned char *packet, int size);
|
---|
| 46 |
|
---|
| 47 | #endif // usb_hbth_h
|
---|
Note:
See
TracBrowser
for help on using the repository browser.