When waking from sleep without interrupts enabled, the PIC will execute the instruction after sleep. I recommend a GOTO the line" MOVLW 1"
The failure to program after build got me as well. Wasted a hell of a lot of time. The Microchip tech support was very helpful, and I'm still looking for the knee spanner, to rotate my knee 180 degrees and kick my own arse around the shack.
16F84 and 16F84A are firmware compatable, they do require different programming algorithms. The ICD2 won't program the non A 16F84
Try to get your hands on a 16F88, or a 16F877A, both support the debugger mode which is an great way to learn the inner workings of a PIC. The old 877A has tons of software including many compilers.
They were free... And i didn't know what to get when i ordered the free samples. I will request some 16f88's on my next free sample order from Microchip.
The faulty logic that lead to Mark's selection may have been along these lines.
The net seems to be full of project using the 16F84, that would be a good choice.
The 12f683 only has 8 pins. That sounds simple to use. Maybe good to learn on. Get a few of these.
All wrong
The 16F88 is a good choice.
Once you get past the tutorial stuff you should also get some 28 pin PICS. Lots of choices here. Better to use the 18F family. The price is very close and they have more memory. etc This has been discussed in other threads.
The faulty logic that lead to Mark's selection may have been along these lines.
The net seems to be full of project using the 16F84, that would be a good choice.
The 12f683 only has 8 pins. That sounds simple to use. Maybe good to learn on. Get a few of these.
All wrong
The 16F88 is a good choice.
Once you get past the tutorial stuff you should also get some 28 pin PICS. Lots of choices here. Better to use the 18F family. The price is very close and they have more memory. etc This has been discussed in other threads.
Go back in time and tell me that. Actually, the reason i chose the 16f84 is because of that tutorial. I read through it a bit before i got started with pics, and decided that would be best for free.
Go back in time and tell me that. Actually, the reason i chose the 16f84 is because of that tutorial. I read through it a bit before i got started with pics, and decided that would be best for free.
Looks like I missed the boat on that one. It was a bit difficult to figure out exactly what to do/say/send.
It looks like the only PICs you have that work the the debugger are the 877 and 877A's.
You can switch to one of them once you are up to setting your own config. Not difficult given that most anyone here can help you with that. But then you are going to need a crystal/caps or ceramic oscillator.
I'd start with the 16F88 or 16F886 (both have the internal clocks much easier to use than adding an external clock)
Then when I've got your head wrapped around one of those look at the 18F2525 (you can use it as a 16F886 substitute). It's so packed with features that it's hard to recommend as a starter chip (although the general lack of bank switching makes it tempting) But an excellent chip all around for 28pins.
Avoid the wee 8 pins for learning.
I'll be using the LCD 16F917 in the thermostat as the LCD hardware makes it easy.
Edit, the 887 are the "modern" 877A replacement. Very nice chips all around.
Great thread! I just got an ICD2 recently and some 16F88s are in the mail (expected later this week).
Bill: The reference to the 16F88 in your "Hello World" tutorial - will that code work generally with the 16F88, or is it specific to the Firefly? I'm just wondering what I'd have to do to get an LED blinking using the 16F88's internal oscillator. Thanks.
And thanks, Mark256, for working your way out of a trap I would've undoubtedly fallen into!