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.

Question about the PIC chip lineup

Status
Not open for further replies.

mramos1

Active Member
I am asking all of these questions to save me hours of research, and thanks for any help in advance (and time spent).

I have been using Atmels for years now, and they work great. I see the PIC has changed since the 16F84 (I get yelled at everytime I mention them).. I switched for ATMEL mainly because of the the internal OSC and the lower price. How does the PIC line stand up now? I also had a free basic compiler, but support is slowing down on the compiler (as it is free). Also, most ATMELs run from 2-3 volts to 6 volts, and low power consumption. But it
sounds like MicroChip learned and maybe caught up or passed ATMEL. I know the Atmels are faster internally, but speed is not an issue for my projects.

Questions:

1) I have an old MELABS PICBASIC (version 2 range I think), will the 16F84 .hex file run (minus extra functions of course), or do I need to get a newer compiler? I pulled a Proton BASIC that looks promising (did not look at the price yet). I will pull MPLAB as well, as the PIC ASM is a lot easier than the Atmel ASM was for me.

2) What is the closest chip to the 16F84, the 16F624a?

3) Can I use the picall or was it pic40all programmer, as my EPIC died a long time ago, to program the new chips (are pinouts and protocols the same)?

4) what is the best free BASIC (if any)? I looked at BoostBASIC, and the docs were weak?

5) If I need a new programmer, what is the best simple (single sided) one out there as I can make boards (if one exists)?

Thanks for any input, Microchip might win me back.
 
mramos1 said:
I am asking all of these questions to save me hours of research, and thanks for any help in advance (and time spent).

I have been using Atmels for years now, and they work great. I see the PIC has changed since the 16F84 (I get yelled at everytime I mention them).. I switched for ATMEL mainly because of the the internal OSC and the lower price. How does the PIC line stand up now? I also had a free basic compiler, but support is slowing down on the compiler (as it is free). Also, most ATMELs run from 2-3 volts to 6 volts, and low power consumption. But it
sounds like MicroChip learned and maybe caught up or passed ATMEL. I know the Atmels are faster internally, but speed is not an issue for my projects.

Questions:

1) I have an old MELABS PICBASIC (version 2 range I think), will the 16F84 .hex file run (minus extra functions of course), or do I need to get a newer compiler? I pulled a Proton BASIC that looks promising (did not look at the price yet). I will pull MPLAB as well, as the PIC ASM is a lot easier than the Atmel ASM was for me.

The 16F628 is very similar to the 16F84, with only very minor differences (basically improvements) - but you would need to slightly alter the code produced by an F84 compiler to make it run.

But PIC assembler is easy to learn anyway.

2) What is the closest chip to the 16F84, the 16F624a?

The 16F84 was replaced by the 16F628 last century, inturn the 16F628 has been replaced by the 16F628A (which is just a later silicon revision).

3) Can I use the picall or was it pic40all programmer, as my EPIC died a long time ago, to program the new chips (are pinouts and protocols the same)?

Pinouts have remained the same, but the programming software has changed, there are many (certainly in the teens) different programming algorithms used.

4) what is the best free BASIC (if any)? I looked at BoostBASIC, and the docs were weak?

5) If I need a new programmer, what is the best simple (single sided) one out there as I can make boards (if one exists)?

Free BASIC's are usually limited, a popular programmer these days is ICD2 clones - which work directly from MPLAB.
 
Even though you have been given awesome advice, I would add:
that the 10Fxxx pics which have a very good internal osc, can be had for about fifty cents. (I switched for ATMEL mainly because of the the internal OSC and the lower price.)

PICs come in a great range - from the tiny 6pin SOT-23 10Fxxxs all the way up to the 16bit DSPs. They have micros with a great range of peripherals.

One thing I really don't like about AVRs, is that if you program the configuration wrong, it is a real headache to save your chip. This doesn't happen in PICs.

