EmbeddedRelated.com
Forums

TCP version of lpc21isp

Started by nourson54 July 21, 2006
Hi,

For those who are interested I have modified the version 1.31 of
lpc21isp in order to be able to program lpc parts using a TCP
connection instead a serial com port.

It can be useful if you're using a Ethernet/serial bridge on your
board as I do with Xport parts from Lantronix .
Until now, I have to use a virtual com port redirector in order to
bridge lpc21isp.

I's using winsock 2 and it compiled with gcc. I have to 'properly'
include my source code into lpc21isp, but in a short time , I could
post the file here.

Moreover, I developped a little GUI wrapper for lpc21isp (in c# so
.net). It can reset the board in prog mode (via XPort I/O) and then
launch lpc21isp via the shell.

Regards,

Yann.

An Engineer's Guide to the LPC2100 Series

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

nourson54 wrote:
> For those who are interested I have modified the version 1.31 of
> lpc21isp in order to be able to program lpc parts using a TCP
> connection instead a serial com port.
>
> It can be useful if you're using a Ethernet/serial bridge on your
> board as I do with Xport parts from Lantronix .
> Until now, I have to use a virtual com port redirector in order to
> bridge lpc21isp.
>
> I's using winsock 2 and it compiled with gcc. I have to 'properly'
> include my source code into lpc21isp, but in a short time , I could
> post the file here.
>
> Moreover, I developped a little GUI wrapper for lpc21isp (in c# so
> .net). It can reset the board in prog mode (via XPort I/O) and then
> launch lpc21isp via the shell.

Your post triggered me to have a closer look at lpc21isp.

I'm a bit surprised to see that it consists of just one big
source file, with lots of "#if defined". I can imagine that it is
quite complex to add new functionality to it.

How about the following improvements:
* Cutting up the code into sensible chunks:
* COM port communication layer: windows and linux versions can
have the same interface (e.g. com.h) but different implementations
(say a com_linux.c file and a com_w32.c file). I think this can
reduce the amount of "#if"s somewhat.
* separate the commandline parsing code from the core functionality.
* put the AnalogDevices code in a separate source file
* Create a proper Makefile

?

Regards,
Bertrik
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFEwRYPETD6mlrWxPURApviAJ98GaGjWzrWt4CgXhI7l+TcETtvJgCdF5UR
sDUhd6CxxjViuD8o66EduQ4=jSEW
-----END PGP SIGNATURE-----
--- In l..., "nourson54" wrote:

> For those who are interested I have modified the version 1.31 of
> lpc21isp in order to be able to program lpc parts using a TCP
> connection instead a serial com port.

Please post your code here! Or email to me if you don't want to upload
it here.

> Moreover, I developped a little GUI wrapper for lpc21isp (in c# so
> .net). It can reset the board in prog mode (via XPort I/O) and then
> launch lpc21isp via the shell.

It might be cool to write a C# port of lpc21isp. I want to enhance my
C# debugger to support ISP, and also JTAG via OpenOCD. I'm also
looking at supporting the Stellaris Cortex M3 devices when I get some
time.

Eric