PDA

View Full Version : Feeling Noobish with 12F683



picster
- 17th October 2008, 17:42
Ok, this is getting to me.

very simple test program:


CMCON0=7 '00000111 - comparator pins configured as I/O
ANSEL=0 'all I/O is digital
OSCCON=96 'internal 4mhz clock 01100000
TRISIO=40 '101000

led var GPIO.4

CLEAR

start:

led=1
pause 500
led=0
pause 500
goto start


compiles fine (no duh)

Using pbp 2.46, the parallel EPIC PLUS programmer, ICSP harness... erases fine, confirmed blank.

I get a "code programming error at 0000"

Upon "verify", it shows the following message:

"Configuration verify error at 0000. 0FFF should be 00F4. Continue verifying?"
The rest verifies ok if I click YES.

I have verified that I can program a 16F88 right afterwards, with no issues.

What the heck ?

Any suggestions?

Bruce
- 17th October 2008, 19:33
Do you get the same error if you try programming the part in the EPIC DIP socket?

picster
- 17th October 2008, 19:55
Haven't tried it... I'll give it a shot and let you know.

Steve

picster
- 17th October 2008, 20:03
Same results in the ZIF socket and in the on-board socket.

Any other ideas? If the 16F88's wouldn't program, I'd at least have a pattern.

Also tried another 12F683, same result.

Steve

Bruce
- 17th October 2008, 22:29
Contact [email protected]

I'm sure they'll get you up & going.

mackrackit
- 17th October 2008, 22:30
Can you post your config seetings from the inc file and the generated hex from you compiler?

skimask
- 17th October 2008, 23:03
Same results in the ZIF socket and in the on-board socket.
Any other ideas? If the 16F88's wouldn't program, I'd at least have a pattern.
Also tried another 12F683, same result.
Steve

What version of software/firmware for the EPIC PLUS are you running?

picster
- 18th October 2008, 01:14
using meProg 3.30 - is there firmware for the Epic Plus parallel?

picster
- 18th October 2008, 01:24
Can you post your config seetings from the inc file and the generated hex from you compiler?

I use the config settings via meProg options, not in the file itself, and have them set as follows:

Oscillator: INTOSCIO
Watchdog Timer: Disabled
PowerUp Timer: Disabled
MCLR Pin Function: Reset
Brown-out Detect: Disabled
Internal External Switchover: Disabled
Fail-Safe Clock Monitor: Disabled
Code: Not Protected
Data EEPROM: Not Protected


Here's the hex generated:

:020000040000FA
:100000002E288001840AFF3E031D01282928A30110
:10001000A200FF30A207031CA307031C29280330FA
:10002000A100DF3015200928A101E83EA000A109A8
:10003000FC30031C1E28A00703181B28A00764001F
:10004000A10F1B2820182428A01C282800002828DD
:10005000080083130313831264000800073099001B
:1000600083169F0160308F00283085002030840087
:10007000603083120120A03084002030012005165A
:100080000130A300F430082005120130A300F43041
:0400900008203F28DD
:02400E00FC3F75
:00000001FF

Steve

Darrel Taylor
- 18th October 2008, 01:30
Do you have the program Configuration option checked?

http://www.pbpgroup.com/files/meProgConfig.JPG

Added: And since you are changing the configs manually, unchecking the Update Configuration From File option will make things easier. Won't help the current problem though.

mackrackit
- 18th October 2008, 02:28
I use the config settings via meProg options, not in the file itself, and have them set as follows:

Oscillator: INTOSCIO
Watchdog Timer: Disabled
PowerUp Timer: Disabled
MCLR Pin Function: Reset
Brown-out Detect: Disabled
Internal External Switchover: Disabled
Fail-Safe Clock Monitor: Disabled
Code: Not Protected
Data EEPROM: Not Protected

Here is what you hex says
<img src="http://www.picbasic.co.uk/forum/attachment.php?attachmentid=2914&stc=1&d=1224292884">
Almost matches. I do not have you setup. Is there a way with you programmer to set the fuses from the inc or in the code?

I am just guessing again :o

picster
- 18th October 2008, 14:29
Darrel,

I have the item you noted checked, and upload config from file UNchecked. I don't have "Program Fast" checked - but I doubt this would be the problem?