I really agree with Nigel; the ICD2, or clones (less than $50) are the way to go. They will program all of microchip's parts, and they work very well, right out of MP lab.

The small instruction set makes learning assembly fairly easy, and you could stick with that. If you want a high level language, Microchip provides a (virtually free) C compiler for the 18F series. The only limitation in the student version, is that after some time, optomization is limited. There are other compilers you can use, some in demo, or free mode, and others very cheap, CC5X, for example. I'm sure you could find a free, or cheap BASIC compiler out there.
Hope this helps,
Robert
 
BeeBop said:
Even though you have been given awesome advice, I would add:
that the 10Fxxx pics which have a very good internal osc, can be had for about fifty cents. (I switched for ATMEL mainly because of the the internal OSC and the lower price.)

Well, to be honest, the AVR Tiny11 is what has me upset with Atmel, it is an old chip but 50 cents. I bought 3 and I wasted 2 of the 3 because their default is to burn and lock the chip (yea, wasted 2 before I checked, the other chips to not do that). I was not happy that was their default. I EMAILed ATMEL, since I can not talk to them, and no response. Then I thought, maybe it is time to look at the PIC again, as I see low current and internal OSC. Now, I hear from you, 50 cents for 8 pin PICS as well. But that is what made me look at the old Tiny11, the low price.

PICs come in a great range - from the tiny 6pin SOT-23 10Fxxxs all the way up to the 16bit DSPs. They have micros with a great range of peripherals.

I saw DSP and USB PIC awhile back that peaked my interest, though I have no need for it right now. But it could be something to add on a digikey/mouser order, just to play with.

One thing I really don't like about AVRs, is that if you program the configuration wrong, it is a real headache to save your chip. This doesn't happen in PICs.

That is what prompted my post/topic. And no EMAILs back from Atmel. I will not go in the AVRFREAKS forums to talk to people that do not know what the Tiny11 is.

I really agree with Nigel; the ICD2, or clones (less than $50) are the way to go. They will program all of microchip's parts, and they work very well, right out of MP lab.

Yea, on break today I went looking for a basic compiler as I do not want to spend a lot on a compiler and programmer when I have no project to pay me back.

I will look at the ICD2 for sure. Nigel is 99.99998888111% (they are not exact numbers on Nigel, but close most of the time) always on target in my books. And I will pull MPLAB as I did not mind ASM on the PIC (pretty simple. like 32 commands). I have a friend that wrote RVKBASIC so I went the BASIC way. And it is fast and simple for small stuff.. So thought I would look for a free basic. I found a couple. One looked good. Proton (I have not looked at their price. Funny, with me, if it is more that $99, I like assembler).

The small instruction set makes learning assembly fairly easy, and you could stick with that. If you want a high level language, Microchip provides a (virtually free) C compiler for the 18F series. The only limitation in the student version, is that after some time, optomization is limited. There are other compilers you can use, some in demo, or free mode, and others very cheap, CC5X, for example. I'm sure you could find a free, or cheap BASIC compiler out there.

