Re: [lwip-users] Network Loss causes network to go down

2020-04-01 Thread Yacob Hassidim
Hello all,

My project environment is:
- Controller:  STM32F439BGT6
- Ethernet  PHY chip: LAN8742A (from Microchip)
- OS: FreeRTOS
- TCP/IP stack: LwIP Version 2.0.3

My project also requires to identify Link (network) disconnection.

I used HAL_ETH_ReadPHYRegister (, PHY_BSR, ) to identify the 
status of the link.

The definition PHY_LINKED_STATUS masks the bit of link status.

I read the PHY register twice to ensure the link is down.

I changed the function ethernetif_set_link() in the file: ethernetif.c for 
reading twice the PHY register.

The link disconnection is identified successfully. 

Sincerely,

Yacob Hassidim,
Real Time Embedded Software Engineer

-Original Message-
From: lwip-users  On 
Behalf Of Jan Menzel
Sent: Thursday, April 2, 2020 1:17 AM
To: lwip-users@nongnu.org
Subject: Re: [lwip-users] Network Loss causes network to go down

Hi Dan!
Its a fundamental thing with TCP and UDP that there is not way to know, 
that the link is valid but the other side just did not had anything to say 
unless you added it to your protocol. Using cable detection in the phy might 
help, but only a little bit as most devices talk to other devices that are 
multiple hops away and any problem between the first hop and the remote side 
are not covered then.
I once had a project where a LWIP driven device had to send small 
amount of data ever few minutes to a remote server that was located on the 
other side of the world. This devices had nobody to maintain it like watching 
for status leds or pressing a reset knob.
We finally solved the issue using multiple points:
- enabled timeouts for receive and transmit to never block. Thats what we 
observed first: the transmit loop was blocked due to to many unacked data.
- use some watchdog/ping command in the protocol to detect if the connection to 
the remote side is still valid/active. Thats the only way to be sure, the 
remote side is still reachable.
The F427 has lots of RAM. You might provide more storage to allow more 
then one connection.

Jan

On 01.04.2020 00:45, Bomsta, Dan wrote:
> Thanks Trampas!  You went down the same road I started on with the 
> ability to detect the disconnection.  I was told we cannot change the 
> hardware, so I am trying to find the correct location in Lwip to 
> “clean up” when there is no route.  Just haven’t found it yet.
> 
>  
> 
> The correct solution in using the carrier sense pin.
> 
>  
> 
> Thanks again,
> 
> Dan
> 
>  
> 
> *From:*lwip-users
>  *On Behalf Of 
> *Trampas Stern
> *Sent:* Tuesday, March 31, 2020 5:11 PM
> *To:* Mailing list for lwIP users 
> *Subject:* Re: [lwip-users] Network Loss causes network to go down
> 
>  
> 
> Dan,
> 
>  
> 
> I had been using a RMII phy and noticed similar issues.  Specifically 
> I could not detect cable connected or disconnected using the RMII, the 
> link activity bit does not work for cable connected/disconnected.  I 
> was shocked to find that RMII did not provide this functionality.  
> Sure the LED blink but no bits in the RMII register map changes when 
> cable is inserted or not.
> 
>  
> 
> We had problems where it timeouts in setting up the netif/lwip  were 
> causing watch dog time outs if cable was unplugged on boot. Then when 
> cable was removed and reinserted (not a normal case for our device) we 
> were having similar issues as you.  We could not find a way to know if 
> the cable was connected or not, except by redesigning hardware.  So we 
> are redesigning hardware to use hardware cable connection detection 
> using PHY carrier sense pin.   The plan was try and shutdown lwip and 
> restart netif and lwip when cable was plugged back in.
> 
>  
> 
> Trampas
> 
>  
> 
>  
> 
> On Tue, Mar 31, 2020 at 5:51 PM Bomsta, Dan  <mailto:dan.bom...@sageglass.com>> wrote:
> 
> I have am working  on an issue with our device.  First here are the
> particulars
> 
> Micro:  STM32F427
> 
> LwIP: 2.0.3
> 
> WolfSSL: 3.15.3
> 
> Microchip managed switch KSZ8863RLLI.
> 
>  
> 
> If one removes the Ethernet cable from our device (typically during
> heavy traffic) the network is not usable for many minutes upon
> reconnecting the Ethernet cable.  I have been printing WolfSSL debug
> messages and Lwip debug messages without solving the issue yet.
> 
>  
> 
> No, we do not have the ability to “hardware” determine when the
> cable is unplugged.  Our system has these devices “daisy chained” so
> one would need to ping to determine if the network is available. 
> The last good trace I got is this (then my laptop crashed)
> 
>  
> 
> ip4_route: No route to 172.20.0.14
> 
> data=0x0
> 
> 

