T O P I C R E V I E W |
BrunoR |
Posted - 07/01/2010 : 11:53:07 Hello,
I need to reprogram an old PIC16C84 and I have discovered that this chip is not listed in the device selection. I read somewhere else in this forum that one could edit the devicelist.txt file and add an entry for a new device based on existing device of the same class. I had a look at PIC16C73 and PIC16F84A entries in the file, but they look very different in terms of parameters and I don't know which would be required for a PIC16C84. Any hint? Thanks. |
2 L A T E S T R E P L I E S (Newest First) |
BrunoR |
Posted - 07/10/2010 : 07:41:22 quote: Originally posted by ZLM
You can try to use:
Name="PIC16C84",ID="XXXX",Class="PIC16F84A",Category="MCU",MFG="Microchip",ENDPRG_COMMAND="",SKIP_WRITE_BLANK="0",BEGERASECHIP_COMMAND="8",Speed="4";
But, the PIC16C84 is OTP chip, so it is costly to test chip. If you have a used chip with no code protect enabled, then try to write a few bytes each time, until compelted testing.
Thank you for your reply.
Actually, the PIC16C84 is not OTP as it has EEPROM program memory and could then be erased and reprogrammed. I think it should be considered as an early PIC16F84.
Anyway, I have added the line above into my devices.txt files and restarted USBPrg. PIC16C84 appeared in the list but once selected I got this error message :
Of course this pic16c84.dev file doesn't exists. After pressing OK, I have got the default user interface with PIC16C84 device selected. I checked the device information by clicking on the small "i" button, and this gave me this :
Definitively, something is wrong. The code and data sizes are incorrect. Voltages look OK.
I have created a new device file based on the PIC16F84A one and changed a few parameters. Now USBPrg doesn't complain about the missing file but parameters are still incorrect. What's wrong? Does USBPrg really reads parameters in the .dev file?
Here is my pic16c84.dev file:
# <!-- XML:Generated(2008-04-09 13:55:48.991000) -->
# <!-- XML:AnnotatedFile:Generated(2007-08-22 10:13:48.421000) -->
# Device file info: $Id: PIC16C84.ann,v 1.5 2007/10/12 16:17:28 charled Exp $
# Macro file info: $Id: PIC16C84.ann,v 1.5 2007/10/12 16:17:28 charled Exp $
format=0.1
#device=PIC16C84
vpp (range=12.000-14.000 dflt=13.000)
vdd (range=2.500-5.500 dfltrange=4.500-5.500 nominal=5.000)
pgming (memtech=ee tries=1)
wait (pgm=4000 eedata=4000 cfg=4000 userid=4000 erase=4000)
latches(pgm=1 eedata=1 userid=1 cfg=1)
# <!-- XML:Regions:Begin() -->
pgmmem (region=0x0-0x3ff)
testmem (region=0x2000-0x200f)
userid (region=0x2000-0x2003)
cfgmem (region=0x2007-0x2007)
eedata (region=0x0-0x3f)
# <!-- XML:Regions:End() -->
# <!-- XML:SFRs:Begin() -->
sfr (key=INDF addr=0x0 size=1 flags=i access='u u u u u u u u')
reset (por='--------' mclr='--------')
bit (names='INDF' width='8')
sfr (key=TMR0 addr=0x1 size=1 access='rw rw rw rw rw rw rw rw')
reset (por='xxxxxxxx' mclr='uuuuuuuu')
bit (names='TMR0' width='8')
stimulus (scl=rwb pcfiles=w regfiles=w type=int)
sfr (key=PCL addr=0x2 size=1 access='rw rw rw rw rw rw rw rw')
reset (por='00000000' mclr='00000000')
bit (names='PCL' width='8')
stimulus (scl=rwb pcfiles=rw regfiles=w)
sfr (key=STATUS addr=0x3 size=1 access='rw rw rw r r rw rw rw')
reset (por='00011xxx' mclr='000qquuu')
bit (names='IRP RP nTO nPD Z DC C' width='1 2 1 1 1 1 1')
sfr (key=FSR addr=0x4 size=1 access='rw rw rw rw rw rw rw rw')
reset (por='xxxxxxxx' mclr='uuuuuuuu')
bit (names='FSR' width='8')
stimulus (scl=rwb pcfiles=rw regfiles=w type=int)
sfr (key=PORTA addr=0x5 size=1 access='u u u rw rw rw rw rw')
reset (por='---xxxxx' mclr='---uuuuu')
bit (names='- - - RA4 RA3 RA2 RA1 RA0' width='1 1 1 1 1 1 1 1')
bit (tag=scl names='RA' width='8')
stimulus (scl=rwb pcfiles=rw regfiles=rw)
sfr (key=PORTB addr=0x6 size=1 access='rw rw rw rw rw rw rw rw')
reset (por='xxxxxxxx' mclr='uuuuuuuu')
bit (names='RB7 RB6 RB5 RB4 RB3 RB2 RB1 RB0' width='1 1 1 1 1 1 1 1')
bit (tag=scl names='RB' width='8')
stimulus (scl=rwb pcfiles=rw regfiles=rw)
sfr (key=EEDATA addr=0x8 size=1 access='rw rw rw rw rw rw rw rw')
reset (por='xxxxxxxx' mclr='uuuuuuuu')
bit (names='EEDATA' width='8')
stimulus (scl=rwb pcfiles=rw regfiles=rw)
sfr (key=EEADR addr=0x9 size=1 access='rw rw rw rw rw rw rw rw')
reset (por='xxxxxxxx' mclr='uuuuuuuu')
bit (names='EEADR' width='8')
stimulus (scl=rwb pcfiles=rw regfiles=w)
sfr (key=PCLATH addr=0xa size=1 access='u u u rw rw rw rw rw')
reset (por='---00000' mclr='---00000')
bit (names='- - - PCLATH' width='1 1 1 5')
stimulus (scl=rwb pcfiles=rw regfiles=w type=int)
sfr (key=INTCON addr=0xb size=1 access='rw rw rw rw rw rw rw rw')
reset (por='0000000x' mclr='0000000u')
bit (names='GIE EEIE T0IE INTE RBIE T0IF INTF RBIF' width='1 1 1 1 1 1 1 1')
stimulus (scl=rwb pcfiles=rw regfiles=w)
sfr (key=OPTION_REG addr=0x81 size=1 access='rw rw rw rw rw rw rw rw')
reset (por='11111111' mclr='11111111')
bit (names='nRBPU INTEDG T0CS T0SE PSA PS' width='1 1 1 1 1 3')
stimulus (scl=rwb regfiles=w)
sfr (key=TRISA addr=0x85 size=1 access='u u u rw rw rw rw rw')
reset (por='---11111' mclr='---11111')
bit (names='- - - TRISA4 TRISA3 TRISA2 TRISA1 TRISA0' width='1 1 1 1 1 1 1 1')
bit (tag=scl names='TRISA' width='8')
stimulus (scl=rwb regfiles=w)
sfr (key=TRISB addr=0x86 size=1 access='rw rw rw rw rw rw rw rw')
reset (por='11111111' mclr='11111111')
bit (names='TRISB7 TRISB6 TRISB5 TRISB4 TRISB3 TRISB2 TRISB1 TRISB0' width='1 1 1 1 1 1 1 1')
bit (tag=scl names='TRISB' width='8')
stimulus (scl=rwb regfiles=w)
sfr (key=EECON1 addr=0x88 size=1 access='u u u rw rw rw rs rs')
reset (por='---0x000' mclr='---0q000')
bit (names='- - - EEIF WRERR WREN WR RD' width='1 1 1 1 1 1 1 1')
stimulus (scl=rwb pcfiles=rw regfiles=w)
sfr (key=EECON2 addr=0x89 size=1 access='w w w w w w w w')
reset (por='--------' mclr='--------')
bit (names='EECON2' width='8')
# <!-- XML:SFRs:End() -->
NumBanks=2
NumHWBP=1 #Added for hardware break point May 23rd,2007
MirrorRegs (0x0-0x0 0x80-0x80)
MirrorRegs (0x02-0x04 0x82-0x84)
MirrorRegs (0x0a-0x2f 0x8a-0xaf)
UnusedRegs (0x7-0x7)
UnusedRegs (0x30-0x7f)
UnusedRegs (0x87-0x87)
UnusedRegs (0xb0-0xff)
# <!-- XML:DCRs:Begin() -->
cfgbits (key=CONFIG addr=0x2007 unused=0x0)
field (key=OSC mask=0x3 desc="Oscillator")
setting (req=0x3 value=0x3 desc="RC")
setting (req=0x3 value=0x0 desc="LP")
setting (req=0x3 value=0x1 desc="XT")
setting (req=0x3 value=0x2 desc="HS")
field (key=WDT mask=0x4 desc="Watchdog Timer")
setting (req=0x4 value=0x4 desc="On")
setting (req=0x4 value=0x0 desc="Off")
field (key=PUT mask=0x8 desc="Power Up Timer")
setting (req=0x8 value=0x8 desc="On")
setting (req=0x8 value=0x0 desc="Off")
field (key=CP mask=0x3ff0 desc="Code Protect")
setting (req=0x3ff0 value=0x3ff0 desc="Off")
checksum (type=0x0 protregion=0x0-0x0)
setting (req=0x3ff0 value=0x3fe0 desc="On")
checksum (type=0x20 protregion=0x0-0x3ff)
# <!-- XML:DCRs:End() -->
|
ZLM |
Posted - 07/06/2010 : 13:49:51 You can try to use:
Name="PIC16C84",ID="XXXX",Class="PIC16F84A",Category="MCU",MFG="Microchip",ENDPRG_COMMAND="",SKIP_WRITE_BLANK="0",BEGERASECHIP_COMMAND="8",Speed="4";
But, the PIC16C84 is OTP chip, so it is costly to test chip. If you have a used chip with no code protect enabled, then try to write a few bytes each time, until compelted testing. |
|
|