P89C51 / P89V51 FLash Magic ISP programming compatability

Started by phonoplug, June 07, 2006, 09:11:20 AM

Previous topic - Next topic

phonoplug

Hello.

Have just tried the P89V51RD2 on an existing design that uses the 'C51RD2 chip.

Previously the 'C51 was programmed using Flash Magic and the DTR / RTS lines to trigger ISP entry. However, now programming the 'V51, I find that the DTR line holds the processor permanently in reset so it cannot enter ISP mode.

When I cut the track on the application PCB that connects DTR to the watchdog trip input to reset the processor all I have to do is just plug in the power once I 'START' Flash Magic, and it all runs fine. Unfortunately this means a new board issue for production though.

Question is this - is there any reason why Flash Magic has to hold the DTR in the state that on the 'C51 would be permanently resetting the processor? Sureley I am not the only one being forced to change from C51 to V51 that would be very grateful for a bit of compatability here? Perhaps implement the same use of DTR and RTS for the V51 as was the case for the C51?

Any comments from those at ESA would be much appreciated!



Post Edited (06-07-06 09:12)

Andy Ayre

Assuming the DTR/RTS options in Flash Magic are either disabled or not visible...

When an application opens the COM port, Windows asserts DTR to indicate to whatever is connected that the COM port is open. Hence the name "Data Terminal Ready". The best that could be done in Flash Magic would be to deassert DTR after opening, but this would mean a pulse on DTR and I'm sure other users would not be happy with that.

I think that unfortunately this is a side effect of doubling up the use of COM port signals for another use.

Embedded Systems Academy, Inc.
support at esacademy dot com

phonoplug

"Assuming the DTR/RTS options in Flash Magic are either disabled or not visible..."

Have I missed something here? I cant find any DTR/RTS options when set to 'V51RD2. The Hardware config page under advanced options page is blank, but this is where that stuff is for the 'C51RD2.

Just wondering because these lines were used for programming the C51, whether they could do a similar job when programming the V51? For the C51 they could be turned off so I guess that could also be done for the V51?

Andy Ayre

Embedded Systems Academy, Inc.
support at esacademy dot com

Jan Waclawek

This sounds similar than my question here a few days ago. Fortunately, the status quo suited my purpose well; but I investigated this a little bit then, and now I am uncertain: couldn't this be solved somehow by using the commandline version of FM (using the HARDWARE option)?

Jan Waclawek

phonoplug

Thanks Jan, I have been looking at using the command line version, however....

Is the 89V51 supported in the command line version? As far as I can tell it doesnt seem to be.

Andrew - is this correct? Are there any plans to support it in command line version?

Jan Waclawek

Alex, you are right, sorry. I haven't really tried, just had a look at it... But Andy recently published a "hack" here: http://www.esacademy.com/software/flashmagic/forum/read.php?f=1&i=2815&t=2815

Other - maybe stupid, too - thing came into my mind, couldn't you simply cut the DTR line in the cable?

Jan Waclawek

phonoplug

Aaaha, sounded like that hack would be just the job, but... it no longer works! using a negative oscillator frequency gives:

ERROR: Invalid parameters for DEVICE directive: DEVICE(89C51RD2xx,-1)

I see from the other thread Andy says 'using DTR and RTS are still on the to-do list' so I can stay in hope that its not too far down the list :thumbsup:

Andy Ayre

Embedded Systems Academy, Inc.
support at esacademy dot com

Andy Ayre

Try this:

DEVICE(89C51RD2Hxx, -1.000)

I think that you need the decimal point for the value to be recognized as a floating point number.

Embedded Systems Academy, Inc.
support at esacademy dot com

Jan Waclawek

> Try this:
>
> DEVICE(89C51RD2Hxx, -1.000)

Now THIS is something I call a HACK !!!  :)

JW



Post Edited (06-09-06 01:57)

rik

HI

With all informations I have found, I was finaly able to program a P89V51RC2FA by selecting 89C51RX2XX but only in 12clock mode.

It seems that 6clock mode option is not working.

Does anybody knows why?

Rik