Re: [lwip-users] TCP Receive Timeout

2020-01-12 Thread Yacob Hassidim
Hello,

Thanks Simon,

Do you mean I must to enable LWIP_TCPIP_TIMEOUT and LWIP_SO_RCVTIMEO to enable 
TCP receive timeout?

Can you please answer to the next question also?

The timeout value shall be set by the function netconn_set_recvtimeout().
Can I use netconn_set_recvtimeout() at any time or it must be at system startup?

Yacob Hassidim,
Real Time Embedded Software Engineer

-Original Message-
From: lwip-users  On 
Behalf Of goldsi...@gmx.de
Sent: Saturday, January 11, 2020 12:28 AM
To: Mailing list for lwIP users 
Subject: Re: [lwip-users] TCP Receive Timeout

Am 19.12.2019 um 06:44 schrieb Yacob Hassidim:
> Hello all,
>
> I use LwIP version 2.0.3.
>
> I want to define timeout for TCP receive.
>
> LwIP allows to define the following options:
>
> - LWIP_TCPIP_TIMEOUT

Have you found out by now that LWIP_TCPIP_TIMEOUT has nothing to do with 
receive timeouts?

When using sockets, just try to use standard calls and come back here for 
anything that doesn't work compared to Unix/Linux/windows.

Regards,
Simon

>
> - LWIP_SO_RCVTIMEO
>
> Which of them shall be enabled for receive timeout?
>
> The timeout value shall be set by the function netconn_set_recvtimeout().
>
> Can I use netconn_set_recvtimeout() at any time or it must be at 
> system startup?
>
> Thanks.
>
> Yacob Hassidim.
>
>
> ___
> lwip-users mailing list
> lwip-users@nongnu.org
> https://lists.nongnu.org/mailman/listinfo/lwip-users
>


___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users


___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

Re: [lwip-users] TCP Receive Timeout

2019-12-25 Thread Yacob Hassidim
Hello,

 

Thank you for your fast response.

 

I understand LWIP_TCPIP_TIMEOUT is required to create timers (so it must be 
enabled) and LWIP_SO_RCVTIMEO is for Receive Timeout.

 

Yacob Hassidim.

 

From: lwip-users  On 
Behalf Of Mesut Cömert
Sent: Thursday, December 26, 2019 9:32 AM
To: Mailing list for lwIP users 
Subject: Re: [lwip-users] TCP Receive Timeout

 

Hello, I've using as set LWIP_TCPIP_TIMEOUT to 1 too. Also, 
netconn_set_recvtimeout is a define line for sign to "conn->recv_timeout".

 

Yacob Hassidim mailto:yac...@dds-security.com> >, 26 
Ara 2019 Per, 10:15 tarihinde şunu yazdı:

Hello,

 

Thank you.

 

Do you mean LWIP_TCPIP_TIMEOUT is not required?

 

Can I set “conName->recv_timeout” at any time?

 

Yacob Hassidim.

 

From: lwip-users mailto:dds-security@nongnu.org> > On Behalf Of Mesut Cömert
Sent: Thursday, December 26, 2019 9:09 AM
To: Mailing list for lwIP users mailto:lwip-users@nongnu.org> >
Subject: Re: [lwip-users] TCP Receive Timeout

 

Hello,

 

If you set "LWIP_SO_RCVTIMEO" option to 1, "->recv_timeout" will be enable.

 

Regards

 

Yacob Hassidim mailto:yac...@dds-security.com> >, 26 
Ara 2019 Per, 09:58 tarihinde şunu yazdı:

Hello,

 

