lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [lwip-users] Using UDP and TCP simultaneously (FreeRTOS 4.2.1 & lwip


From: Andrew_Kunz
Subject: RE: [lwip-users] Using UDP and TCP simultaneously (FreeRTOS 4.2.1 & lwip 1.1.0)
Date: Thu, 24 Jan 2008 15:52:35 -0500


Thanks.  I will check with Atmel on the difference between the date codes.  0718 is the date.

The 1.2.0 upgrade should be very clean, and yes, it fixed a number of issues for me.  I'm dreading doing the 1.3.0 though since so much changed.

Can't answer you on TTL, though, sorry.

Andy




"BMW Cyclist RR" <address@hidden>
Sent by: address@hidden

01/24/2008 03:48 PM

Please respond to
Mailing list for lwIP users <address@hidden>

To
<address@hidden>
cc
Subject
RE: [lwip-users] Using UDP and TCP simultaneously (FreeRTOS 4.2.1        &        lwip 1.1.0)





Andy,
 
Thank you for your answers. I've checked out the lwip 1.2.0 source code and indeed the files and overall structure look quite similar to v.1.1.0. So I may go ahead and upgrade my lwip as you recommend. Famous last words: "Things can only get better" and "What could it hurt?."
 
As far as the particulars for the AT91SAM7X512 chip I have (received as a sample from Atmel), here are the top side chip markings:
 
    AT91SAM7X512AU-ES
    0718
    7P0613D
 
Hopefully you will know which code reflects the date of manufacture (0718 perhaps).
 
Hey, while I've got your attention, is there a way to set the TTL for a UDP packet for a particular "connection" using lwip? I saw only a top level setting in lwipopts.h so far which I assumed would apply to all UDP packets (i.e. #define UDP_TTL 255).
 
Thanks,
 
Dave Squires

-----------------------------------
SQUIRES ENGINEERING, INC.
2604 Lowell Circle
Melbourne, FL 32935-2215
phone:  (321) 242-8611
fax:    (321) 242-0949
website:
http://www.squires-eng.com
-----------------------------------

 
 
 
-----Original Message-----
From:
address@hidden [mailto:address@hidden
Sent:
Thursday, January 24, 2008 2:30 PM
To:
address@hidden
Subject:
Re: [lwip-users] Using UDP and TCP simultaneously (FreeRTOS 4.2.1 & lwip 1.1.0)


Dave,


ANSWERS:


We had trouble initially with the demo version on the website, but upgrading to 1.2.0 fixed it.  It was a very straightforward upgrade.  Going to 1.3.0 turned out to be something that would require an awful lot of changes, so I haven't done that yet (but would like to).  If you get 1.3.0 running in the demo system, I'd love to get a copy of what you changed.


I would definitely recommend that you start by upgrading to 1.2.0.


Our app is built using gcc, and I'm using the SAM-BA USB bootloader to stuff code into mine.  I'm not running JTAG for anything.  My Ethernet-using tasks are all created using an updated sys_thread() function.  If you look into sys_thread() code, tasks are actually created calling xTaskCreate() - so they're the same in the long run.  From what I can tell, it doesn't matter.


QUESTION:


Can you give me the date code off your chip?  I am using date code 0705.  We had a problem with some stuff with Atmel and I'm trying to see what others using the same chip are seeing.  I'm actually waiting for chips from a new die lot to be delivered to me.


Andy



"BMW Cyclist RR" <address@hidden>
Sent by: address@hidden

01/24/2008 01:45 PM

Please respond to
Mailing list for lwIP users <address@hidden>


To
<address@hidden>
cc
Subject
[lwip-users] Using UDP and TCP simultaneously (FreeRTOS 4.2.1 &        lwip 1.1.0)







I am hoping someone can provide some insight regarding some problems I am
seeing when trying to use UDP (multicast) and TCP (FreeRTOS 4.2.1 BasicWeb
demo app) concurrently on a AT91SAM7X512 platform.

I am doing development under YAGARTO on WinXP using Eclipse with gcc. My
makefile successfully builds the standard FreeRTOS 4.2.1 release just fine.
I can run gdb on my platform under Eclipse using the Amontec JTAGKEY
product.

I've kept the basic Web server application intact while I've added a UDP
task that sends multicast packets via the default ethernet interface. I am
using a standard Atmel AT91SAM7X-EK board with a (self-upgraded)
AT91SAM7X512 processor. So I now have a full 128 KB of RAM available.

The UDP task is currently created in the vBasicWEBServer function within the
BasicWeb.c file, after the lwip initialization functions have been called
and after the network interface has been brought up (i.e. netif_set_up).

The BasicWEB sys_thread is executing at tskIDLE_PRIORITY + 2, as is my UDP
task. Another trival task to simulate SPI I/O is creating data for the UDP
task and runs in a simple loop using vTaskDelay calls. It's also running
with a priority of tskIDLE_PRIORITY + 2. All tasks and the BasicWeb
sys_thread have default stack sizes of configMINIMAL_STACK_SIZE.

The UDP task sends relatively large packets (~1400+ bytes) via multicast and
sends packets almost continuously. I've inserted a 1 mSec delay after each
UDP packet is sent and a 10 mSec delay after every ten or so packets are
sent. The application is a phased array sonar device, hence the relatively
high data rate. I am running the ethernet at 100 Mb/sec.). I am using the
netconn API in lwip for the UDP application.

I've of course enabled udp in the lwipopts.h file and called udp_init()
right after ip_init() in the vlwIPInit funtion in BasicWEB.c. I've kept the
defaults in lwipopts.h. I've also kept:

               configTOTAL_HEAP_SIZE                                  ( ( size_t ) 22000 )

I've kept all the FreeRTOS demo tasks intact and alive as a sanity check
that I've not broken something in FreeRTOS as I add code to my applications.
Thus I see the LEDs flashing as usual on the AT91SAM7X-EK board until
something "bad" happens.

The UDP application runs very reliably and when executing by itself
seemingly will run forever. However, when I attempt to exercise the demo
webserver task, the software appears to "hang up" in one of several places
in the code. I won't elaborate on those before I ask the group some basic
questions.

1. Why is the demo web server app created as a sys_thread, not as a generic
FreeRTOS task?
2. Should additional tasks that require access to lwip functionality also be
implemented as sys_threads, not FreeRTOS tasks as I have done?
3. Would upgrading my lwip to version 1.2.0 be a good idea before worrying
further about my applications?
4. I also need to implement another tcp task to provide a control interface
for the sonar unit. So I need to get these issues straightened out before I
add additional code and confusion to the mix.

Any help or insight would be most appreciated.

Thanks,

Dave Squires

-----------------------------------
SQUIRES ENGINEERING, INC.
2604 Lowell Circle
Melbourne, FL 32935-2215
phone:  (321) 242-8611
fax:    (321) 242-0949
website: http://www.squires-eng.com
-----------------------------------



_______________________________________________
lwip-users mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/lwip-users


_______________________________________________
lwip-users mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/lwip-users



reply via email to

[Prev in Thread] Current Thread [Next in Thread]