Question

I'm currently working with the µIP TCP/IP library, for use on an embedded system. My question is a very simple one: I have downloaded the source code for the library, but how do I install it on my device? I realize that I have to build the library and then link it to my C file in which I am working with. Basically, I'm trying to build this library on a FOX G20 V embedded board (with no OS) with an ATMEL AT91SAM9G20 processor. Are there any helpful tips/links that might allow me to build the library on device. And as a bonus, if anyone has an idea how to modify the library to be specific to that platform for ethernet communications would be very helpful.

Was it helpful?

Solution

The library appears to have been subsumed into the Contiki OS, but is available also as a stand-alone library. You might also consider lwIP originally from the same author but supported as an open-source project in active development in it's own right.

In essence the library is not "installed" as such, but simply compiled and linked to your application code. Assuming that your target has no OS or a simple RTOS kernel, and that you are therefore using a hosted cross-development tool-chain, you would typically build the library (any library - this is not specific µIP) from the source as a static-link library, then link that to your application code to create a monolithic application image, which is then loaded to your target's ROM. It is also possible to compile and link the source to your application directly as you would any other source code without creating an intermediate static library - but this will extend your application build time, which may become and issue on a large project during development. However in this case µIP (having looked at the documentation) has a number of compile-time configuration options, that will be fixed if you build a static library; so if you envisage these things changing often, including the source code directly in your application project may be simpler.

You will no doubt also have to write, compile and link the platform specific device driver to allow the library to work on your hardware. I have taken a look at the library documentation, and a device driver interface is defined.

It seems that you might need to familiarise yourself with the embedded development process more generally before you worry about integrating a third-party library.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top