Author Topic: 89C664  (Read 5865 times)

KS Tan

  • Guest
89C664
« on: May 31, 2005, 08:39:49 pm »
I have problem using Flash Magic to program a 89C664.  I followed the document stated in the AN461 but no luck.  Can anyone help?

thanks,

Andy Ayre

  • ESAcademy Staff
  • Sr. Member
  • *****
  • Posts: 2190
    • View Profile
    • Embedded Systems Academy, Inc.
    • Email
Re: 89C664
« Reply #1 on: May 31, 2005, 10:08:47 pm »
Try working through the Flash Magic application note "What to do when ISP does not work" and let us know the results of the tests. We will then be in a better position to pinpoint the cause of the problem.

Are you pulling both P2.6 and P2.7 high while resetting into ISP mode?

Embedded Systems Academy, Inc.
support at esacademy dot com

KS Tan

  • Guest
Re: 89C664
« Reply #2 on: June 01, 2005, 02:14:34 am »
Hi Andy,
I have read thru' the application notes.  The fmd debug file as below:

debug> Short timeouts set to 4000 milliseconds
debug> Long timeouts set to 60000 milliseconds
debug> opened com 2
debug> hwconfig=3
debug> attempting to use baudrate 7200
debug> GetCommProperties - dwMaxTxQueue = 0 - no max size given
debug> GetCommProperties - dwMaxRxQueue = 0 - no max size given
debug> SetupComm successful. Configured txbufsize=16384,rxbufsize=16384
debug> comport configuration completed.
debug> RST asserted (DTR TTL = 0)
debug> PSEN asserted (RTS TTL = 0)
debug> COM Port RX flushed
debug> COM Port TX flushed
tx> U
debug> ReadFile - not enough or too many bytes read
debug> wanted 1 bytes, read 0 bytes
rx>
debug> Comport closed

Yes, I have 2.6, 2.7 pulled high, PSEN low, ALE High all conditions as specified by the AN461 but still cannot get to communicate with the device.

regards,

erikm

  • Guest
Re: 89C664
« Reply #3 on: June 01, 2005, 05:15:22 am »
did it communicate once?
If not in any way, the chip should still be "factory fresh" and thus already in ISP mode.
If so, and oscillator and reset is correct, it is the path PC - MAX232(equivalent) - uC that is your problem.

Erik

Andy Ayre

  • ESAcademy Staff
  • Sr. Member
  • *****
  • Posts: 2190
    • View Profile
    • Embedded Systems Academy, Inc.
    • Email
Re: 89C664
« Reply #4 on: June 01, 2005, 08:11:48 am »
Also test sending the 'U' with hyperterminal. That will narrow the problem down to the device/hardware or Flash Magic.

Embedded Systems Academy, Inc.
support at esacademy dot com

KS Tan

  • Guest
Re: 89C664
« Reply #5 on: June 03, 2005, 02:54:09 am »
Hi Erik,
The board I am using already have a MAX232 equivalent build in. Its ST202.  I followed the application specs stated http://www.st.com/stonline/prodpres/standard/interfc/st202_1.htm, with the AN461 notes, but still can't get it to communicate.

Hi Andy,
As explained above to Erik, I cannot get it to communicate, therefore, can't send a 'U' thru' hyperterminal.

regards,
KS

Andy Ayre

  • ESAcademy Staff
  • Sr. Member
  • *****
  • Posts: 2190
    • View Profile
    • Embedded Systems Academy, Inc.
    • Email
Re: 89C664
« Reply #6 on: June 03, 2005, 08:00:12 am »
Check with a scope to see if the 'U' you are sending in Hyperterminal is being received at RxD. If so is anything coming out of TxD?

If nothing at RxD - check your hardware, the path from the PC's COM Port to the RxD pin. Likewise if you see something coming out of TxD.

If the U is reaching RxD but nothing is coming out of TxD then you likely haven't satsified the requirements to get the device into ISP mode. Double check all voltages on pins and check for glitches, ripple, etc. with a scope. Check for a sine wave on the XTAL pins.

Embedded Systems Academy, Inc.
support at esacademy dot com