Topic: Freertos stm32f439

Hi i am struggling with some configurations issues.

I am using the STM32CcubeMx and like to have an Freertos, lwip and wolfssl as my setup. I basically left all in it's default. Tried a client connection but failed. It's hard to figure out the correct setting in multiple header files and here to set callbacks.

My debug error

Your IO Send callback is null, please set
wolfSSL Leaving SendClientHello, return -308
wolfSSL error occurred, error = -308
wolfSSL Leaving wolfSSL_negotiate, return -1
wolfSSL Leaving wolfSSL_write, return -1

Share

Re: Freertos stm32f439

Hi MO380,

Your build options likely have WOLFSSL_USER_IO set, which requires you setup your own callbacks using wolfSSL_CTX_SetIOSend and wolfSSL_SSLSetIORecv.

Try removing WOLFSSL_USER_IO and adding WOLFSSL_LWIP_NATIVE. Or if you have the LWIP POSIX layer enabled, you can just use our default POSIX ones by not defining WOLFSSL_LWIP_NATIVE.

Thanks,
David Garske, wolfSSL

Share

Re: Freertos stm32f439

That was fast.

I tried it by defining WOLFSSL_LWIP_NATIVE, but i got the next problem.

Now

EMS extension to write
Assertion "tcp_write: invalid pcb" failed at line 414 in ../Middlewares/Third_Party/LwIP/src/core/tcp_out.c
wolfSSL Leaving SendClientHello, return -308

pcb is NULL

Share

Re: Freertos stm32f439

Hi MO380,

Was your LWIP already working previously? That appears to be an internal LWIP issue. Have you properly configured LWIP NATIVE?

Have you tried without WOLFSSL_LWIP_NATIVE defined, which uses the LWIP POSIX interfaces (connect/send/recv/close).

Thanks,
David Garske, wolfSSL

Share