Reply by rodboyce70 April 19, 20062006-04-19
And for the ones that do offer ISP use that instead :-) for all the
rest use something else..... ;-)

Rod
--- In l..., "tbavp" wrote:
> And for those who "may not know better", I count 15 LPC devices on my
> June 2005 Philips microcontroller line card that only have ICP
> programming capability! They don't even have parallel programmer access.
>
> So for these lower-pin-count devices, ISP is simply not an option.
>
> tom
>
> --- In l..., "rodboyce70"
> wrote:
> >
> > All,
> >
> > At the risk of upsetting people who may or may not know better. I
> > would suggest that instead of ICP you use the ISP protocol. It is
>
Reply by tbavp April 19, 20062006-04-19
And for those who "may not know better", I count 15 LPC devices on my
June 2005 Philips microcontroller line card that only have ICP
programming capability! They don't even have parallel programmer access.

So for these lower-pin-count devices, ISP is simply not an option.

tom

--- In l..., "rodboyce70"
wrote:
>
> All,
>
> At the risk of upsetting people who may or may not know better. I
> would suggest that instead of ICP you use the ISP protocol. It is
Reply by rodboyce70 April 14, 20062006-04-14
All,

The link to the source file is
http://cvs.sourceforge.net/viewcvs.py/lpc935-prog/lpc935-prog/lpc935-prog.c?rev=1.4&view=auto
from the link below select cvs then browse repository.

I do not measure the pulse length there is no need to if did not go
into bootloader mode this time when try the command again, I detect
this but the looking at the output on the screen. THese pulses are so
short compaired to the length of a time slice that you have to be
unlucky to b task switched and have one pulse lengthened. A task
periord is usually 10mS to 50mS this is an age when trying to generate
3 pulses with a total time of 64uS (16uS high and 48uS low). Using
the serial port is less hassel than the parallel port but until you
try it you are never going to know if it will work.

Regards,
Rod

--- In l..., "Mohsen Heidari"
wrote:
>
> Rod,
>
> I couldn't find the files at the link you said, but if Jan's guess is
> right, it sounds a very creative and interesting solution to me too.
>
> I still haven't received my Philips chips, and besides that I've got a
> list of nearly 6473765.563 jobs to do for the easter, otherwise I
> would surly give it a try!
>
> Cheers, and thanks
> Mohsen
>
> --- In l..., Jan Waclawek wrote:
> >
> > rodboyce70 wrote:
> > > PC's today are more than fast enough to do what you want to do even
> > > under windows you just have to be prepared to try a second time.
> >
> > Congratulations!
> >
> > Without attempting to understand your code, does this mean that you
> > measure the length of pulses you are creating, so you know it went
> wrong
> > and an another process kicked in meantime?
> >
> > Thanks,
> >
> > Jan Waclawek
>
Reply by Mohsen Heidari April 13, 20062006-04-13
Rod,

I couldn't find the files at the link you said, but if Jan's guess is
right, it sounds a very creative and interesting solution to me too.

I still haven't received my Philips chips, and besides that I've got a
list of nearly 6473765.563 jobs to do for the easter, otherwise I
would surly give it a try!

Cheers, and thanks
Mohsen

--- In l..., Jan Waclawek wrote:
>
> rodboyce70 wrote:
> > PC's today are more than fast enough to do what you want to do even
> > under windows you just have to be prepared to try a second time.
>
> Congratulations!
>
> Without attempting to understand your code, does this mean that you
> measure the length of pulses you are creating, so you know it went
wrong
> and an another process kicked in meantime?
>
> Thanks,
>
> Jan Waclawek
>
Reply by Jan Waclawek April 13, 20062006-04-13
rodboyce70 wrote:
> PC's today are more than fast enough to do what you want to do even
> under windows you just have to be prepared to try a second time.

Congratulations!

Without attempting to understand your code, does this mean that you
measure the length of pulses you are creating, so you know it went wrong
and an another process kicked in meantime?

Thanks,

Jan Waclawek
Reply by rodboyce70 April 13, 20062006-04-13
All,

