RE: different IP than expected

2023-09-21 Thread Gustavo Soares
king for a way to do this. Thank you all for the support! De: Gregory Nutt Enviado: quinta-feira, 21 de setembro de 2023 10:45 Para: dev@nuttx.apache.org Assunto: Re: different IP than expected On 9/21/2023 6:34 AM, Simon Filgis wrote: > When I started with

Re: different IP than expected

2023-09-21 Thread Gregory Nutt
On 9/21/2023 6:34 AM, Simon Filgis wrote: When I started with networking, I set the IP via kconfig. I remember that it was necessary to enter the same IP at two different places. Netlib and FTP server in my case. Maybe your IP is overwritten by another app? A buildin app that you use for experime

Re: different IP than expected

2023-09-21 Thread Gregory Nutt
On 9/21/2023 6:53 AM, Petro Karashchenko wrote: setting "address.sin_addr.s_addr" + "bind" is kind of a way you can use to receive requests only from an interface that has a specific IP address. This is useful if your system has multiple network interfaces and you want to provide some kind of iso

Re: different IP than expected

2023-09-21 Thread Petro Karashchenko
a, 21 de setembro de 2023 09:35 > Para: dev@nuttx.apache.org > Assunto: Re: different IP than expected > > I think that you misunderstood the data flow a bit. > > So you have > ... > address.sin_family = AF_INET; > address.sin_addr.s_addr = INADDR_ANY; > addr

RE: different IP than expected

2023-09-21 Thread Gustavo Soares
So setting a value for the IP address in Kconfig and assigning it to address.sin_addr.s_addr should solve the problem? De: Petro Karashchenko Enviado: quinta-feira, 21 de setembro de 2023 09:35 Para: dev@nuttx.apache.org Assunto: Re: different IP than expected

Re: different IP than expected

2023-09-21 Thread Petro Karashchenko
t; the incoming requests so you can take a better look. How should I make the > API call to get the device IP? > -- > *De:* Petro Karashchenko > *Enviado:* quinta-feira, 21 de setembro de 2023 09:00 > *Para:* dev@nuttx.apache.org > *Assunto:* Re: diff

Re: different IP than expected

2023-09-21 Thread Simon Filgis
When I started with networking, I set the IP via kconfig. I remember that it was necessary to enter the same IP at two different places. Netlib and FTP server in my case. Maybe your IP is overwritten by another app? A buildin app that you use for experiments? -- Ingenieurbüro-Filgis USt-IdNr.: DE3

RE: different IP than expected

2023-09-21 Thread Gustavo Soares
Para: dev@nuttx.apache.org Assunto: Re: different IP than expected Yeah, But what is in between [image.png] and [image.png] ??? Do you have any API call to get the IP? Because I read that like "int a = 10; printf("%d", a);" If there is no API call to update "addre

Re: different IP than expected

2023-09-21 Thread Gregory Nutt
On 9/21/2023 5:06 AM, Gustavo Soares wrote: Why is it a different IP? The server is listening to one but this method returns another one. You provide almost no information for anyone to really help you. Where is the server and client?  It sounds like you are saying that the HTTP server is o

Re: different IP than expected

2023-09-21 Thread Petro Karashchenko
; >  > Hi, Petro! > > I use this struct: > > [image: image.png] > > and this where I use the inet_ntoa: > > [image: image.png] > -- > *De:* Petro Karashchenko > *Enviado:* quinta-feira, 21 de setembro de 2023 08:16 > *Para

Re: different IP than expected

2023-09-21 Thread MIGUEL ALEXANDRE WISINTAINER
-feira, 21 de setembro de 2023 08:16 Para: dev@nuttx.apache.org Assunto: Re: different IP than expected Hi, But what do you pass to "inet_ntoa"? Maybe you get the IP of your PC or a default router IP and try to print it? Best regards, Petro чт, 21 вер. 2023 р. о 14:06 Gust

Re: different IP than expected

2023-09-21 Thread MIGUEL ALEXANDRE WISINTAINER
ache.org>> Subject: Re: different IP than expected Hi, "INADDR_ANY" definitely does not match "listens to the defined IP" statement. I do not understand exactly what you are trying to do, but it would be good to know what is the output of "ifconfig" running fr

RE: different IP than expected

2023-09-21 Thread Gustavo Soares
Assunto: Re: different IP than expected Hi, But what do you pass to "inet_ntoa"? Maybe you get the IP of your PC or a default router IP and try to print it? Best regards, Petro чт, 21 вер. 2023 р. о 14:06 Gustavo Soares mailto:gustavo.felipesoa...@hotmail.com>> пише: I don

Re: different IP than expected

2023-09-21 Thread Petro Karashchenko
Hi, "INADDR_ANY" definitely does not match "listens to the defined IP" statement. I do not understand exactly what you are trying to do, but it would be good to know what is the output of "ifconfig" running from NSH. If you do not want to share code details, maybe you can check how your applicatio

different IP than expected

2023-09-20 Thread Gustavo Soares
Hello everyone! I configured NuttX to a certain IP address and I have a webserver which listens to the defined IP: [cid:820c9f69-369e-403b-8928-15a97245100a] [cid:a42eded4-3e24-4b28-b0a7-07170d21a404] The HTML file above has a variable that contains the server IP address, but it is a differe