Thanks for your answer.

 

But what about the first question:

LwIP allows to define the following options:

- LWIP_TCPIP_TIMEOUT

- LWIP_SO_RCVTIMEO

 

Which of them shall be enabled for receive timeout?

 

Yacob Hassidim.

 

From: lwip-users mailto:dds-security@nongnu.org> > On Behalf Of Mesut Cömert
Sent: Thursday, December 26, 2019 8:49 AM
To: Mailing list for lwIP users mailto:lwip-users@nongnu.org> >
Subject: Re: [lwip-users] TCP Receive Timeout

 

Hello,

 

I think you can use netconn_set_recvtimeout() function. But I've prefering 
"conName->recv_timeout" method.

 

Yacob Hassidim mailto:yac...@dds-security.com> >, 26 
Ara 2019 Per, 09:42 tarihinde şunu yazdı:

Hello all,

 

This is the 3rd time I send this question.

Can anyone help?

 

I use LwIP version 2.0.3.

 

I want to define timeout for TCP receive.

 

LwIP allows to define the following options:

- LWIP_TCPIP_TIMEOUT

- LWIP_SO_RCVTIMEO

 

Which of them shall be enabled for receive timeout?

 

The timeout value shall be set by the function netconn_set_recvtimeout().

Can I use netconn_set_recvtimeout() at any time or it must be at system startup?

 

Thanks.

 

Yacob Hassidim.

 

___
lwip-users mailing list
lwip-users@nongnu.org <mailto:lwip-users@nongnu.org> 
https://lists.nongnu.org/mailman/listinfo/lwip-users




 

-- 

Mesut Cömert

Elektrik Elektronik Mühendisi | Electrical Electronics Engineer

___
lwip-users mailing list
lwip-users@nongnu.org <mailto:lwip-users@nongnu.org> 
https://lists.nongnu.org/mailman/listinfo/lwip-users




 

-- 

Mesut Cömert

Elektrik Elektronik Mühendisi | Electrical Electronics Engineer

___
lwip-users mailing list
lwip-users@nongnu.org <mailto:lwip-users@nongnu.org> 
https://lists.nongnu.org/mailman/listinfo/lwip-users




 

-- 

Mesut Cömert

Elektrik Elektronik Mühendisi | Electrical Electronics Engineer

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

Re: [lwip-users] TCP Receive Timeout

2019-12-25 Thread Yacob Hassidim
Hello,

 

Thank you.

 

Do you mean LWIP_TCPIP_TIMEOUT is not required?

 

Can I set “conName->recv_timeout” at any time?

 

Yacob Hassidim.

 

From: lwip-users  On 
Behalf Of Mesut Cömert
Sent: Thursday, December 26, 2019 9:09 AM
To: Mailing list for lwIP users 
Subject: Re: [lwip-users] TCP Receive Timeout

 

Hello,

 

If you set "LWIP_SO_RCVTIMEO" option to 1, "->recv_timeout" will be enable.

 

Regards

 

Yacob Hassidim mailto:yac...@dds-security.com> >, 26 
Ara 2019 Per, 09:58 tarihinde şunu yazdı:

Hello,

 

Thanks for your answer.

 

But what about the first question:

LwIP allows to define the following options:

- LWIP_TCPIP_TIMEOUT

- LWIP_SO_RCVTIMEO

 

Which of them shall be enabled for receive timeout?

 

Yacob Hassidim.

 

From: lwip-users mailto:dds-security@nongnu.org> > On Behalf Of Mesut Cömert
Sent: Thursday, December 26, 2019 8:49 AM
To: Mailing list for lwIP users mailto:lwip-users@nongnu.org> >
Subject: Re: [lwip-users] TCP Receive Timeout

 

Hello,

 

I think you can use netconn_set_recvtimeout() function. But I've prefering 
"conName->recv_timeout" method.

 

Yacob Hassidim mailto:yac...@dds-security.com> >, 26 
Ara 2019 Per, 09:42 tarihinde şunu yazdı:

Hello all,

 

This is the 3rd time I send this question.

Can anyone help?

 

I use LwIP version 2.0.3.

 

I want to define timeout for TCP receive.

 

