Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

PIC16F84 Queries

Status
Not open for further replies.

vicgray

New Member
Hi! I am doing a project and am having headaches.

I am doing a heartbeat monitor using **broken link removed**

1. Is there any difference between PIC16F84 and PIC16F84A?

2. I heard that the source code for PIC16F84 cannot be programmed to PIC16F84A. It will not work. Is that true?

3. The circuit is using PIC16F84-10/P. However, I am only using a 4MHz crystal in the circuit. Can I use PIC16F84-04/P?

Please advise! Thanks!
 
If you havent ordered your pics yet , i would suggest a newer PIC ..perhaps one with a built in A/D converter..and a built in oscillator..
the difference between an F84 & an F84A is so slight..
the code is definatly compatible, yes..
 
Yes, though the difference between 84 and 84A is a little, but I have heard that they are note compatible with each other. But I have heard 84A is better.

I was using 84A instead of 84, and the circuit that was tested on protoboard just failed. I am now soldering it on the breadboard. hopefulle it would just be the misuse of PIC. And that by changing it back to 84 will do.

well, I don't know, cos I am an idiot.
 
vicgray said:
Hi! I am doing a project and am having headaches.

I am doing a heartbeat monitor using **broken link removed**

1. Is there any difference between PIC16F84 and PIC16F84A?

2. I heard that the source code for PIC16F84 cannot be programmed to PIC16F84A. It will not work. Is that true?

3. The circuit is using PIC16F84-10/P. However, I am only using a 4MHz crystal in the circuit. Can I use PIC16F84-04/P?

Please advise! Thanks!

The 84A was the old replacement for the 84 (just a later silicon revision), but both are long obselete!. You should really use a more modern PIC, the 16F628 was the replacement for the 84 series, and in turn is now replaced by the 16F628A (again, just a later silicon revision). There are also various other new compatible PIC's, some of which have inbuilt A2D - like the 16F819 and 16F88.

All of these are pin compatible with the 84 series, and the original code runs with only VERY slight changes - basically to account for the extra hardware in the newer devices. For example turning OFF the comparators in the 628, and turning OFF the analogue inputs on the others.

What you generally CAN'T do is load the original HEX files, you need to reassemble the source files with the slight changes, plus altering the include file name in the header, and the fuse settings - but it's all VERY simple.

If you check my tutorials you will see that the 628 ones all include two lines commented as 'make it like an 84', these turn off the comparators.

As well as the 628 being a better spec, it's also cheaper!, plus it includes an internal 4MHz oscillator - saving you adding the external crystal and capacitors. This is why I choose it for my tutorials, it's so much easier to use than the 84 (and saves money!).
 
vicgray said:
I am now soldering it on the breadboard. hopefulle it would just be the misuse of PIC.

If you are in the soldering phase, I would highly recommend soldering in a socket, as opposed to the actual chip. That way, if you ever need to reprogram it, you can pull it out of the circuit, reprogram it, and put it back in, very very easily. Use an 18 pin one (my picture is a 16 pin one, oh well :p).
 

Attachments

  • socket.jpg
    socket.jpg
    5.1 KB · Views: 2,114
Yes, I am using a port to insert the IC.

My concern is more on this:

3. The circuit is using PIC16F84-10/P. However, I am only using a 4MHz crystal in the circuit. Can I use PIC16F84-04/P?

While there is not much time for me to change the IC, I don't know PIC programming. so, I have to stick with the current one.

Thanks!
 
Yes, it will work fine. If you notice in the picture that is included in the ZIP file, he's even using a 4.000 MHz crystal. Since the PIC you're using is an 84, and his timing delays are actually written for 4 MHz instruction cycles, and you are running on a 4 MHz crystal, there's no problem at all. You shouldn't have to change a thing. Just compile it to a hex file and upload it to the PIC.
 
vicgray said:
3. The circuit is using PIC16F84-10/P. However, I am only using a 4MHz crystal in the circuit. Can I use PIC16F84-04/P?

There appears to be NO difference between PIC's with different speed ratings (except the price!) - presumably they all come off the same production line and are probably stamped 4 or 10 regardless?.

I've happily used 4MHz rated PIC's at 12MHz - with no ill effects at all. I never even look what it says on the PIC any more, they all seem quite happy at any speed.

As for running them slower, that's even less concern - PIC's will run right down to DC.
 
A lot of processors are assigned speed ratings during testing. They are all made in the same way but due to process variations some are better than others.
 
Thanks to all! Looks like I will go back to PIC16F84-04/P after all the advice given! Thanks again.

Now, if you notice the programs that it includes in the ZIP file, there are three seperate files:

1. hemon.asm
2. hemon.inc
3. reg16c84.inc

When I read the "hemon.asm", there are these lines of instruction:

Code:
include	"reg16c84.inc"	;register memory mapping file
	include "hemon.inc"	;heartbeat definitions

What does this mean?

Do I have to assemble these three files altogether to become one single file, and then only change it to HEX and flash it to the PIC16F84?

If yes, how do I use MPLAB to do that?

Thanks again!
 

Attachments

  • designguide.zip
    131.1 KB · Views: 423
So, as long as the MPLAB has verified the program, I would just need to flash the hemon.asm to the IC will do?
 
Oh yeah, forgot about it. HEX is the one I need. Well, I shall proceed with my project then. Thanks to all!
 
ive already build up the program and it was sucessful on MPLAB, but the problem is, the only output are 142, or 14... the only digits that been seen are 1, 2, and 4.. i simulate the program at PROTEUS.. can anyone help me? thanks alot...
 
hi all , i need some one to help me, i wanna understand the assembly code but i can not, and i also wanna the PCB circuit. plz help me
 
Working pic16f84a programmer

hi to all,
There are few steps to build correctly the pic progammer
**broken link removed**

Regards
 
Status
Not open for further replies.

Latest threads

Back
Top