Oh, assembler is not a problem, I taught x86 many years ago (at my job, used from the moto6800 to 680xx (HC11 is nice), intel 8031 to 32bit chip, TI, 8080, 6502, etc, etc), and really think motorola is the best assembler just takes more time if I want to flip a couple bits at a certain time/freq (why I like basic). My first non-work releated project in 1981, was a single keystroke version of command.com (the MSDOS shell). I rewrote command.com in 3 weeks it was 11K (ExecuDIR, later called MasterDOS). But as we age, high level (like basic) is good. I think C is in the middle of the two, so I always use assember over C anytime (same work for me and a faster more acurate program (I can see Nigel with a big smile). If you use C, IMHO, you are missing out on assembler. But basic is like a macro level language for these little powerful chips.

Anyway. Thanks for the input. Will look at (buy) the programmer and pull MPLAB tomorrow. And order some 16F628a (I think it was, will check before I order and probably some 10F508 chips too).
 
Last edited:
Hi again,
Yes, I am a bit intimidated, posting after Nigel. He is on, almost always!

I saw DSP and USB PIC awhile back that peaked my interest, though I have no need for it right now. But it could be something to add on a digikey/mouser order, just to play with.

I'm not really ready for the dsp either, but when I saw this board for $37, I couldn't help myself, and ordered one.https://www.futurlec.com/dsPIC30F2010_Board.shtml I have no business, but I'll give it a try!

Yes, I use C because it's faster for me, but lately have been doing some projects in assembly, because it is a much better way to really understand these chips.

I was put off everything Atmel, because when I first started with micros, I got a kit with an 89c4051. The PC application to burn the chip wouldn't run on my PC, because I didn't have Hangul (Korean typeface) installed on my PC. I tried various other programmers, etc, all with no joy. Then I got onto PICs, which seemed painless, and easy. Since, I have done a couple of things with AVRs, which seem easier than the '51, but I like using the PIC best.

I paid a lot (about 200 USD!) for my ICD2. It was built under license of Microchip, by Comfile, a Korean company. I know now, I could order from Microchip for half that, but SparkFun sells the Olimex clones a lot cheaper. I think the ICD2 is great!, and never look back at what I spent on it.

About the little chips: I got a bunch of 10F206s in 8 pin DIP package to play with. I think I paid about a dollar each. When I first connected to my board, I seem to have lost the oscillator calibration value, even though I didn't write to the chip! Too early to say, because right after that I had to rush off to work. I'm going back to that project when I finish reading here, so more on that later. They are a nice little chip, though. 512 bytes of flash, 24 bytes of RAM, 3 I/O pins, and you can use MCLR as an input. The chips have one timer and one comparator, pull ups on the pins, and can be programmed in circuit. The 4 MHz osc should be precise enough to do serial with.

Oh, have a look at SparkFun's site:
https://www.sparkfun.com/commerce/categories.php They have the ICD2 clones at good prices, as well as many other things of interest.

Best wishes,
Robert
 
I am a big proponent of just about all ICD2 clones. I have been using the full USB Olimex clone for over 2 years now without any problems programming everything from the 10F devices through dsPICs. You can get them for about $100. They also make an RS232 only version that is in the $50 range. If you search around on Google, there are instructions on how to build your own ICD2 clone but you will need a stand alone PIC programmer to install the bootloader onto it. These can be built for less than $10 in some cases.

The ICD2 is the best programming platform for the hobbiest PIC developer (and any business that can't afford an ICE) at the moment.

Hey BeeBop, the dsPIC is not hard to develop with. A few of the hurdles I faced was how to locate code in memory and how to make use of all the new instructions. Luckily there are code templates included with MPLAB which clarified a number of issues I was having. Also, when you are used to working with a single Wreg and limited instructions, it is somewhat difficult to find ways of taking advantage of all the new features the dsPIC offers.

-Bill
 
BeeBop and Phalanx,

Thanks for the input. Looks like that answers all the questions. I have a 16PIC40PRO or something like that. It is parallel uni, and I use it on a laptop with Win98 so no IO problems. Looks like it is time to upgrade. Now what do I do with all these 16F84 I have (just kidding).

Off to get MPLAB and look for the programmer.
 
mramos1 said:
BeeBop and Phalanx,

Thanks for the input. Looks like that answers all the questions. I have a 16PIC40PRO or something like that. It is parallel uni, and I use it on a laptop with Win98 so no IO problems. Looks like it is time to upgrade. Now what do I do with all these 16F84 I have (just kidding).

I presume you mean a P16PRO40?, it's a classic PIC programmer and suitable for the vast majority of PIC's, just depending on the software used.
 
Nigel Goodwin said:
I presume you mean a P16PRO40?, it's a classic PIC programmer and suitable for the vast majority of PIC's, just depending on the software used.

That is the one I have. Can I use that? I am stuck between the Olimex ICD2 (it has realtime debugging) and the Presto (does a lot of chips), as I can still do most of the Atmels as well. Does the ICD2 allow realtime in-circuit debugging, like ICE, where I can break and step?

But I have the P16PRO40 and the Atmel STK500, rather spend the money on a
compiler. The P16PRO40 is a parallel unit, what software to you recommend? If it will do the 10Fxxx, 12F508/9 and the 16F628a, that would cover most of my projects.
 
Last edited:
mramos1 said:
The P16PRO40 is a parallel unit, what software to you recommend? If it will do the 10Fxxx, 12F508/9 and the 16F628a, that would cover most of my projects.

The P16PRO40 is basically an improved David Tait design, WinPicprog (my software will drive it), as will IC-Prog, and presumably WinPic will as well?.


Mine supports the 16F628A, but not the others, I suggest you check on the other programmer websites?. The 10Fxxx is likely to be a problem, as it's SM only, so hard to fit in a ZIF socket :p
 
Nigel Goodwin said:
The 10Fxxx is likely to be a problem, as it's SM only, so hard to fit in a ZIF socket :p

No it is not. 10Fs are also available in 8pin DIP package (with two pins as NC), so this is not a good excuse for not implementing them into your Programing SW.:p
 
Jay.slovak said:
No it is not. 10Fs are also available in 8pin DIP package (with two pins as NC), so this is not a good excuse for not implementing them into your Programing SW.:p

There goes another excuse!


However, if it's in the same 8 pin package you may as well use a 12Fxxx instead :)
 
Nigel Goodwin said:
... you may as well use a 12Fxxx instead :)

Well, I would use DIP for developing (and pragrammer support :) )and SMD for production. Seems pretty simple to me. :eek:
And you can't fit 12F everywhere 10F in SOT-223 fits.
 