LwIP allows to define the following options:

- LWIP_TCPIP_TIMEOUT

- LWIP_SO_RCVTIMEO

 

Which of them shall be enabled for receive timeout?

 

The timeout value shall be set by the function netconn_set_recvtimeout().

Can I use netconn_set_recvtimeout() at any time or it must be at system startup?

 

Thanks.

 

Yacob Hassidim.

 

___
lwip-users mailing list
lwip-users@nongnu.org <mailto:lwip-users@nongnu.org> 
https://lists.nongnu.org/mailman/listinfo/lwip-users




 

-- 

Mesut Cömert

Elektrik Elektronik Mühendisi | Electrical Electronics Engineer

___
lwip-users mailing list
lwip-users@nongnu.org <mailto:lwip-users@nongnu.org> 
https://lists.nongnu.org/mailman/listinfo/lwip-users




 

-- 

Mesut Cömert

Elektrik Elektronik Mühendisi | Electrical Electronics Engineer

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

Re: [lwip-users] TCP Receive Timeout

2019-12-25 Thread Yacob Hassidim
Hello,

 

Thanks for your answer.

 

But what about the first question:

LwIP allows to define the following options:

- LWIP_TCPIP_TIMEOUT

- LWIP_SO_RCVTIMEO

 

Which of them shall be enabled for receive timeout?

 

Yacob Hassidim.

 

From: lwip-users  On 
Behalf Of Mesut Cömert
Sent: Thursday, December 26, 2019 8:49 AM
To: Mailing list for lwIP users 
Subject: Re: [lwip-users] TCP Receive Timeout

 

Hello,

 

I think you can use netconn_set_recvtimeout() function. But I've prefering 
"conName->recv_timeout" method.

 

Yacob Hassidim mailto:yac...@dds-security.com> >, 26 
Ara 2019 Per, 09:42 tarihinde şunu yazdı:

Hello all,

 

This is the 3rd time I send this question.

Can anyone help?

 

I use LwIP version 2.0.3.

 

I want to define timeout for TCP receive.

 

LwIP allows to define the following options:

- LWIP_TCPIP_TIMEOUT

- LWIP_SO_RCVTIMEO

 

Which of them shall be enabled for receive timeout?

 

The timeout value shall be set by the function netconn_set_recvtimeout().

Can I use netconn_set_recvtimeout() at any time or it must be at system startup?

 

Thanks.

 

Yacob Hassidim.

 

___
lwip-users mailing list
lwip-users@nongnu.org <mailto:lwip-users@nongnu.org> 
https://lists.nongnu.org/mailman/listinfo/lwip-users




 

-- 

Mesut Cömert

Elektrik Elektronik Mühendisi | Electrical Electronics Engineer

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

[lwip-users] TCP Receive Timeout

2019-12-25 Thread Yacob Hassidim
Hello all,

 

This is the 3rd time I send this question.

Can anyone help?

 

I use LwIP version 2.0.3.

 

I want to define timeout for TCP receive.

 

LwIP allows to define the following options:

- LWIP_TCPIP_TIMEOUT

- LWIP_SO_RCVTIMEO

 

Which of them shall be enabled for receive timeout?

 

The timeout value shall be set by the function netconn_set_recvtimeout().

Can I use netconn_set_recvtimeout() at any time or it must be at system
startup?

 

Thanks.

 

Yacob Hassidim.

 

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

[lwip-users] TCP Receive Timeout

2019-12-18 Thread Yacob Hassidim
Hello all,

 

I use LwIP version 2.0.3.

 

I want to define timeout for TCP receive.

 

LwIP allows to define the following options:

- LWIP_TCPIP_TIMEOUT

- LWIP_SO_RCVTIMEO

 

Which of them shall be enabled for receive timeout?

 

The timeout value shall be set by the function netconn_set_recvtimeout().

Can I use netconn_set_recvtimeout() at any time or it must be at system
startup?

 

Thanks.

 

Yacob Hassidim.

 

 

 

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

[lwip-users] TCP Receive Timeout

2019-12-15 Thread Yacob Hassidim
Hello all,

 

I use LwIP version 2.0.3.

 

