LWIP connection problem

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

LWIP connection problem

Sadegh916
Hi
I have an STM32F439 Evaluation Board. I want to connect this board to my PC
via ethernet cable. I am using LWIP TCP/IP stack.
I can send and receive data between my PC and evaluation board. But there is
a problem:
When I reset the evaluation board For Stablishing the connection, the
ethernet cable must be connected to my PC Otherwise the connection will not
be established. How can I resolve it?



--
Sent from: http://lwip.100.n7.nabble.com/lwip-users-f3.html

_______________________________________________
lwip-users mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-users
Reply | Threaded
Open this post in threaded view
|

Re: LWIP connection problem

Jan Menzel
Hi!
        What you're reporting sounds to me as if you're missing to check the
line status or if you link status check is not working properly. Usually
you've to poll the phy and react to link status changes by updating the
emac configuration and informing lwip if a link is available or not.

        Jan

On 26.08.2018 16:54, Sadegh916 wrote:

> Hi
> I have an STM32F439 Evaluation Board. I want to connect this board to my PC
> via ethernet cable. I am using LWIP TCP/IP stack.
> I can send and receive data between my PC and evaluation board. But there is
> a problem:
> When I reset the evaluation board For Stablishing the connection, the
> ethernet cable must be connected to my PC Otherwise the connection will not
> be established. How can I resolve it?
>
>
>
> --
> Sent from: http://lwip.100.n7.nabble.com/lwip-users-f3.html
>
> _______________________________________________
> lwip-users mailing list
> [hidden email]
> https://lists.nongnu.org/mailman/listinfo/lwip-users
>

_______________________________________________
lwip-users mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-users
Reply | Threaded
Open this post in threaded view
|

Re: LWIP connection problem

Jens Nielsen
Hi

Last time I checked the ST drivers this was exactly the problem, Jan is
correct. Furthermore ST only did auto negotiation in HAL_ETH_Init() and
it returns an error if the cable is not connected, I have removed that
code from my projects and manage auto negotiation myself but maybe you
can get away with simply calling HAL_ETH_Init() when the cable is
connected instead of from the netif init

//Jens

On 2018-08-27 09:58, Jan Menzel wrote:

> Hi!
> What you're reporting sounds to me as if you're missing to check the
> line status or if you link status check is not working properly. Usually
> you've to poll the phy and react to link status changes by updating the
> emac configuration and informing lwip if a link is available or not.
>
> Jan
>
> On 26.08.2018 16:54, Sadegh916 wrote:
>> Hi
>> I have an STM32F439 Evaluation Board. I want to connect this board to my PC
>> via ethernet cable. I am using LWIP TCP/IP stack.
>> I can send and receive data between my PC and evaluation board. But there is
>> a problem:
>> When I reset the evaluation board For Stablishing the connection, the
>> ethernet cable must be connected to my PC Otherwise the connection will not
>> be established. How can I resolve it?
>>
>>
>>
>> --
>> Sent from: http://lwip.100.n7.nabble.com/lwip-users-f3.html
>>
>> _______________________________________________
>> lwip-users mailing list
>> [hidden email]
>> https://lists.nongnu.org/mailman/listinfo/lwip-users
>>
> _______________________________________________
> lwip-users mailing list
> [hidden email]
> https://lists.nongnu.org/mailman/listinfo/lwip-users


_______________________________________________
lwip-users mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-users
Reply | Threaded
Open this post in threaded view
|

Re: LWIP connection problem

SKiran
In reply to this post by Sadegh916
Hi,
You might want to keep a breakpoint in ethernetif_update_config in
ethernetif.c file to check if that function is being called. If not you need
to set that callback.



--
Sent from: http://lwip.100.n7.nabble.com/lwip-users-f3.html

_______________________________________________
lwip-users mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-users