At the risk of upsetting people who may or may not know better. I
would suggest that instead of ICP you use the ISP protocol. It is
serial based and all you need is a RS-232 level shifter to program the
chip if set up correctly. I have written such code for both windows
and linux and everybody said that you wont be able to garantee the
timming of the reset pulses if a task switch occures and it might
fail and the world will generally be a bad palce to be after this code
is written. Well I have done it and in the 3 boards I have designed
that use this code to program them with no problems. Well it works
fine for me as long as you don't use a USB serial port. Yes there are
better ways to do this I agree but this is the way I implemented it
and it works fine for me. I have even put it up on sourceforge under
http://sourceforge.net/projects/lpc935-prog at the very least it will
show you how to do very fast and precise loops from both windows and
linux for you own code. I will say that this code is very simple but
it works fine for me. I have a very simple MAX3232 and
two transistors doing the level shifting, I use DTR to power the chip
on and off and RTS to toggle the reset line look at the function
lpc_PlaceInBootLoaderMode in my code on sourceforge if you want to see
how I have did it.

PC's today are more than fast enough to do what you want to do even
under windows you just have to be prepared to try a second time. I
would say if you are really keen to do an ICP from the parallel port
then give it a go the only thing you have to loose is time and if you
have plenty of that then the issues you are going to have to over-come
are not all that differcult.
Low level hardware access on even a windows PC is not that hard look
up a device driver called directio for a simple one there are lots of
them out there and they all use the same basic mechanism.

Anyway good luck while I have not done this I have bit bashed I2C on
parrallel ports before. In-fact how I have read the specification a
little it looks very simple. This looks like a good easter project
feel free to use the code I wrote for my own ISP programer you could
just add the extra loops necessary for ICP mode and you are 25%
of the way there I placed my code under LGPL for this reason.

Hope this helps regards,
Rod Boyce.

PS if you get stuck leave me a message on this group and I'll make
contact off line for more assistance.

--- In l..., "Mark Hall" wrote:
>
> I can tell you first hand - the timing for the reset pulses is critical,
> which bit-banged parallel port is not known for...especially going
through
> the drivers required for low-level hardware access in NT/XP. We have
> parallel port devices and we're phasing them out due to the "sloppy"
nature
> and driver issues.
>
> Remember, to ICP program LPC9xx devices, you MUST control the power and
> reset of the target device under software control to be able to
"match" the
> timing requirements.
>
> Also, you would have to write 100% of the software since FlashMagic is
> serial port-based and would not work with a parallel port programmer.
>
> Philips supports FlashMagic, so it's always going to stay up to date
with
> the newest device support and continue to grow.
>
> Regards,
> Future Designs, Inc.
>
>
> _____
>
> From: l...
[mailto:l...] On
> Behalf Of Mohsen Heidari
> Sent: Wednesday, April 12, 2006 2:42 AM
> To: l...
> Subject: RE: [lpc900_users] How to ICP?
> You are right Jan. As a matter of fact, I haven't studied detailed
> specifications of ICP yet. But I've used that sort of simple
programmers for
> the Atmel ATMEGA series in the past and I found them very reliable;
hence I
> guessed a similar solution might be available for the Philips P89LPC9x
> series too.
>
> Mohsen
Reply by Mark Hall April 12, 20062006-04-12
I can tell you first hand - the timing for the reset pulses is critical,
which bit-banged parallel port is not known for...especially going through
the drivers required for low-level hardware access in NT/XP. We have
parallel port devices and we're phasing them out due to the "sloppy" nature
and driver issues.

Remember, to ICP program LPC9xx devices, you MUST control the power and
reset of the target device under software control to be able to "match" the
timing requirements.

Also, you would have to write 100% of the software since FlashMagic is
serial port-based and would not work with a parallel port programmer.

Philips supports FlashMagic, so it's always going to stay up to date with
the newest device support and continue to grow.

Regards,
Future Designs, Inc.

_____

From: l... [mailto:l...] On
Behalf Of Mohsen Heidari
Sent: Wednesday, April 12, 2006 2:42 AM
To: l...
Subject: RE: [lpc900_users] How to ICP?
You are right Jan. As a matter of fact, I haven't studied detailed
specifications of ICP yet. But I've used that sort of simple programmers for
the Atmel ATMEGA series in the past and I found them very reliable; hence I
guessed a similar solution might be available for the Philips P89LPC9x
series too.

Mohsen
-----Original Message-----
From: l... [mailto:l...] On
Behalf Of Jan Waclawek
Sent: Wednesday, 12 April 2006 2:40 PM
To: l...
Subject: Re: [lpc900_users] How to ICP?

