From FreeRTOS V4.0.3, this demo requires CrossWorks V1.6 or higher.
The example executes 12 of the standard demo application tasks, the idle task, and a task containing Adam Dunkels uIP (�IP) embedded TCP/IP stack and sample small web server.
FreeRTOS has made some modifications to the uIP stack since this demo was created. See the Embedded Ethernet Examples List page for more information.
The demo is preconfigured to execute on the LPC-E2124 embedded Ethernet development board (instructions are provided should you wish to use an alternative development board), for which the uIP TCP/IP stack port and embedded Ethernet device drivers were provided by Paul Curtis of Rowley Associates.
IMPORTANT! Notes on using the �IP demoPlease read all the following points before using this Demo.
RTOS ConfigurationThis demo uses the FreeRTOS GCC ARM7 port which is documented separately. The file Demo/uIP_Demo_Rowley_ARM7/FreeRTOSConfig.h is used to tailor the port for use with the LPC2124 development board.
Source Code Organization
main.c contains the application entry point. It is responsible for creating all the tasks, then starting the real time kernel.
Building the Demo ApplicationCrossWorks provides a user friendly interface to the GCC development tools – greatly simplifying startup configuration, linking and debugging. To build the application:
Loading and Executing the Demo ApplicationThese instructions describe how a J-Link USB JTAG debug interface can be used from within CrossWorks to program the flash and debug the application. CrossWorks also supports Wiggler (low cost) and CrossConnect JTAG interfaces. If you do not have access to one of these JTAG interfaces refer to the main GCC ARM7 port pages for information on using the free flash programming software from Philips.
Connecting to the Demo ApplicationTo connect to the embedded computer you must set a compatible IP address and use an appropriate cable.
The IP address is configured within the file FreeRTOS/Demo/uIP_Demo_Rowley_ARM7/uip/uipopt.h. This must be set to be on the same subnet as your host computer, and must not conflict with any other IP address on the same subnet.
A standard CAT5 Ethernet cable can only be used if a HUB is placed between the embedded computer and your host. A cross over (or point to point) cable is required if you want to connect directly (without a HUB).
Once correctly configured use any HTTP client (such as Internet Explorer) to make a connection by typing ‘http://nnn.nnn.nnn.nnn’ into the address bar – obviously replacing the nnn’s with the correct IP address.
Demo Application FunctionalityThe demo application creates 12 of the standard demo application tasks. These are included to demonstrate and test the RTOS kernel functionality. In addition a ‘Check’ task is created to ensure the standard demo tasks are executing correctly. Every three seconds the ‘Check’ task monitors the standard demo tasks, then toggles the yellow LED. If the yellow LED is toggling every three seconds then the ‘Check’ task has not discovered any errors. If the toggle rate increases to 500ms then an error has been discovered in at least one task.
A separate task is created to execute the uIP TCP/IP stack and web server. The uIP Ethernet driver can only poll the Ethernet interface. The LPC-E2124 8bit interface mode does not allow for interrupt operation of the CS8900 Ethernet controller. The uIP task therefore operates at a high priority, yielding processing time to the other tasks when it finds nothing to do.
To achieve this functionality a couple of small changes were required to the uIP code provided by Paul Curtis.
Execution ContextThe RTOS scheduler executes in supervisor mode, tasks execute in system mode.
NOTE! : The processor MUST be in supervisor mode when the RTOS scheduler is started (vTaskStartScheduler is called). The demo applications included in the FreeRTOS download switch to supervisor mode prior to main being called. If you are not using one of these demo application projects then ensure Supervisor mode is entered before calling vTaskStartScheduler().
See the LPC2000 GCC documentation for a lot more
information on the RTOS scheduler setup and usage.
LicensingPlease note that the uIP stack is licensed separately to FreeRTOS. Users must familiarise themselves with the license conditions.
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.
Watch for updates in the coming months as we add new IoT-related functionality and improved website navigation and resources
View a recording of the “OTA Update Security and Reliability” webinar, presented by TI and AWS.
FreeRTOS and other embedded software careers at AWS.