diff options
Diffstat (limited to 'fw/fe310/test/cell_dev.c')
-rw-r--r-- | fw/fe310/test/cell_dev.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/fw/fe310/test/cell_dev.c b/fw/fe310/test/cell_dev.c new file mode 100644 index 0000000..40f2736 --- /dev/null +++ b/fw/fe310/test/cell_dev.c @@ -0,0 +1,24 @@ +#include <stdio.h> +#include <stdlib.h> +#include <unistd.h> +#include <string.h> + +#include <eos.h> +#include <net.h> +#include <cell.h> + +#include "status.h" +#include "cell_dev.h" + +static void cell_dev_handler(unsigned char type, unsigned char *buffer, uint16_t len) { + switch (type) { + case EOS_CELL_MTYPE_READY: + app_status_msg_set("Modem ready", 1); + break; + } + eos_net_free(buffer, 0); +} + +void app_cell_dev_init(void) { + eos_cell_set_handler(EOS_CELL_MTYPE_DEV, cell_dev_handler); +} |