I want to define timeout for TCP receive.

 

LwIP allows to define the following options:

- LWIP_TCPIP_TIMEOUT

- LWIP_SO_RCVTIMEO

 

Which of them shall be enabled for receive timeout?

 

The timeout value shall be set by the function netconn_set_recvtimeout().

Can I use netconn_set_recvtimeout() at any time or it must be at system
startup?

 

Thanks.

 

Yacob Hassidim.

 

 

 

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

Re: [lwip-users] lwip netconn with ethernet disconnect

2018-11-08 Thread Yacob Hassidim
Hello all,

I check also the connection state reported by the PHY but don't re-init
LWIP.

I call netif_set_link_up() or netif_set_link_down() in accordance with:
a) the connection state reported by PHY 
b) the state of netif that reported by netif_is_link_up()

Yacob Hassidim

-Original Message-
From: lwip-users  On
Behalf Of Hugh Reynolds
Sent: Thursday, November 8, 2018 11:28 AM
To: 'Mailing list for lwIP users' 
Cc: j...@enginelab.net
Subject: Re: [lwip-users] lwip netconn with ethernet disconnect

Jim,

In my application each time I call LWIP I check the connection state
reported by the PHY.
I have a state machine that handles cable up/down.
If it is down, when it comes back I re-init LWIP and anything that has been
hanging on the line.

That works...every time...is there a better way?

Regards

Hugh

-Original Message-
From: lwip-users  On
Behalf Of jim
Sent: 08 November 2018 01:46
To: lwip-users@nongnu.org
Cc: 
Subject: [lwip-users] lwip netconn with ethernet disconnect

Hi,

I have the lwip system working and it is awesome!

I am wondering how to recover from cable disconnect in my application. 
On cable disconnect, the driver calls tcpip_callback_with_block which ends
up successfully entering netif_set_link_down.

My application is currently waiting on the receive mailbox through
netconn_recv.

What is the expected behavior when the cable is removed? I would have
expected the blocking  netconn_recv to return with an error.

Thanks in advance for any help.
Jim



___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users


---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus


___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users


___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users


Re: [lwip-users] confirm 0c357...

2018-04-08 Thread Yacob Hassidim
Hello all,

 

I also received such a message and my membership was disabled and I enabled it.

 

Yacob Hassidim.

 

From: lwip-users <lwip-users-bounces+yacobh=dds-security@nongnu.org> On 
Behalf Of Dott. Ing. Bettega Stefano
Sent: Sunday, April 8, 2018 10:26 PM
To: Mailing list for lwIP users <lwip-users@nongnu.org>
Subject: Re: [lwip-users] confirm 0c357...

 

If I well remember I also received such an email a couple of years ago.
It could be an issue with you provider censoring emails from mailing lists. I 
think I logged on and changed my address with a different one (i.e. my private 
home address with my work address), but I'm not really sure: will check 
tomorrow at work and report you back.

Cheers,
Stefano



Il 8 aprile 2018 20:32:19 CEST, 123markus321 <123markus...@gmail.com 
<mailto:123markus...@gmail.com> > ha scritto:

i never received such message. it means that your email was unreachable. it is 
easy to manipulate the sender's address but the message also contains sensitive 
information ( your password). I think it's no phishing


-- 
Inviato dal mio dispositivo Android con K-9 Mail. Perdonate la brevità.

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

Re: [lwip-users] Support of two Ethernet connections

2018-03-08 Thread Yacob Hassidim
Hello Simeon,

 

Thanks for your fast response.

 

Yacob Hassidim

 

From: lwip-users <lwip-users-bounces+yacobh=dds-security@nongnu.org> On 
Behalf Of simeon.trifo...@amk-drives.bg
Sent: Thursday, March 8, 2018 2:35 PM
To: 'Mailing list for lwIP users' <lwip-users@nongnu.org>
Subject: Re: [lwip-users] Support of two Ethernet connections

 

Hi Yacob,

 

I mean two MACs and two Phys. Actually one Phy is an Ethernet and the second is 
an Ethernet over VARAN (but for the stack it must look like a normal Ethernet 
Phy). 

 

Simeon

 

