lwIP PPP - missing in WICED

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
dferbas
Level 1
Level 1
10 sign-ins 5 sign-ins First reply posted

Hi guys.

My intention is to make a WiFi board, which will replace a GPRS one, without changing our existing application a lot.  The app uses PPP to establish a connection to a mobile operator.  Did anybody test a case with PPP running on WICED?
My intention is to establish a PPP connection from remote target via Laird's EWB uart, and route with IP unnumbered (add proxyarp).

I read several lwIP threads in this forum (links below), installed WICED, successfully build snip.scan-LAIRD_EWB-FreeRTOS-LwiP-SDIO and its ThreadX variant to check, if there are any  build issues.   Awesome, both were built w/o a warning.

I added PPP from Savannah lwIP 2.0.3, even compared to 2.1.0, 2.1.1 and 2.1.2 releases, tried to redefine PBUF_POOL to PBUF_RAM, sys_jiffies() to xTaskGetTickCount() to fix build issues and played with 43xxx_Wi-Fi/WICED/network/LwIP/WWD/FreeRTOS/lwipopts.h - IP_FORWARD, PPP_SUPPORT, PPP_SERVER, etc.

Special PBUF_POOL_RX and PBUF_POOL_TX pools were created for WICED to handle wwd driver buffers.  I think PPP can have all its buffers in a local RAM.  Can I use the PBUF_RAM pool for them?

PSoC6 example with internet connectivity using GSM modem
Delta changes done in WICED lwip 2.0.3 - BTW I did not find info about changes to 2.0.3, only changes against 2.0.2
Laird Sterling Wi-Fi Performance - probably use ThreadX + NetX for better performance

Dusan

0 Likes
1 Solution
Aditi_B
Moderator
Moderator
Moderator
500 replies posted 5 questions asked 250 replies posted

Hi,

Yes, the lwIP in ModusToolbox has support for ppp. You can check whether this works out for your application and let us know if you have any queries.

Thanks

Aditi

View solution in original post

0 Likes
4 Replies
Aditi_B
Moderator
Moderator
Moderator
500 replies posted 5 questions asked 250 replies posted

Hi,

Can you specify which specific protocol in PPP are you looking for? Is it PAP, CHAP, EAP, something else?

Thanks

Aditi

0 Likes
lock attach
Attachments are accessible only for community members.

Hi Aditi,

just the PPP itself :-).
I expect to route all IP traffic, which should be delivered through UARTwith proxyarp.

If you download WICED 6.6, there are no ppp sources for lwIP.
I downloaded them from lwip-2.0.3.zip and placed them into 43xxx_Wi-Fi/WICED/network/LwIP/ver2.0.3/.

I modified the  43xxx_Wi-Fi/WICED/network/LwIP/WWD/FreeRTOS/lwipopts.h for PPP support - see lwipopts.h snippet below. I added ppp sources to .../lwIP.mk to include them in a build (all modified files are in the attached 43xxx_Wi-Fi.zip).

Now plenty of errors appear, because PBUF_POOL in lwIP was modified in WICED to PBUF_POOL_RX and PBUF_POOL_TX (see Delta changes done in WICED lwip 2.0.3, but there is no answer in the thread anyway).  I compared lwIP sources and I found a place where PBUF_POOL was replaced with PBUF_RAM. So I added following defines to the lwipopts.h, which allowed to build ppp sources.

#define PBUF_POOL PBUF_RAM
#define sys_jiffies() xTaskGetTickCount()

Now here are my questions to guys who modified lwIP for WICED: Can I do it this way?  or What was the reason for PBUF pool changes?  Was the reason to separate pools for RX and TX not to mix pool allocations between different threads? If so, am I expected to find RX and TX cases also in PPP?  or Should I use another pool separately for PPP not to mix with WiFi traffic?

lwipopts.h

/**
* PPP Support
*/
#define PPP_SUPPORT 1
#define PPPOS_SUPPORT PPP_SUPPORT
#define PAP_SUPPORT PPP_SUPPORT

#define PPP_SERVER PPP_SUPPORT
#define PPP_OUR_NAME "lwIP Example"

#define LCP_ECHOINTERVAL 10

 

0 Likes
dferbas
Level 1
Level 1
10 sign-ins 5 sign-ins First reply posted

Hi,

do you know if ppp is supported in the newer ModusToolbox™ ?

The CYW4343W hip seems to be supported as per e.g. Cypress WICED BT/BLE Host Stack solution.
But what about the ppp? Is there a same PBUF pool change in the lwIP?
Does anybody know?

0 Likes
Aditi_B
Moderator
Moderator
Moderator
500 replies posted 5 questions asked 250 replies posted

Hi,

Yes, the lwIP in ModusToolbox has support for ppp. You can check whether this works out for your application and let us know if you have any queries.

Thanks

Aditi

0 Likes