P89V51RD2 Problem

Started by jcabral, January 15, 2008, 02:33:21 PM

Previous topic - Next topic

Jan Waclawek

#15
And did using the DC power separate from USB alleviate your problems?
---
I don't quite understand what you mean "the bootloader destroys itself". Please comment.

JW

jcabral

Quote from: Jan Waclawek on January 23, 2008, 12:18:01 AM
And did using the DC power separate from USB alleviate your problems?
---
I don't quite understand what you mean "the bootloader destroys itself". Please comment.

JW

A separate DC power doesn't solve the problem, in order to work I have to make changes to the development board: include a reset to the FTDI chip or include a oscillator based on an external crystal.

The bootloader has code in "user" program memory ... that code deletes itself after determining the baud rate, it does it very well from any garbage generated from the FTDI ... if the chip gets garbage from the serial port or Vdd is not 5.0V, that portion of code is deleted and a parallel programmer is required to recover. Furthermore bootloader v7 is only available for ISP upgrade, only v5 is available from NXP site.
What I will do asap is to modify the bootloader in order to be able to use 40 chips, or redesign a smaller development board with standard RS-232.
For the boards that I have now, and still intend to use (we have around 150 of these), I will buy parts from other manufacturer.

I attached the schematic of the circuit.

Regards,
JCabral

erikm

I have been looking for other manufacturers and I found that some have new bootloaders similar to this one, but they still keep the hardware ISP entry mode.

I am a great fan of the no hardware ISP entry mode (I created NoTouch for that reason) and think that Philips did very well with the ISP design of the V chips. However that seems not to be the case for some others so NXP had to come out with the VC series that have hardware ISP entry mode.

SO, if you prefer hardware ISP entry mode get a VC chip, they are supposedly identical to the C (non -H) series re ISP.

Erik
erik

Jan Waclawek

Quote from: jcabral on January 23, 2008, 10:03:47 AM
The bootloader has code in "user" program memory ... that code deletes itself after determining the baud rate, it does it very well from any garbage generated from the FTDI ... if the chip gets garbage from the serial port or Vdd is not 5.0V, that portion of code is deleted and a parallel programmer is required to recover.
The bootloader does not delete itself, nor does it have code in the "user" (application, Block0) FLASH. It is only the bootloader updater (from whichever to version 7) which is programmed into the application FLASH and, after having updated the boot FLASH, it erases itself. But that does not happen before it verifies the new bootloader to be programmed all OK.

However, with erratic power I can imagine any possible scenario. You need to fix that first.

Quote from: jcabral on January 23, 2008, 10:03:47 AMFurthermore bootloader v7 is only available for ISP upgrade, only v5 is available from NXP site.
If you want to program the v7 bootloader in parallel programmer, simply take the updater as downloaded, take out the 0000-1FFF part off it, set the first 3 bytes to zero, and "burn" this into the boot FLASH. Note however, that in this way you will destroy the SoftICE code (the v5 bootloader programmed in parallel programmer into boot FLASH will do the same). If you want to preserve that, you need to read the boot FLASH first, store 0800-1EFF of it - that's the SoftICE part, concatenate it with 0000-07FF and 1F00-1FFF of v7 (zeroing the first three bytes), then program the whole back into the boot FLASH.

Quote from: jcabral on January 23, 2008, 10:03:47 AMWhat I will do asap is to modify the bootloader in order to be able to use 40 chips, or redesign a smaller development board with standard RS-232.
For the boards that I have now, and still intend to use (we have around 150 of these), I will buy parts from other manufacturer.

Just out of curiosity: Atmel AT89C51RD2/ED2?

Jan Waclawek

Andy Ayre

Note that the bootloader updater is designed to work with the corresponding feature in Flash Magic. Choose Update Bootloader from the ISP menu.

Andy
Embedded Systems Academy, Inc.
support at esacademy dot com

Jan Waclawek

Quote from: Andy Ayre on January 28, 2008, 07:34:25 AMNote that the bootloader updater is designed to work with the corresponding feature in Flash Magic. Choose Update Bootloader from the ISP menu

Hummmm... Does this meant that there is any sort of magic performed by FlashMagic, other than "burn" the updater as it would any other application, then run it and re-autobaud?

Jan Waclawek

Andy Ayre

No, but it's not necessary to modify the hex file so is a bit easier than using a parallel programmer.

Andy
Embedded Systems Academy, Inc.
support at esacademy dot com

Jan Waclawek

Quote from: Andy Ayre on January 28, 2008, 11:11:23 AM
No, but it's not necessary to modify the hex file so is a bit easier than using a parallel programmer.
Oh I see, thanks Andy.

Nevertheless it seems that some users do prefer parallel programming of the bootloader update, and possibly with the "bootloader entry on pin" option switched already on - I know it's beyond FlashMagic, it's just the defunct (or barely functional) NXP web and forum why these question gets asked here - there was an another separate thread about this topic recently.

Jan Waclawek