From: lwip-users <lwip-users-bounces+simeon.trifonov=amk-drives...@nongnu.org 
<mailto:lwip-users-bounces+simeon.trifonov=amk-drives...@nongnu.org> > On 
Behalf Of Yacob Hassidim
Sent: Thursday, March 08, 2018 2:30 PM
To: 'Mailing list for lwIP users' <lwip-users@nongnu.org 
<mailto:lwip-users@nongnu.org> >
Subject: Re: [lwip-users] Support of two Ethernet connections

 

Hello Simeon,

 

I am not going to answer but ask a question about your system.

 

By Ethernet adaptor what do you mean?

a.  Two MAC and two Phys or
b.  One MAC and two Phys

 

Sincerely,

 

Yacob Hassidim.

 

From: lwip-users <lwip-users-bounces+yacobh=dds-security@nongnu.org 
<mailto:lwip-users-bounces+yacobh=dds-security@nongnu.org> > On Behalf Of 
simeon.trifo...@amk-drives.bg <mailto:simeon.trifo...@amk-drives.bg> 
Sent: Thursday, March 8, 2018 2:01 PM
To: lwip-users@nongnu.org <mailto:lwip-users@nongnu.org> 
Subject: [lwip-users] Support of two Ethernet connections

 

Hi,

In my application I’m going to support two Ethernet adapters. I already have an 
implementation with only one, so I already have an experience with LWIP stack. 
Now I need to understand how the LWIP is designed to be used in case of two (or 
more) Ethernet adapters. It is clear that I need to use two separated netif 
structure for each adapter. What I’m wandering now is how to connect to it the 
initialized udp_pcb and tcp_pcb (they are different for both interfaces). How I 
can connect the pcbs to the netif-structures? If I cannot access the pcbs from 
netif-structure, then I need to add them like additional parameters to some 
functions… Sorry for this question, but I by reading in Internet I couldn’t 
find a good explanation how LWIP must be used in such case. So please, give me 
some hints…

 

Best regards!

 

Simeon

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

Re: [lwip-users] Support of two Ethernet connections

2018-03-08 Thread Yacob Hassidim
Hello Simeon,

 

I am not going to answer but ask a question about your system.

 

By Ethernet adaptor what do you mean?

a.  Two MAC and two Phys or
b.  One MAC and two Phys

 

Sincerely,

 

Yacob Hassidim.

 

From: lwip-users <lwip-users-bounces+yacobh=dds-security@nongnu.org> On 
Behalf Of simeon.trifo...@amk-drives.bg
Sent: Thursday, March 8, 2018 2:01 PM
To: lwip-users@nongnu.org
Subject: [lwip-users] Support of two Ethernet connections

 

Hi,

In my application I’m going to support two Ethernet adapters. I already have an 
implementation with only one, so I already have an experience with LWIP stack. 
Now I need to understand how the LWIP is designed to be used in case of two (or 
more) Ethernet adapters. It is clear that I need to use two separated netif 
structure for each adapter. What I’m wandering now is how to connect to it the 
initialized udp_pcb and tcp_pcb (they are different for both interfaces). How I 
can connect the pcbs to the netif-structures? If I cannot access the pcbs from 
netif-structure, then I need to add them like additional parameters to some 
functions… Sorry for this question, but I by reading in Internet I couldn’t 
find a good explanation how LWIP must be used in such case. So please, give me 
some hints…

 

Best regards!

 

Simeon

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

Re: [lwip-users] TCP Configuration: Minimum received bytes for callback

2018-02-28 Thread Yacob Hassidim
Hello,

 

Thank you for your answer.

 

Yacob Hassidim.

 

From: lwip-users
[mailto:lwip-users-bounces+yacobh=dds-security@nongnu.org] On Behalf Of
goldsi...@gmx.de
Sent: Tuesday, February 27, 2018 8:31 PM
To: Mailing list for lwIP users <lwip-users@nongnu.org>
Subject: Re: [lwip-users] TCP Configuration: Minimum received bytes for
callback

 

On 27.02.2018 16:32, Yacob Hassidim wrote:

Hello,

 

I want to wait till at least 3 bytes were received by TCP.

 

How the TCP minimum received bytes for callback is configured?


