interniche

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

interniche

7,243件の閲覧回数
wkurzbauer
Contributor I

Hello,

Please can you tell me the most up-to-date version of Nichelite for coldfire processors.

I run a digibutler board (MFC52531) from the lektor magaize in the year 2008.

As I have problems with the TCP/IP stack (heap problems) I would like to know if

eventually a newer revision than mine (rev.3.2) exists.

If so please can you also provide me a link to it.

Thank you

Werner Kurzbauer

0 件の賞賛
返信
23 返答(返信)

758件の閲覧回数
wkurzbauer
Contributor I

Hi,

Thank you for your quick response!!! Actually I did not expect that anyone is still responding on a "digibutler" topic...

I currently try to adapt the rev.3.2 to my digibutler board (as specifically the cpu definitions appear to have changed from

the previous Nichelite version).

As you are also using a Digibutler may I ask if you also noticed the problem that after some days the server stopped apparently having a heap allocation problem (calloc1.c and npalloc.c report problems via printf (RS232) and the ftp stack stop to work).

I tried to find the problem but only with little success as it might really be located deep in the guts of the system.

Maybe you found  a solution...

My hope was this new revision but the migration of my own code and the adaption to my digibutler board seem to require much more effort than hoped.

Did you already adapt the cpu definitions of rev.3.2. to the digibutler board?

I use codewarrior 7.1 so I hope I do not have any problem from the compiler side (I do not really what is "CW 7.2 ABI change" !!??).

If you are still interested in fiddling around with the digibutler board

 I really appreciate an exchange of knowledge and experience!!

Thanks a lot and regards

Werner

0 件の賞賛
返信

758件の閲覧回数
vier_kuifjes
Senior Contributor I

I know about the Digibutler but never used it.

It may well be that you can run the NicheLite stack on the Digibutler without modification. I had it running on both MCF52233 and MCF52235 MCUs without change. You do have to compile the stack on codewarrior 7.2 however, preferrably with all updates installed. Some of the modifications I did were to make it compatible with this version and have to do with the REG_ABI thingy. When REG_ABI is used, parameters are passed to subroutines via CPU registers instead of the stack. This is taken care of automatically by the compiler, but if the program also contains assembly language routines that assume parameters are being passed by the stack, these routines will no longer function properly. Interniche does contain some assembly language routines, which I modified to take parameters via the CPU registers instead of the stack.

0 件の賞賛
返信

758件の閲覧回数
TomE
Specialist II

I have never heard of the "Digibutler" until your post. I just read Marc Vandenhende's post back in 2013 and took a copy of the stack as I knew someone would be asking for it 5 years later, and you did :-).

> I do not really what is "CW 7.2 ABI change" !!??

If you're working with CodeWarrior it is important that you do. You're using 7.1, and I assume the "old system" that works with all the sample code released to that date and all the code in the App Notes. Then in 7.2 the ABI was changed and that broke all existing code (any code that used assembly). I assume that Marc's version of the code has been changed to work with the new one.

You should still compare Marc's sources with your original sources to find the bugs he's fixed in case he fixed your one. But you'll have to know how to recognise the changes that the 7.1 to 7.2 migration caused otherwise that may confuse you.

Here's some notes I keep on that:

https://community.freescale.com/message/401840#401840

Read my last post here:

https://community.freescale.com/message/356263#356263

This mentions that the parameter passing changed between CW7.1 and CW7.2:

Re: Updating CW 7.1 to 7.2, using MQX 3.3,  missing librarys

https://community.freescale.com/message/66959#66959

Marc Vandenhende Jun 17, 2010 11:11 PM (in response to Mark Armbrust)

"CW7.2 uses a different way to pass parameters to functions (REG_ABI) compared to CW7.1, which uses STD_ABI by default. These methods are not compatible with each other."

Search (at top right of this page) for "REG_ABI".

Other posts said that prior to 7.2 you could select either option, and all the libraries and example code on Freescale's web site defaulted to STD_ABI. With CW7.2 that option was removed, and it changed to REG_ABI. So all existing Assembly code broke, and none of the sample code (in App Notes and so on) got updated. This traps everybody, but isn't documented anywhere that I can find. It might be in the documentation provided with CW somewhere, I've never had a copy to check.

7.12 was released in June 2nd, 2009.

7.2 released 22 Jan 2010.

> apparently having a heap allocation problem

Either the Nichelite code isn't correctly freeing memory that it has malloced, is using data after being freed, is double-freeing, or your code that interfaces to it isn't allocating or freeing properly. The "standard way" to diagnose this is to completely replace the memory allocator with one that has diagnostics and that can detect and report bad operations.

Google finds this. Try replacing your "malloc" with something like this and then run:

http://scottmcpeak.com/memory-errors/

> after some days the server stopped

It is very hard to take a "demo project" that runs once, and then turn it into something that can run for weeks or months. That usually takes a lot of work, sometimes even a rewrite.

> calloc1.c and npalloc.c

Those files don't exist in the Nichelite TCP/IP sources. There's only "src/common/alloc.c" which is worryingly simple and has a comment at the top that says "99% of this code stolen/borrowed from the K&R C examples". So your allocator must be someone else's. I'm guessing (from Google searches) it is the one in the OS you're using.

Have you checked here for updates? I suspect Coldfire won't have been supported for years though. Correct - I've just run Nichelite's "Configurator" and Coldfire is nowhere to be seen.

https://www.hcc-embedded.com/embedded-systems-software-products/tcp-stack-networking

p.s. (I don't know why this editor has made the rest of my text BLUE or how to fix it, I've tried three times already.

Tom

0 件の賞賛
返信