Mohsen Heidari wrote:
> Thanks for the replies. Both devices
> (http://www.teamfdi.com/pages/products_index.html
> and http://www.precma.it/lpcprogrammer.htm) seem reasonable and I may
> order one, but I was originally thinking of something even simpler!
>
> The PCL and PDA signals required for ICP can be generated easily by
> the parallel port of PC. So the hardware will be just a flat cable
> with an IDC at one end and a male DB25 with probably one or two
> transistors at the another end. I was about to develop one by myself,
> but thought it must already be available on the net.
>
> Any ideas?
>
> Mohsen

While it sounds reasonably, it might fail because of the tight timing
requirement of reset line "pulsing", especially in multitasking
environments.
And, of course, the well known troubles associated with similar
constructions apply, proper signal conditioning and termination,
crosstalks...

Jan Waclawek

> .
_____
Reply by Mohsen Heidari April 12, 20062006-04-12
You are right Jan. As a matter of fact, I haven't studied detailed
specifications of ICP yet. But I've used that sort of simple programmers for
the Atmel ATMEGA series in the past and I found them very reliable; hence I
guessed a similar solution might be available for the Philips P89LPC9x
series too.

Mohsen
-----Original Message-----
From: l... [mailto:l...] On
Behalf Of Jan Waclawek
Sent: Wednesday, 12 April 2006 2:40 PM
To: l...
Subject: Re: [lpc900_users] How to ICP?

Mohsen Heidari wrote:
> Thanks for the replies. Both devices
> (http://www.teamfdi.com/pages/products_index.html
> and http://www.precma.it/lpcprogrammer.htm) seem reasonable and I may
> order one, but I was originally thinking of something even simpler!
>
> The PCL and PDA signals required for ICP can be generated easily by
> the parallel port of PC. So the hardware will be just a flat cable
> with an IDC at one end and a male DB25 with probably one or two
> transistors at the another end. I was about to develop one by myself,
> but thought it must already be available on the net.
>
> Any ideas?
>
> Mohsen

While it sounds reasonably, it might fail because of the tight timing
requirement of reset line "pulsing", especially in multitasking
environments.
And, of course, the well known troubles associated with similar
constructions apply, proper signal conditioning and termination,
crosstalks...

Jan Waclawek
Reply by Jan Waclawek April 12, 20062006-04-12
Mohsen Heidari wrote:
> Thanks for the replies. Both devices
> (http://www.teamfdi.com/pages/products_index.html
> and http://www.precma.it/lpcprogrammer.htm) seem reasonable and I may order
> one, but I was originally thinking of something even simpler!
>
> The PCL and PDA signals required for ICP can be generated easily by the
> parallel port of PC. So the hardware will be just a flat cable with an IDC
> at one end and a male DB25 with probably one or two transistors at the
> another end. I was about to develop one by myself, but thought it must
> already be available on the net.
>
> Any ideas?
>
> Mohsen

While it sounds reasonably, it might fail because of the tight timing
requirement of reset line "pulsing", especially in multitasking
environments.
And, of course, the well known troubles associated with similar
constructions apply, proper signal conditioning and termination,
crosstalks...

Jan Waclawek
Reply by Mohsen Heidari April 12, 20062006-04-12
Thanks for the replies. Both devices
(http://www.teamfdi.com/pages/products_index.html
and http://www.precma.it/lpcprogrammer.htm) seem reasonable and I may order
one, but I was originally thinking of something even simpler!

The PCL and PDA signals required for ICP can be generated easily by the
parallel port of PC. So the hardware will be just a flat cable with an IDC
at one end and a male DB25 with probably one or two transistors at the
another end. I was about to develop one by myself, but thought it must
already be available on the net.

Any ideas?

Mohsen


-----Original Message-----
From: l... [mailto:l...] On
Behalf Of Fausto Marzoli
Sent: Tuesday, 11 April 2006 5:52 PM
To: l...
Subject: Re: [lpc900_users] How to ICP?

Alle 11:10, marted11 aprile 2006, Mohsen Heidari ha scritto:

> I am considering switching from Atmel AT89Cxx to Philips P89LPC9xx
> devices and I'm looking for a very easy and low cost way for in
> circuit programming (ICP, not ISP). What is the cheapest solution for
this? I don't want to
> buy an MCB900 from Keil.

http://www.precma.it/lpcprogrammer.htm
--
Fausto Marzoli - 8052.it - http://www.8052.it/