Add two threads into the IOT WIFIDemo for test_JacobShi

Dependencies:   C12832 HTTPClient wifiontros wifirtos mbed

Fork of frdm_rtos by Freescale

Committer:
shiyilei
Date:
Fri Dec 05 02:14:44 2014 +0000
Revision:
4:242715d40e54
Parent:
3:5f921ff0868d
wifibasedonrtos

Who changed what in which revision?

UserRevisionLine numberNew contents of line
shiyilei 3:5f921ff0868d 1 #ifndef __SYSINTERFACE_H
shiyilei 3:5f921ff0868d 2 #define __SYSINTERFACE_H
shiyilei 3:5f921ff0868d 3 #include "mbed.h"
shiyilei 3:5f921ff0868d 4 #include "rtos.h"
shiyilei 4:242715d40e54 5 #include "baseinterface.h"
shiyilei 4:242715d40e54 6 typedef struct publicdata{
shiyilei 4:242715d40e54 7 bool send_ready;
shiyilei 4:242715d40e54 8 bool send_completed;
shiyilei 4:242715d40e54 9 bool receive_completed;
shiyilei 4:242715d40e54 10 short send_length;
shiyilei 4:242715d40e54 11 short send_length_over;
shiyilei 4:242715d40e54 12 char send_buffer[600];
shiyilei 4:242715d40e54 13 char receive_buffer[600];
shiyilei 4:242715d40e54 14 int receive_length;
shiyilei 4:242715d40e54 15 int need_receive;
shiyilei 4:242715d40e54 16 short need_send;
shiyilei 4:242715d40e54 17 bool receive_start;
shiyilei 4:242715d40e54 18 bool readable;
shiyilei 4:242715d40e54 19 } PUBLICDATA;
shiyilei 4:242715d40e54 20 extern PUBLICDATA globaldata;
shiyilei 3:5f921ff0868d 21 void send_task(void const *args);
shiyilei 3:5f921ff0868d 22 void recv_task(void const *args);
shiyilei 3:5f921ff0868d 23 #define sys_thread_new(taskname,function) Thread taskname(function)
shiyilei 3:5f921ff0868d 24 #define net_system_start sys_thread_new(task2,recv_task);sys_thread_new(task1,send_task);
shiyilei 3:5f921ff0868d 25 #endif