version_2.0
Dependents: cc3000_ping_demo_try_2
Fork of cc3000_hostdriver_mbedsocket by
cc3000_netapp.h@20:30b6ed7bf8fd, 2013-10-03 (annotated)
- Committer:
- Kojto
- Date:
- Thu Oct 03 17:15:45 2013 +0200
- Revision:
- 20:30b6ed7bf8fd
- Parent:
- 0:615c697c33b0
UNIX line endings
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
Kojto | 20:30b6ed7bf8fd | 1 | /***************************************************************************** |
Kojto | 20:30b6ed7bf8fd | 2 | * |
Kojto | 20:30b6ed7bf8fd | 3 | * C++ interface/implementation created by Martin Kojtal (0xc0170). Thanks to |
Kojto | 20:30b6ed7bf8fd | 4 | * Jim Carver and Frank Vannieuwkerke for their inital cc3000 mbed port and |
Kojto | 20:30b6ed7bf8fd | 5 | * provided help. |
Kojto | 20:30b6ed7bf8fd | 6 | * |
Kojto | 20:30b6ed7bf8fd | 7 | * This version of "host driver" uses CC3000 Host Driver Implementation. Thus |
Kojto | 20:30b6ed7bf8fd | 8 | * read the following copyright: |
Kojto | 20:30b6ed7bf8fd | 9 | * |
Kojto | 20:30b6ed7bf8fd | 10 | * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/ |
Kojto | 20:30b6ed7bf8fd | 11 | * |
Kojto | 20:30b6ed7bf8fd | 12 | * Redistribution and use in source and binary forms, with or without |
Kojto | 20:30b6ed7bf8fd | 13 | * modification, are permitted provided that the following conditions |
Kojto | 20:30b6ed7bf8fd | 14 | * are met: |
Kojto | 20:30b6ed7bf8fd | 15 | * |
Kojto | 20:30b6ed7bf8fd | 16 | * Redistributions of source code must retain the above copyright |
Kojto | 20:30b6ed7bf8fd | 17 | * notice, this list of conditions and the following disclaimer. |
Kojto | 20:30b6ed7bf8fd | 18 | * |
Kojto | 20:30b6ed7bf8fd | 19 | * Redistributions in binary form must reproduce the above copyright |
Kojto | 20:30b6ed7bf8fd | 20 | * notice, this list of conditions and the following disclaimer in the |
Kojto | 20:30b6ed7bf8fd | 21 | * documentation and/or other materials provided with the |
Kojto | 20:30b6ed7bf8fd | 22 | * distribution. |
Kojto | 20:30b6ed7bf8fd | 23 | * |
Kojto | 20:30b6ed7bf8fd | 24 | * Neither the name of Texas Instruments Incorporated nor the names of |
Kojto | 20:30b6ed7bf8fd | 25 | * its contributors may be used to endorse or promote products derived |
Kojto | 20:30b6ed7bf8fd | 26 | * from this software without specific prior written permission. |
Kojto | 20:30b6ed7bf8fd | 27 | * |
Kojto | 20:30b6ed7bf8fd | 28 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS |
Kojto | 20:30b6ed7bf8fd | 29 | * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT |
Kojto | 20:30b6ed7bf8fd | 30 | * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR |
Kojto | 20:30b6ed7bf8fd | 31 | * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT |
Kojto | 20:30b6ed7bf8fd | 32 | * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
Kojto | 20:30b6ed7bf8fd | 33 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT |
Kojto | 20:30b6ed7bf8fd | 34 | * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |
Kojto | 20:30b6ed7bf8fd | 35 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
Kojto | 20:30b6ed7bf8fd | 36 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
Kojto | 20:30b6ed7bf8fd | 37 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
Kojto | 20:30b6ed7bf8fd | 38 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
Kojto | 20:30b6ed7bf8fd | 39 | * |
Kojto | 20:30b6ed7bf8fd | 40 | *****************************************************************************/ |
Kojto | 20:30b6ed7bf8fd | 41 | #ifndef CC3000_NETAPP_H |
Kojto | 20:30b6ed7bf8fd | 42 | #define CC3000_NETAPP_H |
Kojto | 20:30b6ed7bf8fd | 43 | |
Kojto | 20:30b6ed7bf8fd | 44 | #define MIN_TIMER_VAL_SECONDS 20 |
Kojto | 20:30b6ed7bf8fd | 45 | #define MIN_TIMER_SET(t) if ((0 != t) && (t < MIN_TIMER_VAL_SECONDS)) \ |
Kojto | 20:30b6ed7bf8fd | 46 | { \ |
Kojto | 20:30b6ed7bf8fd | 47 | t = MIN_TIMER_VAL_SECONDS; \ |
Kojto | 20:30b6ed7bf8fd | 48 | } |
Kojto | 20:30b6ed7bf8fd | 49 | |
Kojto | 20:30b6ed7bf8fd | 50 | |
Kojto | 20:30b6ed7bf8fd | 51 | #define NETAPP_DHCP_PARAMS_LEN (20) |
Kojto | 20:30b6ed7bf8fd | 52 | #define NETAPP_SET_TIMER_PARAMS_LEN (20) |
Kojto | 20:30b6ed7bf8fd | 53 | #define NETAPP_SET_DEBUG_LEVEL_PARAMS_LEN (4) |
Kojto | 20:30b6ed7bf8fd | 54 | #define NETAPP_PING_SEND_PARAMS_LEN (16) |
Kojto | 20:30b6ed7bf8fd | 55 | |
Kojto | 20:30b6ed7bf8fd | 56 | |
Kojto | 20:30b6ed7bf8fd | 57 | typedef struct _netapp_dhcp_ret_args_t |
Kojto | 20:30b6ed7bf8fd | 58 | { |
Kojto | 20:30b6ed7bf8fd | 59 | uint8_t aucIP[4]; |
Kojto | 20:30b6ed7bf8fd | 60 | uint8_t aucSubnetMask[4]; |
Kojto | 20:30b6ed7bf8fd | 61 | uint8_t aucDefaultGateway[4]; |
Kojto | 20:30b6ed7bf8fd | 62 | uint8_t aucDHCPServer[4]; |
Kojto | 20:30b6ed7bf8fd | 63 | uint8_t aucDNSServer[4]; |
Kojto | 20:30b6ed7bf8fd | 64 | }tNetappDhcpParams; |
Kojto | 20:30b6ed7bf8fd | 65 | |
Kojto | 20:30b6ed7bf8fd | 66 | typedef struct _netapp_ipconfig_ret_args_t |
Kojto | 20:30b6ed7bf8fd | 67 | { |
Kojto | 20:30b6ed7bf8fd | 68 | uint8_t aucIP[4]; |
Kojto | 20:30b6ed7bf8fd | 69 | uint8_t aucSubnetMask[4]; |
Kojto | 20:30b6ed7bf8fd | 70 | uint8_t aucDefaultGateway[4]; |
Kojto | 20:30b6ed7bf8fd | 71 | uint8_t aucDHCPServer[4]; |
Kojto | 20:30b6ed7bf8fd | 72 | uint8_t aucDNSServer[4]; |
Kojto | 20:30b6ed7bf8fd | 73 | uint8_t uaMacAddr[6]; |
Kojto | 20:30b6ed7bf8fd | 74 | uint8_t uaSSID[32]; |
Kojto | 20:30b6ed7bf8fd | 75 | }tNetappIpconfigRetArgs; |
Kojto | 20:30b6ed7bf8fd | 76 | |
Kojto | 20:30b6ed7bf8fd | 77 | |
Kojto | 20:30b6ed7bf8fd | 78 | /*Ping send report parameters*/ |
Kojto | 20:30b6ed7bf8fd | 79 | typedef struct _netapp_pingreport_args |
Kojto | 20:30b6ed7bf8fd | 80 | { |
Kojto | 20:30b6ed7bf8fd | 81 | uint32_t packets_sent; |
Kojto | 20:30b6ed7bf8fd | 82 | uint32_t packets_received; |
Kojto | 20:30b6ed7bf8fd | 83 | uint32_t min_round_time; |
Kojto | 20:30b6ed7bf8fd | 84 | uint32_t max_round_time; |
Kojto | 20:30b6ed7bf8fd | 85 | uint32_t avg_round_time; |
Kojto | 20:30b6ed7bf8fd | 86 | } netapp_pingreport_args_t; |
Kojto | 20:30b6ed7bf8fd | 87 | |
Kojto | 20:30b6ed7bf8fd | 88 | #endif |