That's not supported. You'll have to queue the rx pbufs yourself in your
recv callback.

Simon 

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

Re: [lwip-users] LwIP configuration for directing LWIP_DEBUGF to user function

2018-02-25 Thread Yacob Hassidim
Helo Simon,

 

Thank you for referring me to lwip-contrib.

 

I downloaded the version contrib-2.0.1.

 

I found that LWIP_DEBUG is defined as compilation parameters of project
layer.

 

I didn't find mention of LWIP_PLATFORM_DIAG.

 

I use LwIP as part of ST CubeMx environment that defines LWIP_PLATFORM_DIAG
in cc.h as the following:

#define LWIP_PLATFORM_DIAG(message)  printf message

 

Can you please advise me how should I direct the "printf message" to
serial_write(char *message_string)?

 

Yacob Hassidim.

 

From: lwip-users
[mailto:lwip-users-bounces+yacobh=dds-security@nongnu.org] On Behalf Of
goldsi...@gmx.de
Sent: Sunday, February 25, 2018 2:27 PM
To: Mailing list for lwIP users <lwip-users@nongnu.org>
Subject: Re: [lwip-users] LwIP configuration for directing LWIP_DEBUGF to
user function

 

On 25.02.2018 13:18, Yacob Hassidim wrote:

Can you please send an example of definitions of LWIP_DEBUG and
LWIP_PLATFORM_DIAG?


Instead of sharing yet more ports, why don't you have a look at the example
ports for windows or linux in lwip-contrib? There you will find what you are
looking for.

Simon

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

Re: [lwip-users] LwIP configuration for directing LWIP_DEBUGF to user function

2018-02-25 Thread Yacob Hassidim
Hello Noam,

 

Thank you for your fast response.

 

Can you please send an example of definitions of LWIP_DEBUG and
LWIP_PLATFORM_DIAG?

 

Yacob Hassidim,

Real Time Embedded Software Engineer

Mobile: 052-3468818

 

From: lwip-users
[mailto:lwip-users-bounces+yacobh=dds-security@nongnu.org] On Behalf Of
Noam Weissman
Sent: Tuesday, February 20, 2018 3:37 PM
To: Mailing list for lwIP users <lwip-users@nongnu.org>
Subject: Re: [lwip-users] LwIP configuration for directing LWIP_DEBUGF to
user function

 

Hi Yacob,

 

In file sysy_arch.c you have an include to debug.h

 

If you set LWIP_DEBUG you need to define  LWIP_PLATFORM_DIAG

 

LWIP_PLATFORM_DIAG is your wrapper for printing

 

Normally this is defined in cc.h that is part of your micro porting code.

 

Hope that helped,

Noam.

 

 

 

From: lwip-users [mailto:lwip-users-bounces+noam=silrd@nongnu.org] On
Behalf Of Yacob Hassidim
Sent: Tuesday, February 20, 2018 2:44 PM
To: lwip-users@nongnu.org <mailto:lwip-users@nongnu.org> 
Subject: [lwip-users] LwIP configuration for directing LWIP_DEBUGF to user
function

 

Hello,

 

I use LwIP version 2.0.0.

 

How to configure LwIP in order to direct LWIP_DEBUGF to user function e.g.
serial_write() ?

 

Thanks.

 

Yacob Hassidim.

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

[lwip-users] LwIP configuration for directing LWIP_DEBUGF to user function

2018-02-20 Thread Yacob Hassidim
Hello,

 

I use LwIP version 2.0.0.

 

How to configure LwIP in order to direct LWIP_DEBUGF to user function e.g.
serial_write() ?

 

Thanks.

 

Yacob Hassidim.

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

[lwip-users] Ethernet MAC Interrupt

2018-02-12 Thread Yacob Hassidim
Hello all,

 

My board contains the controller of STM32F4 and Ethernet Phy of Microchip.

 

The board is connected to PC by Ethernet LAN.

 

The receive path of MAC is connected to Scope.

 

I send ping from PC and see on Scope the packet to MAC of the controller but
there is no interrupt.

 

Can somebody advise?

 

Thanks.

 

Yacob Hassidim.

 

___
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users