Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
11 years, 3 months ago.
lwip raw example
Can someone provide an example for using the new ethernet interface library with NO_SYS = 1 option, i.e. "raw" lwip without rtos?
1 Answer
11 years, 3 months ago.
I have not tried with the new library, but the Server example originally published by Michael Wei, gives examples of how to use Raw API with mbed.
This relies on mbed library 26. To try with later library, you must at least change the file device.h to another name, to avoid conflict with the newer libraries.
http://mbed.org/users/RodColeman/code/LwIP_raw_API_serverExample/
I developed this example very much - for use as a fast TCP client, and it has worked reliably. (I have had no success with the HTTP client layers in the cookbook - both new and old versions are unsuitable for production, IME)
Hi Rod. I have started a project based on mbed hardware but I have not used mbed library. I need to add raw lwIP support but I need to minimize the code overhead caused when whole mbed library is include. Where can I download source of mbed library 26? I would like to get a clean and light weight compilation of you project. I would appreciate some other suggestions Best.
posted by 16 Feb 2014Hi Sergio, If you import this programme: http://mbed.org/users/RodColeman/code/LwIP_raw_API_serverExample/ you will have mbed library 26 ready to use. this may cause difficulties with maintaining the code, but it does allow you to try out the raw LwIP API. This code is very reliable, and much lighter weight than any http client or server layers.
posted by 17 Feb 2014Thanks for your answer Rod. I like that reliable part. Just a couple of questions: just for getting clearness ,Is the ethernetif implementation (lpc_phy_dp83848, lpc17_emac....) ready on mbed library 26? Where is sys_now() implemented? thanks in advance foyr help
posted by 19 Feb 2014Sergio, the ethernet i/f works very well, PHY and EMAC. I have not looked for sys_now - but you can select the project (in your compiler screen) and do and ADVANCED search for it.
posted by 19 Feb 2014