Searching \ for '[PIC]: ICD-2 and 18xxx' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page:
Search entire site for: 'ICD-2 and 18xxx'.

Exact match. Not showing close matches.
PICList Thread
'[PIC]: ICD-2 and 18xxx'
2002\04\25@220722 by Barry Gershenfeld

picon face
I've got a new 18F252, a 16-bit C compiler, version 5.61 of MPLAB,
and the new ICD-2 to run it all with.  But I've got problems.  And
too many questions to fit in that little text box on the mChip
web board.

The most egregious problem is that I can't get it to recognize the
debug code.  After a programming run, it will verify the program,
verify the config bits, and fail trying to verify the ICD debug code.

The second thing is that I can't (usually) turn off the debug
code, program it, disconnect and run it.  This works maybe 2%
of the time.  It's as if the chip doesn't run.  So I'm wondering
if the ICD program and verify can work without the chip running,
while the ICD debug needs a running chip.

I've checked, and I've got power, ground, a good reset from
a reset controller, and a clock oscillator that drives OSC1
and I can see it coming back out on OSC2.  I assume that
with external drive I can use any setting (I'm using HS,
and it's 7 MHz).

For my last question, I'm not used to looking at the code
for this 16-bit stuff.  I'm looking for that NOOP that's
supposed to be in the first location.  The "ROM" window
shows me this:

0000  EF1A          GOTO
0002  F000          (nop) Main

Looks like almost-maybe-but-not-quite a noop there.  Now, I
just set up an assembler project to try to get control of
this sort of thing, and I find I get the identical thing
with the assembly program...  Hmm, goto F000 ?  there's
something going on here.  Time to do some more reading.


-- Going offline? Don't AutoReply us!
email with SET PICList DIGEST in the body

2002\04\25@230114 by Bob Ammerman

picon face

On the 18F GOTO and CALL and LFSR are all two word instructions.

The second word of all these instructions is alawys in the form 0xF???

If the processor encouters this second word where it is expecting the start
of an instruction, it will treat it as a no-op.

This is useful when you want to do something like:

   BTFSS    someerg,somebit
   GOTO    someplace

Note that if the skip happens, it will be right into the middle of the GOTO
instruction. However, that will be OK because the second half of the GOTO
starts with 0xF, so it will be treated as a no-op.

Bob Ammerman
RAm Systems

{Original Message removed}

2002\04\26@133146 by Barry Gershenfeld

picon face
>On the 18F GOTO and CALL and LFSR are all two word instructions.

For a minute I though we had a Linear Feedback Shift Register in
there!  Oh, it's just "load FSR".

>The second word of all these instructions is alawys in the form 0xF???

Ok, I get it.

The question remains--Should I see NOP as the first instruction? Either
the ICD/debug entry method has changed, or I've got a possible cause
for my problem.  (Though not why it won't run standalone).


-- hint: To leave the PICList

More... (looser matching)
- Last day of these posts
- In 2002 , 2003 only
- Today
- New search...