SimpleLink CC3100/CC3200 Host Driver  Version 1.0.1.6
Simplifies the implementation of Internet connectivity
simplelink.h
1 /*
2  * simplelink.h - CC31xx/CC32xx Host Driver Implementation
3  *
4  * Copyright (C) 2015 Texas Instruments Incorporated - https://www.ti.com/
5  *
6  *
7  * Redistribution and use in source and binary forms, with or without
8  * modification, are permitted provided that the following conditions
9  * are met:
10  *
11  * Redistributions of source code must retain the above copyright
12  * notice, this list of conditions and the following disclaimer.
13  *
14  * Redistributions in binary form must reproduce the above copyright
15  * notice, this list of conditions and the following disclaimer in the
16  * documentation and/or other materials provided with the
17  * distribution.
18  *
19  * Neither the name of Texas Instruments Incorporated nor the names of
20  * its contributors may be used to endorse or promote products derived
21  * from this software without specific prior written permission.
22  *
23  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
24  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
25  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
26  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
27  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
28  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
29  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
30  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
31  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
32  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
33  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
34  *
35 */
36 
37 
216 #ifndef __SIMPLELINK_H__
217 #define __SIMPLELINK_H__
218 
219 /* define the default types
220  * If user wants to overwrite it,
221  * he need to undef and define again */
222 #define _u8 unsigned char
223 #define _i8 signed char
224 #define _u16 unsigned short
225 #define _i16 signed short
226 #define _u32 unsigned long
227 #define _i32 signed long
228 
229 #define _volatile volatile
230 #define _const const
231 
232 #include "../user.h"
233 
234 #ifdef __cplusplus
235 extern "C"
236 {
237 #endif
238 
239 
263 /*****************************************************************************/
264 /* Macro declarations for Host Driver version */
265 /*****************************************************************************/
266 #define SL_DRIVER_VERSION "1.0.1.6"
267 #define SL_MAJOR_VERSION_NUM 1L
268 #define SL_MINOR_VERSION_NUM 0L
269 #define SL_VERSION_NUM 1L
270 #define SL_SUB_VERSION_NUM 6L
271 
272 
273 /*****************************************************************************/
274 /* Macro declarations for predefined configurations */
275 /*****************************************************************************/
276 
277 #ifdef SL_TINY
278 
279 #undef SL_INC_ARG_CHECK
280 #undef SL_INC_EXT_API
281 #undef SL_INC_SOCK_SERVER_SIDE_API
282 #undef SL_INC_WLAN_PKG
283 #undef SL_INC_NET_CFG_PKG
284 #undef SL_INC_FS_PKG
285 #undef SL_INC_SET_UART_MODE
286 #undef SL_INC_NVMEM_PKG
287 #define SL_INC_STD_BSD_API_NAMING
288 #define SL_INC_SOCK_CLIENT_SIDE_API
289 #define SL_INC_SOCK_RECV_API
290 #define SL_INC_SOCK_SEND_API
291 #define SL_INC_SOCKET_PKG
292 #define SL_INC_NET_APP_PKG
293 
294 #endif
295 
296 #ifdef SL_SMALL
297 #undef SL_INC_EXT_API
298 #undef SL_INC_NET_APP_PKG
299 #undef SL_INC_NET_CFG_PKG
300 #undef SL_INC_FS_PKG
301 #define SL_INC_ARG_CHECK
302 #define SL_INC_WLAN_PKG
303 #define SL_INC_SOCKET_PKG
304 #define SL_INC_SOCK_CLIENT_SIDE_API
305 #define SL_INC_SOCK_SERVER_SIDE_API
306 #define SL_INC_SOCK_RECV_API
307 #define SL_INC_SOCK_SEND_API
308 #define SL_INC_SET_UART_MODE
309 #endif
310 
311 #ifdef SL_FULL
312 #define SL_INC_EXT_API
313 #define SL_INC_NET_APP_PKG
314 #define SL_INC_NET_CFG_PKG
315 #define SL_INC_FS_PKG
316 #define SL_INC_ARG_CHECK
317 #define SL_INC_WLAN_PKG
318 #define SL_INC_SOCKET_PKG
319 #define SL_INC_SOCK_CLIENT_SIDE_API
320 #define SL_INC_SOCK_SERVER_SIDE_API
321 #define SL_INC_SOCK_RECV_API
322 #define SL_INC_SOCK_SEND_API
323 #define SL_INC_SET_UART_MODE
324 #endif
325 
326 #define SL_RET_CODE_OK (0)
327 #define SL_RET_CODE_INVALID_INPUT (-2)
328 #define SL_RET_CODE_SELF_ERROR (-3)
329 #define SL_RET_CODE_NWP_IF_ERROR (-4)
330 #define SL_RET_CODE_MALLOC_ERROR (-5)
331 #define SL_RET_CODE_ABORT (-6)
332 #define SL_RET_CODE_PROTOCOL_ERROR (-7)
333 
334 
335 /* #define sl_Memcpy memcpy */
336 #define sl_Memset(addr, val, len) memset(addr, val, (size_t)len)
337 #define sl_Memcpy(dest, src, len) memcpy(dest, src, (size_t)len)
338 
339 #ifndef SL_TINY_EXT
340 #define SL_MAX_SOCKETS (_u8)(8)
341 #else
342 #define SL_MAX_SOCKETS (_u8)(2)
343 #endif
344 
345 
346 /*****************************************************************************/
347 /* Types definitions */
348 /*****************************************************************************/
349 
350 #ifndef NULL
351 #define NULL (0)
352 #endif
353 
354 #ifndef FALSE
355 #define FALSE (0)
356 #endif
357 
358 #ifndef TRUE
359 #define TRUE (!FALSE)
360 #endif
361 
362 #ifndef OK
363 #define OK (0)
364 #endif
365 
366 typedef _u16 _SlOpcode_t;
367 typedef _u8 _SlArgSize_t;
368 typedef _i16 _SlDataSize_t;
369 typedef _i16 _SlReturnVal_t;
370 
371 #ifdef __cplusplus
372 }
373 #endif /* __cplusplus */
374 
375 
376 
377 /*
378  * This event status used to block or continue the event propagation
379  * through all the registered external libs/user application
380  *
381  */
382 
383  typedef enum {
384  EVENT_PROPAGATION_BLOCK = 0,
385  EVENT_PROPAGATION_CONTINUE
386 
387  } _SlEventPropogationStatus_e;
388 
389 
390 
391 
392 
393 
394 /*****************************************************************************/
395 /* Include files */
396 /*****************************************************************************/
397 
398 
399 /*
400  objInclusion.h and user.h must be included before all api header files
401  objInclusion.h must be the last arrangement just before including the API header files
402  since it based on the other configurations to decide which object should be included
403 */
404 #include "../source/objInclusion.h"
405 #include "trace.h"
406 #include "fs.h"
407 #include "socket.h"
408 #include "netapp.h"
409 #include "wlan.h"
410 #include "device.h"
411 #include "netcfg.h"
412 #include "wlan_rx_filters.h"
413 
414 
415  /* The general events dispatcher which is
416  * initialized to the user handler */
417 #ifdef sl_GeneralEvtHdlr
418 #define _SlDrvHandleGeneralEvents sl_GeneralEvtHdlr
419 #endif
420 
421  /* The wlan events dispatcher which is
422  * initialized to the user handler */
423 #ifdef sl_WlanEvtHdlr
424 #define _SlDrvHandleWlanEvents sl_WlanEvtHdlr
425 #endif
426 
427  /* The NetApp events dispatcher which is
428  * initialized to the user handler */
429 #ifdef sl_NetAppEvtHdlr
430 #define _SlDrvHandleNetAppEvents sl_NetAppEvtHdlr
431 #endif
432 
433  /* The http server events dispatcher which is
434  * initialized to the user handler if exists */
435 #ifdef sl_HttpServerCallback
436 #define _SlDrvHandleHttpServerEvents sl_HttpServerCallback
437 #endif
438 
439  /* The socket events dispatcher which is
440  * initialized to the user handler */
441 #ifdef sl_SockEvtHdlr
442 #define _SlDrvHandleSockEvents sl_SockEvtHdlr
443 #endif
444 
445 
446 
447 #define __CONCAT(x,y) x ## y
448 #define __CONCAT2(x,y) __CONCAT(x,y)
449 
450 
451 /*
452  * The section below handles the external lib event registration
453  * according to the desired events it specified in its API header file.
454  * The external lib should be first installed by the user (see user.h)
455  */
456 #ifdef SL_EXT_LIB_1
457 
458  /* General Event Registration */
459  #if __CONCAT2(SL_EXT_LIB_1, _NOTIFY_GENERAL_EVENT)
460  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_1, _GeneralEventHdl) (SlDeviceEvent_t *);
461  #define SlExtLib1GeneralEventHandler __CONCAT2(SL_EXT_LIB_1, _GeneralEventHdl)
462 
463  #undef EXT_LIB_REGISTERED_GENERAL_EVENTS
464  #define EXT_LIB_REGISTERED_GENERAL_EVENTS
465  #endif
466 
467  /* Wlan Event Registration */
468  #if __CONCAT2(SL_EXT_LIB_1, _NOTIFY_WLAN_EVENT)
469  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_1, _WlanEventHdl) (SlWlanEvent_t *);
470  #define SlExtLib1WlanEventHandler __CONCAT2(SL_EXT_LIB_1, _WlanEventHdl)
471 
472  #undef EXT_LIB_REGISTERED_WLAN_EVENTS
473  #define EXT_LIB_REGISTERED_WLAN_EVENTS
474  #endif
475 
476  /* NetApp Event Registration */
477  #if __CONCAT2(SL_EXT_LIB_1, _NOTIFY_NETAPP_EVENT)
478  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_1, _NetAppEventHdl) (SlNetAppEvent_t *);
479  #define SlExtLib1NetAppEventHandler __CONCAT2(SL_EXT_LIB_1, _NetAppEventHdl)
480 
481  #undef EXT_LIB_REGISTERED_NETAPP_EVENTS
482  #define EXT_LIB_REGISTERED_NETAPP_EVENTS
483  #endif
484 
485  /* Http Server Event Registration */
486  #if __CONCAT2(SL_EXT_LIB_1, _NOTIFY_HTTP_SERVER_EVENT)
487  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_1, _HttpServerEventHdl) (SlHttpServerEvent_t* , SlHttpServerResponse_t*);
488  #define SlExtLib1HttpServerEventHandler __CONCAT2(SL_EXT_LIB_1, _HttpServerEventHdl)
489 
490  #undef EXT_LIB_REGISTERED_HTTP_SERVER_EVENTS
491  #define EXT_LIB_REGISTERED_HTTP_SERVER_EVENTS
492  #endif
493 
494  /* Socket Event Registration */
495  #if __CONCAT2(SL_EXT_LIB_1, _NOTIFY_SOCK_EVENT)
496  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_1, _SockEventHdl) (SlSockEvent_t *);
497  #define SlExtLib1SockEventHandler __CONCAT2(SL_EXT_LIB_1, _SockEventHdl)
498 
499  #undef EXT_LIB_REGISTERED_SOCK_EVENTS
500  #define EXT_LIB_REGISTERED_SOCK_EVENTS
501  #endif
502 
503 #endif
504 
505 
506 #ifdef SL_EXT_LIB_2
507 
508  /* General Event Registration */
509  #if __CONCAT2(SL_EXT_LIB_2, _NOTIFY_GENERAL_EVENT)
510  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_2, _GeneralEventHdl) (SlDeviceEvent_t *);
511  #define SlExtLib2GeneralEventHandler __CONCAT2(SL_EXT_LIB_2, _GeneralEventHdl)
512 
513  #undef EXT_LIB_REGISTERED_GENERAL_EVENTS
514  #define EXT_LIB_REGISTERED_GENERAL_EVENTS
515  #endif
516 
517  /* Wlan Event Registration */
518  #if __CONCAT2(SL_EXT_LIB_2, _NOTIFY_WLAN_EVENT)
519  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_2, _WlanEventHdl) (SlWlanEvent_t *);
520  #define SlExtLib2WlanEventHandler __CONCAT2(SL_EXT_LIB_2, _WlanEventHdl)
521 
522  #undef EXT_LIB_REGISTERED_WLAN_EVENTS
523  #define EXT_LIB_REGISTERED_WLAN_EVENTS
524  #endif
525 
526  /* NetApp Event Registration */
527  #if __CONCAT2(SL_EXT_LIB_2, _NOTIFY_NETAPP_EVENT)
528  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_2, _NetAppEventHdl) (SlNetAppEvent_t *);
529  #define SlExtLib2NetAppEventHandler __CONCAT2(SL_EXT_LIB_2, _NetAppEventHdl)
530 
531  #undef EXT_LIB_REGISTERED_NETAPP_EVENTS
532  #define EXT_LIB_REGISTERED_NETAPP_EVENTS
533  #endif
534 
535  /* Http Server Event Registration */
536  #if __CONCAT2(SL_EXT_LIB_2, _NOTIFY_HTTP_SERVER_EVENT)
537  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_2, _HttpServerEventHdl) (SlHttpServerEvent_t* , SlHttpServerResponse_t*);
538  #define SlExtLib2HttpServerEventHandler __CONCAT2(SL_EXT_LIB_2, _HttpServerEventHdl)
539 
540  #undef EXT_LIB_REGISTERED_HTTP_SERVER_EVENTS
541  #define EXT_LIB_REGISTERED_HTTP_SERVER_EVENTS
542  #endif
543 
544  /* Socket Event Registration */
545  #if __CONCAT2(SL_EXT_LIB_2, _NOTIFY_SOCK_EVENT)
546  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_2, _SockEventHdl) (SlSockEvent_t *);
547  #define SlExtLib2SockEventHandler __CONCAT2(SL_EXT_LIB_2, _SockEventHdl)
548 
549  #undef EXT_LIB_REGISTERED_SOCK_EVENTS
550  #define EXT_LIB_REGISTERED_SOCK_EVENTS
551  #endif
552 
553 #endif
554 
555 
556 #ifdef SL_EXT_LIB_3
557 
558  /* General Event Registration */
559  #if __CONCAT2(SL_EXT_LIB_3, _NOTIFY_GENERAL_EVENT)
560  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_3, _GeneralEventHdl) (SlDeviceEvent_t *);
561  #define SlExtLib3GeneralEventHandler __CONCAT2(SL_EXT_LIB_3, _GeneralEventHdl)
562 
563  #undef EXT_LIB_REGISTERED_GENERAL_EVENTS
564  #define EXT_LIB_REGISTERED_GENERAL_EVENTS
565  #endif
566 
567  /* Wlan Event Registration */
568  #if __CONCAT2(SL_EXT_LIB_3, _NOTIFY_WLAN_EVENT)
569  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_3, _WlanEventHdl) (SlWlanEvent_t *);
570  #define SlExtLib3WlanEventHandler __CONCAT2(SL_EXT_LIB_3, _WlanEventHdl)
571 
572  #undef EXT_LIB_REGISTERED_WLAN_EVENTS
573  #define EXT_LIB_REGISTERED_WLAN_EVENTS
574  #endif
575 
576  /* NetApp Event Registration */
577  #if __CONCAT2(SL_EXT_LIB_3, _NOTIFY_NETAPP_EVENT)
578  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_3, _NetAppEventHdl) (SlNetAppEvent_t *);
579  #define SlExtLib3NetAppEventHandler __CONCAT2(SL_EXT_LIB_3, _NetAppEventHdl)
580 
581  #undef EXT_LIB_REGISTERED_NETAPP_EVENTS
582  #define EXT_LIB_REGISTERED_NETAPP_EVENTS
583  #endif
584 
585  /* Http Server Event Registration */
586  #if __CONCAT2(SL_EXT_LIB_3, _NOTIFY_HTTP_SERVER_EVENT)
587  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_3, _HttpServerEventHdl) (SlHttpServerEvent_t* , SlHttpServerResponse_t*);
588  #define SlExtLib3HttpServerEventHandler __CONCAT2(SL_EXT_LIB_3, _HttpServerEventHdl)
589 
590  #undef EXT_LIB_REGISTERED_HTTP_SERVER_EVENTS
591  #define EXT_LIB_REGISTERED_HTTP_SERVER_EVENTS
592  #endif
593 
594  /* Socket Event Registration */
595  #if __CONCAT2(SL_EXT_LIB_3, _NOTIFY_SOCK_EVENT)
596  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_3, _SockEventHdl) (SlSockEvent_t *);
597  #define SlExtLib3SockEventHandler __CONCAT2(SL_EXT_LIB_3, _SockEventHdl)
598 
599  #undef EXT_LIB_REGISTERED_SOCK_EVENTS
600  #define EXT_LIB_REGISTERED_SOCK_EVENTS
601  #endif
602 
603 #endif
604 
605 
606 #ifdef SL_EXT_LIB_4
607 
608  /* General Event Registration */
609  #if __CONCAT2(SL_EXT_LIB_4, _NOTIFY_GENERAL_EVENT)
610  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_4, _GeneralEventHdl) (SlDeviceEvent_t *);
611  #define SlExtLib4GeneralEventHandler __CONCAT2(SL_EXT_LIB_4, _GeneralEventHdl)
612 
613  #undef EXT_LIB_REGISTERED_GENERAL_EVENTS
614  #define EXT_LIB_REGISTERED_GENERAL_EVENTS
615  #endif
616 
617  /* Wlan Event Registration */
618  #if __CONCAT2(SL_EXT_LIB_4, _NOTIFY_WLAN_EVENT)
619  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_4, _WlanEventHdl) (SlWlanEvent_t *);
620  #define SlExtLib4WlanEventHandler __CONCAT2(SL_EXT_LIB_4, _WlanEventHdl)
621 
622  #undef EXT_LIB_REGISTERED_WLAN_EVENTS
623  #define EXT_LIB_REGISTERED_WLAN_EVENTS
624  #endif
625 
626  /* NetApp Event Registration */
627  #if __CONCAT2(SL_EXT_LIB_4, _NOTIFY_NETAPP_EVENT)
628  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_4, _NetAppEventHdl) (SlNetAppEvent_t *);
629  #define SlExtLib4NetAppEventHandler __CONCAT2(SL_EXT_LIB_4, _NetAppEventHdl)
630 
631  #undef EXT_LIB_REGISTERED_NETAPP_EVENTS
632  #define EXT_LIB_REGISTERED_NETAPP_EVENTS
633  #endif
634 
635  /* Http Server Event Registration */
636  #if __CONCAT2(SL_EXT_LIB_4, _NOTIFY_HTTP_SERVER_EVENT)
637  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_4, _HttpServerEventHdl) (SlHttpServerEvent_t* , SlHttpServerResponse_t*);
638  #define SlExtLib4HttpServerEventHandler __CONCAT2(SL_EXT_LIB_4, _HttpServerEventHdl)
639 
640  #undef EXT_LIB_REGISTERED_HTTP_SERVER_EVENTS
641  #define EXT_LIB_REGISTERED_HTTP_SERVER_EVENTS
642  #endif
643 
644  /* Socket Event Registration */
645  #if __CONCAT2(SL_EXT_LIB_4, _NOTIFY_SOCK_EVENT)
646  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_4, _SockEventHdl) (SlSockEvent_t *);
647  #define SlExtLib4SockEventHandler __CONCAT2(SL_EXT_LIB_4, _SockEventHdl)
648 
649  #undef EXT_LIB_REGISTERED_SOCK_EVENTS
650  #define EXT_LIB_REGISTERED_SOCK_EVENTS
651  #endif
652 
653 #endif
654 
655 
656 #ifdef SL_EXT_LIB_5
657 
658  /* General Event Registration */
659  #if __CONCAT2(SL_EXT_LIB_5, _NOTIFY_GENERAL_EVENT)
660  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_5, _GeneralEventHdl) (SlDeviceEvent_t *);
661  #define SlExtLib5GeneralEventHandler __CONCAT2(SL_EXT_LIB_5, _GeneralEventHdl)
662 
663  #undef EXT_LIB_REGISTERED_GENERAL_EVENTS
664  #define EXT_LIB_REGISTERED_GENERAL_EVENTS
665  #endif
666 
667  /* Wlan Event Registration */
668  #if __CONCAT2(SL_EXT_LIB_5, _NOTIFY_WLAN_EVENT)
669  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_5, _WlanEventHdl) (SlWlanEvent_t *);
670  #define SlExtLib5WlanEventHandler __CONCAT2(SL_EXT_LIB_5, _WlanEventHdl)
671 
672  #undef EXT_LIB_REGISTERED_WLAN_EVENTS
673  #define EXT_LIB_REGISTERED_WLAN_EVENTS
674  #endif
675 
676  /* NetApp Event Registration */
677  #if __CONCAT2(SL_EXT_LIB_5, _NOTIFY_NETAPP_EVENT)
678  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_5, _NetAppEventHdl) (SlNetAppEvent_t *);
679  #define SlExtLib5NetAppEventHandler __CONCAT2(SL_EXT_LIB_5, _NetAppEventHdl)
680 
681  #undef EXT_LIB_REGISTERED_NETAPP_EVENTS
682  #define EXT_LIB_REGISTERED_NETAPP_EVENTS
683  #endif
684 
685  /* Http Server Event Registration */
686  #if __CONCAT2(SL_EXT_LIB_5, _NOTIFY_HTTP_SERVER_EVENT)
687  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_5, _HttpServerEventHdl) (SlHttpServerEvent_t* , SlHttpServerResponse_t*);
688  #define SlExtLib5HttpServerEventHandler __CONCAT2(SL_EXT_LIB_5, _HttpServerEventHdl)
689 
690  #undef EXT_LIB_REGISTERED_HTTP_SERVER_EVENTS
691  #define EXT_LIB_REGISTERED_HTTP_SERVER_EVENTS
692  #endif
693 
694  /* Socket Event Registration */
695  #if __CONCAT2(SL_EXT_LIB_5, _NOTIFY_SOCK_EVENT)
696  extern _SlEventPropogationStatus_e __CONCAT2(SL_EXT_LIB_5, _SockEventHdl) (SlSockEvent_t *);
697  #define SlExtLib5SockEventHandler __CONCAT2(SL_EXT_LIB_5, _SockEventHdl)
698 
699  #undef EXT_LIB_REGISTERED_SOCK_EVENTS
700  #define EXT_LIB_REGISTERED_SOCK_EVENTS
701  #endif
702 
703 #endif
704 
705 
706 
707 #if defined(EXT_LIB_REGISTERED_GENERAL_EVENTS)
708 extern void _SlDrvHandleGeneralEvents(SlDeviceEvent_t *slGeneralEvent);
709 #endif
710 
711 #if defined(EXT_LIB_REGISTERED_WLAN_EVENTS)
712 extern void _SlDrvHandleWlanEvents(SlWlanEvent_t *slWlanEvent);
713 #endif
714 
715 #if defined (EXT_LIB_REGISTERED_NETAPP_EVENTS)
716 extern void _SlDrvHandleNetAppEvents(SlNetAppEvent_t *slNetAppEvent);
717 #endif
718 
719 #if defined(EXT_LIB_REGISTERED_HTTP_SERVER_EVENTS)
720 extern void _SlDrvHandleHttpServerEvents(SlHttpServerEvent_t *slHttpServerEvent, SlHttpServerResponse_t *slHttpServerResponse);
721 #endif
722 
723 
724 #if defined(EXT_LIB_REGISTERED_SOCK_EVENTS)
725 extern void _SlDrvHandleSockEvents(SlSockEvent_t *slSockEvent);
726 #endif
727 
728 
729 typedef short (*_SlSpawnEntryFunc_t)(void* pValue);
730 
731 #define SL_SPAWN_FLAG_FROM_SL_IRQ_HANDLER (0X1)
732 
733 #ifdef SL_PLATFORM_MULTI_THREADED
734  #include "../source/spawn.h"
735 #else
736  #include "../source/nonos.h"
737 #endif
738 
739 
740 
741 /* Async functions description*/
742 
776 extern void sl_GeneralEvtHdlr(SlDeviceEvent_t *pSlDeviceEvent);
777 
778 
852 #if (defined(sl_WlanEvtHdlr))
853 extern void sl_WlanEvtHdlr(SlWlanEvent_t* pSlWlanEvent);
854 #endif
855 
856 
883 #if (defined(sl_NetAppEvtHdlr))
884 extern void sl_NetAppEvtHdlr(SlNetAppEvent_t* pSlNetApp);
885 #endif
886 
905 #if (defined(sl_SockEvtHdlr))
906 extern void sl_SockEvtHdlr(SlSockEvent_t* pSlSockEvent);
907 #endif
908 
937 #if (defined(sl_HttpServerCallback))
938 extern void sl_HttpServerCallback(SlHttpServerEvent_t *pSlHttpServerEvent, SlHttpServerResponse_t *pSlHttpServerResponse);
939 #endif
940 
941 
942 
943 
953 #if defined (sl_GetTimestamp)
954 extern _u32 sl_GetTimestamp(void);
955 #endif
956 
964 #ifdef __cplusplus
965 }
966 #endif /* __cplusplus */
967 
968 #endif /* __SIMPLELINK_H__ */
969 
_u32 sl_GetTimestamp(void)
SL get timestamp routine. It returns the timer counter value in ticks unit. The counter must count fr...
void sl_GeneralEvtHdlr(SlDeviceEvent_t *pSlDeviceEvent)
General async event for inspecting general events.
void sl_HttpServerCallback(SlHttpServerEvent_t *pSlHttpServerEvent, SlHttpServerResponse_t *pSlHttpServerResponse)
HTTP server async event.
void sl_SockEvtHdlr(SlSockEvent_t *pSlSockEvent)
Socket Async event handler.
void sl_WlanEvtHdlr(SlWlanEvent_t *pSlWlanEvent)
WLAN Async event handler.
void sl_NetAppEvtHdlr(SlNetAppEvent_t *pSlNetApp)
NETAPP Async event handler.