Maybe a bug in the 683 include file? Should I post it for comparison to yours? I haven't edited it or anything, but maybe it's a 2.46 undoc'd bug or something?

Steve

picster
- 18th October 2008, 14:38
Dave,

Not sure about how to set the fuses in code, I've always done it from the EPIC programmer's chip configuration settings window because it's simple.

I'm doing the PICBASIC in microcode studio - so if there's an easy way to set these switches there, I suppose I could try it (but right now I wouldn't know how).

Steve

mackrackit
- 18th October 2008, 14:49
Dave,

Not sure about how to set the fuses in code, I've always done it from the EPIC programmer's chip configuration settings window because it's simple.

I'm doing the PICBASIC in microcode studio - so if there's an easy way to set these switches there, I suppose I could try it (but right now I wouldn't know how).

Steve
This is the best explanation of how to set the fuses in code space.
http://www.picbasic.co.uk/forum/showthread.php?t=543
As usual, pay close attention to the post from Melanie and Mister-E.
Is there a way in the EPIC to turn that option off? I have not used the EPIC.

picster
- 18th October 2008, 15:54
I'm going to try installing the latest MPLAB IDE. I'm using it as the assembler. My current version is 7.3, so we'll see if the new one makes any difference.

Is there SOMEONE out there who can try my program on THEIR EPIC Plus with a '683 and see if it works for them?

Steve

picster
- 18th October 2008, 16:34
I'm going to try installing the latest MPLAB IDE. I'm using it as the assembler. My current version is 7.3, so we'll see if the new one makes any difference.

Is there SOMEONE out there who can try my program on THEIR EPIC Plus with a '683 and see if it works for them?

Steve

MPLAB updated, no change in the outcome. Still the same message.

Bruce
- 18th October 2008, 18:05
Try this. Insert the PIC in the EPIC DIP or ZIF socket. Start meProg software, select the
PIC12F683, then click "Get Target Information" under the Program menu.

Does it return "Target device matches selected device"?

Note: Try the onboard DIP socket if it doesn't work in the ZIF.

If yes then try this;

With your meProg software, place a check next to "all" options under the main "Options"
menu.

Under "More Options" place a check by "Configuration" in Program, Verify, Read and Erase.

If it still doesn't work, look in the help file for instructions showing how to test the output
voltage of both onboard regulators.

I haven't used the old parallel EPIC for years, but I had a similar problem that was fixed by
adjusting the potentiometer that sets Vpp.

Some PICs it would program fine. Others it wouldn't.

picster
- 19th October 2008, 21:06
Try this. Insert the PIC in the EPIC DIP or ZIF socket. Start meProg software, select the
PIC12F683, then click "Get Target Information" under the Program menu.

Does it return "Target device matches selected device"?

Note: Try the onboard DIP socket if it doesn't work in the ZIF.

If yes then try this;

With your meProg software, place a check next to "all" options under the main "Options"
menu.

Under "More Options" place a check by "Configuration" in Program, Verify, Read and Erase.

If it still doesn't work, look in the help file for instructions showing how to test the output
voltage of both onboard regulators.

I haven't used the old parallel EPIC for years, but I had a similar problem that was fixed by
adjusting the potentiometer that sets Vpp.

Some PICs it would program fine. Others it wouldn't.

1) In the onboard socket, it returns a match in device.

2) I still get the same error when I click the checkboxes as you suggest.

3) I checked the voltages as per the help file, and they're bang-on. Did you adjust the voltage upwards, or downwards from 13.5V when you adjusted your pot?

Steve

Bruce
- 19th October 2008, 22:34
Mine needed adjusting up.

picster
- 20th October 2008, 11:59
No luck. Adjusted the voltage up a bit, and down a bit. The only byte this seems to be writing is byte 0. Beyond that, it's all blank (03FF). Beats me why it's giving me the error message ABOUT location 0.

Again, other pics (well, my trusty 16F88's) program just fine.

Sent an email to MeLabs - if I get a resolve there, I'll post it in followup.

Steve

picster
- 16th November 2008, 21:17
Well, the MElabs folks suggested that I download the OLD version of the EPIC programmer software, version 2.46, from their website and try that to fix my problem. Lo and behold, it WORKED!!!

So if anyone else is having this issue, programming problems with the parallel EPIC programmer and the 12F683, this seems to be the fix.

picster