Hi, I mainly use the RAW API so I do not have any socket examples.
You should start with any working example as this is the best way. Take some example the your microprocessor vendor supplies and start from it. Once you have your ETH driver + LwIP setup and running simply take any simple Socket example and start playing with it. If you prefer the RAW API start with the echo server because it is simple and intuitive. It depends on the micro, OS etc... Do remember one thing as I learned that the hard way. If you work with FreeRTOS and you have a Cortex-M3 micro you must set interrupts priority properly. Failing to set it properly will cause strange behavior that is not easy to find. Cortex-M3 and the FreeRTOS porting have an interrupt priority that is confusing. Your OS timer tick is interrupt driven and has a priority ! You MUST set ETH driver interrupt priority to be lower than the OS. The reason is that the OS Code has blocks of critical section in it. If you set any driver or low level interrupt priority to Have an interrupt level higher than the OS time tick the critical sections will not musk the higher priority and as a result you can have loss of information and other problems. As I wrote above start with a working example from your vendor and continue from it. BR, Noam. -----Original Message----- From: lwip-users [mailto:[email protected]] On Behalf Of A480G Sent: Tuesday, July 26, 2016 9:16 AM To: [email protected] Subject: Re: [lwip-users] raw API Hi Noam, Thank you for your advise!! Perhaps can you link to me some example with sockets API, but I'm using RTOS and I need to initialize the socket in proper way. Thanks in advance BR -- View this message in context: http://lwip.100.n7.nabble.com/raw-API-tp26872p26878.html Sent from the lwip-users mailing list archive at Nabble.com. _______________________________________________ lwip-users mailing list [email protected] https://lists.nongnu.org/mailman/listinfo/lwip-users _______________________________________________ lwip-users mailing list [email protected] https://lists.nongnu.org/mailman/listinfo/lwip-users