Along the same vein...

Lots of talk about the ICD2-type debugger/programmers. I've been eyeing the Olimex clone over at SparkFun, but $100 is a bit intimidating since I'm just getting started.

As someone who wants to start learning, and hasn't even touched a PIC yet, Is it worth my time and money to spend the money on the "good" programmer/debugger?

Thanks so much!
 
PDubya said:
As someone who wants to start learning, and hasn't even touched a PIC yet, Is it worth my time and money to spend the money on the "good" programmer/debugger?

Of course it is worth it! You can't imagine how hard it is to start when you have an untested/unreliable programer. Plus the Debuger feature is very usefull later on.
 
Another silly question - are there any software emmulators for PIC's? I think I saw something about "Proteus" giving you the ability to emmulate not only the pic, but attach virtual devices to do various testing.

Software seems the easiest way to get your feet wet without blowing up components ;). I've got a digikey order I've been holding off ordering as I'm not sure how many 16f628's I should order anticipating I'm probably going to hose some during the learning process. Any thoughts?
 
Personally, I would order a few just to experment with. The only way you would blow it up is if you put excessive voltages on it. If you take precautions, that should not be a problem.
 
PDubya said:
Another silly question - are there any software emmulators for PIC's? I think I saw something about "Proteus" giving you the ability to emmulate not only the pic, but attach virtual devices to do various testing.

Software seems the easiest way to get your feet wet without blowing up components ;). I've got a digikey order I've been holding off ordering as I'm not sure how many 16f628's I should order anticipating I'm probably going to hose some during the learning process. Any thoughts?

MPLAB includes a simulator as well as an assembler, but I never use it anyway (or even MPLAB), I just use the assembler part of MPLAB, MPASM.

PIC's are extremely hardy devices, I've never managed to kill one yet :p

Although I do have one that got so hot it's got my fingerprint burn in it's top, so don't put them in the wrong way round! - or if you do, don't test it with your finger!. It still works perfectly though! - the finger as well (at least as well as it did before, it wasn't 100% from a previous 'incident').
 
Status
Not open for further replies.

Latest threads

Back
Top