27 lines
611 B
C
27 lines
611 B
C
#ifndef CLASS_EEM
|
|
#define CLASS_EEM
|
|
|
|
#include <stdint.h>
|
|
|
|
#include "../usb_callback_event.h"
|
|
|
|
typedef struct {
|
|
uint8_t data_ep; // bulk data in and out endpoint pair
|
|
bool initialized; // EEM is initialized
|
|
} USB_EemState;
|
|
|
|
/**
|
|
* Initialize USB EEM module.
|
|
* @param data_ep data endpoint number
|
|
*/
|
|
void usb_eem_init(uint8_t data_ep);
|
|
|
|
/**
|
|
* Callback function for data reception and transmission.
|
|
* @param cbevt pointer to callback event structure
|
|
* @return function returns how to proceed with packet processing
|
|
*/
|
|
int usb_eem_process_and_return(USB_CallbackEvent * cbevt);
|
|
|
|
#endif /* CLASS_EEM */
|