Ethernet test for ECE 4180 and others to find your IP address and do a simple HTTP GET request over port 80.
Dependencies: mbed Socket lwip-eth lwip-sys lwip
mbed-rtos/rtx/RTX_Config.h@0:e7ca326e76ee, 2013-04-04 (annotated)
- Committer:
- mkersh3
- Date:
- Thu Apr 04 05:26:09 2013 +0000
- Revision:
- 0:e7ca326e76ee
Ethernet Test for ECE4180 and others to find their IP Address and do a simple HTTP GET request over port 80.
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
mkersh3 | 0:e7ca326e76ee | 1 | /*---------------------------------------------------------------------------- |
mkersh3 | 0:e7ca326e76ee | 2 | * RL-ARM - RTX |
mkersh3 | 0:e7ca326e76ee | 3 | *---------------------------------------------------------------------------- |
mkersh3 | 0:e7ca326e76ee | 4 | * Name: RTX_CONFIG.H |
mkersh3 | 0:e7ca326e76ee | 5 | * Purpose: Exported functions of RTX_Config.c |
mkersh3 | 0:e7ca326e76ee | 6 | * Rev.: V4.50 |
mkersh3 | 0:e7ca326e76ee | 7 | *---------------------------------------------------------------------------- |
mkersh3 | 0:e7ca326e76ee | 8 | * |
mkersh3 | 0:e7ca326e76ee | 9 | * Copyright (c) 1999-2009 KEIL, 2009-2012 ARM Germany GmbH |
mkersh3 | 0:e7ca326e76ee | 10 | * All rights reserved. |
mkersh3 | 0:e7ca326e76ee | 11 | * Redistribution and use in source and binary forms, with or without |
mkersh3 | 0:e7ca326e76ee | 12 | * modification, are permitted provided that the following conditions are met: |
mkersh3 | 0:e7ca326e76ee | 13 | * - Redistributions of source code must retain the above copyright |
mkersh3 | 0:e7ca326e76ee | 14 | * notice, this list of conditions and the following disclaimer. |
mkersh3 | 0:e7ca326e76ee | 15 | * - Redistributions in binary form must reproduce the above copyright |
mkersh3 | 0:e7ca326e76ee | 16 | * notice, this list of conditions and the following disclaimer in the |
mkersh3 | 0:e7ca326e76ee | 17 | * documentation and/or other materials provided with the distribution. |
mkersh3 | 0:e7ca326e76ee | 18 | * - Neither the name of ARM nor the names of its contributors may be used |
mkersh3 | 0:e7ca326e76ee | 19 | * to endorse or promote products derived from this software without |
mkersh3 | 0:e7ca326e76ee | 20 | * specific prior written permission. |
mkersh3 | 0:e7ca326e76ee | 21 | * |
mkersh3 | 0:e7ca326e76ee | 22 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
mkersh3 | 0:e7ca326e76ee | 23 | * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
mkersh3 | 0:e7ca326e76ee | 24 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE |
mkersh3 | 0:e7ca326e76ee | 25 | * ARE DISCLAIMED. IN NO EVENT SHALL COPYRIGHT HOLDERS AND CONTRIBUTORS BE |
mkersh3 | 0:e7ca326e76ee | 26 | * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR |
mkersh3 | 0:e7ca326e76ee | 27 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF |
mkersh3 | 0:e7ca326e76ee | 28 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS |
mkersh3 | 0:e7ca326e76ee | 29 | * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN |
mkersh3 | 0:e7ca326e76ee | 30 | * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) |
mkersh3 | 0:e7ca326e76ee | 31 | * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE |
mkersh3 | 0:e7ca326e76ee | 32 | * POSSIBILITY OF SUCH DAMAGE. |
mkersh3 | 0:e7ca326e76ee | 33 | *---------------------------------------------------------------------------*/ |
mkersh3 | 0:e7ca326e76ee | 34 | |
mkersh3 | 0:e7ca326e76ee | 35 | // #define THREAD_STACK_DIAGNOSTIC 1 |
mkersh3 | 0:e7ca326e76ee | 36 | |
mkersh3 | 0:e7ca326e76ee | 37 | /* Error Codes */ |
mkersh3 | 0:e7ca326e76ee | 38 | #define OS_ERR_STK_OVF 1 |
mkersh3 | 0:e7ca326e76ee | 39 | #define OS_ERR_FIFO_OVF 2 |
mkersh3 | 0:e7ca326e76ee | 40 | #define OS_ERR_MBX_OVF 3 |
mkersh3 | 0:e7ca326e76ee | 41 | |
mkersh3 | 0:e7ca326e76ee | 42 | /* Definitions */ |
mkersh3 | 0:e7ca326e76ee | 43 | #define BOX_ALIGN_8 0x80000000 |
mkersh3 | 0:e7ca326e76ee | 44 | #define _declare_box(pool,size,cnt) U32 pool[(((size)+3)/4)*(cnt) + 3] |
mkersh3 | 0:e7ca326e76ee | 45 | #define _declare_box8(pool,size,cnt) U64 pool[(((size)+7)/8)*(cnt) + 2] |
mkersh3 | 0:e7ca326e76ee | 46 | #define _init_box8(pool,size,bsize) _init_box (pool,size,(bsize) | BOX_ALIGN_8) |
mkersh3 | 0:e7ca326e76ee | 47 | |
mkersh3 | 0:e7ca326e76ee | 48 | /* Variables */ |
mkersh3 | 0:e7ca326e76ee | 49 | extern U32 idle_task_stack[]; |
mkersh3 | 0:e7ca326e76ee | 50 | extern U32 os_fifo[]; |
mkersh3 | 0:e7ca326e76ee | 51 | extern void *os_active_TCB[]; |
mkersh3 | 0:e7ca326e76ee | 52 | |
mkersh3 | 0:e7ca326e76ee | 53 | /* Constants */ |
mkersh3 | 0:e7ca326e76ee | 54 | extern U16 const os_maxtaskrun; |
mkersh3 | 0:e7ca326e76ee | 55 | extern U32 const os_trv; |
mkersh3 | 0:e7ca326e76ee | 56 | extern U8 const os_flags; |
mkersh3 | 0:e7ca326e76ee | 57 | extern U32 const os_rrobin; |
mkersh3 | 0:e7ca326e76ee | 58 | extern U32 const os_clockrate; |
mkersh3 | 0:e7ca326e76ee | 59 | extern U32 const os_timernum; |
mkersh3 | 0:e7ca326e76ee | 60 | extern U16 const idle_task_stack_size; |
mkersh3 | 0:e7ca326e76ee | 61 | |
mkersh3 | 0:e7ca326e76ee | 62 | extern U8 const os_fifo_size; |
mkersh3 | 0:e7ca326e76ee | 63 | |
mkersh3 | 0:e7ca326e76ee | 64 | /* Functions */ |
mkersh3 | 0:e7ca326e76ee | 65 | extern void os_idle_demon (void); |
mkersh3 | 0:e7ca326e76ee | 66 | extern int os_tick_init (void); |
mkersh3 | 0:e7ca326e76ee | 67 | extern void os_tick_irqack (void); |
mkersh3 | 0:e7ca326e76ee | 68 | extern void os_tmr_call (U16 info); |
mkersh3 | 0:e7ca326e76ee | 69 | extern void os_error (U32 err_code); |