PDA

View Full Version : Need some experienced advice



bill12780
- 7th June 2007, 17:43
Hello all,
This is my first post on this fine forum. I have been registered for some time and have been reading when I could in preperation of a up comming project.

A little about me...I am an Electroincs Technician by training but I work as a engineer because of my 20+ years of experience.

Its been MANY years ago that I first purchased PBP. I have played with it but never did any real development. I am also a Basic freak! I am VERY familar with writing programs for the PC in Basic.

My question is simple. There are literally HUNDREDS of different PIC chips out now. The project I have been asigned is a Keypad that controls a simple Motor controller circuit. So I don't need any fancy ADC or PWM features. What is a good solid chip that is cheap (comparable to the atmel chips) that will work for me.

Now I know this is a tall order. I am just hoping that someone off the top of their head has some advise on were to start on this.

Also, has anyone taken the course on Pbasic offered by RCG Research Inc? (I don't know if I can put a link here with out getting in trouble. So just google it you will find it.)

I would intrested to hear of anyone experience with them.

Thanks for any and all help....

Once I get my feet wet I will help as around here as much as I can.

Bill12780

skimask
- 7th June 2007, 17:46
Hello all,
This is my first post on this fine forum. I have been registered for some time and have been reading when I could in preperation of a up comming project.
A little about me...I am an Electroincs Technician by traning but I work as a engineer because of my 20+ years of experience.
Its been MANY years ago that I first purchased PBP. I have played with it but never did any real development. I am also a Basic freak! I am VERY familar with writing programs for the PC in Basic.
My question is simple. There are literally HUNDREDS of different PIC chips out now. The project I have been asigned is a Keypad that controls a simple Motor controller circuit. So I don't need any fancy ADC or PWM features. What is a good solid chip that is cheap (comparable to the atmel chips) that will work for me.
Now I know this is a tall order. I am just hoping that someone off the top of their head has some advise on were to start on this.
Also, has anyone taken the course on Pbasic offered by RCG Research Inc? (I don't know if I can put a link here with out getting in trouble. So just google it you will find it.)
I would intrested to hear of anyone experience with them.
Thanks for any and all help....
Once I get my feet wet I will help as around here as much as I can.
Bill12780

HOLY CRAP!
I hope you didn't pay for that!
PBP - $250
PIC Experimenter's board - <$200 for a good one
A bit of time and playing = Priceless..
That class = $2000+
That's the problem with classes and a schedule...when you get done with them, pretty much all you REALLY know how to do is to build the projects they want you to build. You don't get a chance to play and build something of your own and REALLY learn from your own mistakes.

bill12780
- 7th June 2007, 18:06
HOLY CRAP!
I hope you didn't pay for that!
PBP - $250
PIC Experimenter's board - <$200 for a good one
A bit of time and playing = Priceless..
That class = $2000+
That's the problem with classes and a schedule...when you get done with them, pretty much all you REALLY know how to do is to build the projects they want you to build. You don't get a chance to play and build something of your own and REALLY learn from your own mistakes.

Yea its expensive, But if you look you end up with about 900 bucks worth of stuff dev boards, the pro compiler etc...so I figured it was really only about 1000 bucks. I have NOT taken the class but was considering it. Hence my question....

And I agree that I have learned more blowing things up then I ever learned in school.

Thanks for the reply
Bill12780

skimask
- 7th June 2007, 18:45
Yea its expensive, But if you look you end up with about 900 bucks worth of stuff dev boards, the pro compiler etc...so I figured it was really only about 1000 bucks. I have NOT taken the class but was considering it. Hence my question....

And I agree that I have learned more blowing things up then I ever learned in school.

Thanks for the reply
Bill12780

Glad to see you didn't waste your time.
I can tell you that there's probably at least a dozen people or so around here that could probably do an equal if not better job at the same type of thing you were talking about...just change the initials and you're in there...in my case it would be something like jdgresearch. I should do that and charge half the cost.
(Incidentally, I don't see $1,000 worth of stuff there...)

bill12780
- 7th June 2007, 19:49
Glad to see you didn't waste your time.
I can tell you that there's probably at least a dozen people or so around here that could probably do an equal if not better job at the same type of thing you were talking about...just change the initials and you're in there...in my case it would be something like jdgresearch. I should do that and charge half the cost.
(Incidentally, I don't see $1,000 worth of stuff there...)

If you have the expertise to do it...I would talk about a cherry gig! I got the 900 figure from them. They said it includes a dev board, compiler, editor a hand full of PIC's adapters, programers, sensors, motors, LED's all kinds of stuff basically a "everything you need to start" kinda thing.

I did not really need it cause I can order a dev board from MEL and then upgrade my old version of PBP for 25 bucks. I already have a epic programer. But was looking at the USB one they have now.

I also have the book by chuck helbuck(sp?). So I think I just need to lock myself in the basment and go to town!

I know its not "approriate" but what do you guys think of the atmel stuff? I have heard its cheaper (cost per unit) and they are more "universal" in architecture (8051 or arm cant remember)

Again, thanks for the input and the information...I love a good forum.

Once I get up and running I will try and give my advise on the electronics side of stuff that is my forte.

Bill12780

skimask
- 7th June 2007, 21:07
Take a look at the compiler/dev board packages available at www.melabs.com and/or www.mikroe.com/en (not neccessarily mikro's compiler but the dev boards).

Everything you need - you could probably get a 'grab bag' from Jameco for about $25

Programmer - can't beat the USB PICKit2 direct from Microchip for $50-ish

ATMEL vs. PIC - to each their own. I've messed with both. It seems to me that the architecture of the PIC is superior, but that's just me, and I started out with Z-80/8085/Intel types and then switched over.

bill12780
- 7th June 2007, 21:42
Thank you all for the input on the class. Maybe its a good thing I did not go. (the world may never know!)

But what about a good solid chip to start with. Do they make one with a built in RS-232? eventually my project will need to interface to a RF module that is controlled via RS-232.

Like I said before the keypad project will be basically enter a code, allow the user to run a motor one direction or the other. (This is obviously over simplified because there will need to be several levels of codes for different reasons...)

Save me HOURS of combing though datasheets and give me your opinions here!

Thanks everyone!
bill12780

SteveB
- 7th June 2007, 23:46
Hi bill,
I'll poke my nose in here and suggest the following:

You can start with either the 16 or 18 series, but I would go with the 18 series. Disadvantages to doing that are the 18 series does not have any real small pin count options (like 8pin), and older books won't cover them as well.

Some chips I like:
18F4620 (40pin) or 18F2620 (28pin) - Has most of the available hardware functions (I2C, SPI, A2D, USART, Etc), loads of memory, and runs at 32MHz on the internal clock.

18F4550 (40pin) or 18F2550 (28pin) - Similar to the above, but with USB support if you want to dive into that.

Others will have their own preferences. A parametric search on Microchip's (http://www.microchip.com/stellent/idcplg?IdcService=SS_GET_PAGE&nodeId=74) site will turn up a lot of options. Selecting the functions (like USART) you can't live without, memory size, pin count, and such will narrow the field nicely.

You'll find lot's of help here, especially if you put the work in on your side.:)
All the best as you start learning. Welcome!
SteveB

Melanie
- 7th June 2007, 23:47
> What is a good solid chip that is cheap (comparable to the atmel chips) that will work for me.

This depends on the number of I/O's you need...

For up to 16 I/O's the cheap 16F628A is a good choice. (a) You don't need an xtal (unless you're doing async comms) because it works from it's own internal oscillator, and (b) it handles MCLR internally for you too. So all you need is a program, some volts and it works!

I'll go with skimask's recommendation... forget any and all training courses. Equip yourself with a good programmer, latest version of PBP, a handfull of PICs, the Datasheets are free, a breadboard, good PSU, LCD with flying leads on it, and you're in business.

If you don't know how to do something, then cobble together a little test program to display the result on the LCD. You'll learn more that way than any course.

skimask
- 8th June 2007, 00:51
I'll go with skimask's recommendation...

WHOA! Did I read that right! Did Mel go with MY recommendation? (head swelling, I'll let you know when the pressure gets to be too much :D )
Learned all I can, I have...but a Jedi, I am not...

I'd say go with a PIC18F4550 and associated hardware, programmers, etc.
You can get it in a DIP package (which means you can mess with it on a solderless protoboard), it's got plenty of I/O and memory, plenty of functionality, and it's got USB ports...which, no, they aren't really for a beginner, but they are there for future toys.

bill12780
- 8th June 2007, 01:32
I cant tell you how nice it is to get some good help as a noob on a forum. It is RARE! I read a sticky from Melanie about this and it must have worked!

I do appreciate all the suggestion on chips. I will get the datasheets tonight and look them over.

If you all can handle it. I do have more questions....

1) How big a problem is it moving from one chip to another. Example. Lets say I choose one chip and find I don't have enough space for the program. Are there "other" versions of the same chip with more memory? I mean pin for pin compatible? Otherwise, how do you even begin to estimate how big your program is going to be?

2) I mentioned my project is keypad based. Have any of you heard of or know what the advantages are to using a 74c922 keyboard decoder? I have seen other designs that dont use them and some that do? Like I mentioned before I am an electronics guy (mostly analog stuff) so I have never used a 74c922. I do understand that the decoder will reduce Inputs needed on the PIC and the debounce is controlable. I guess what I am asking is more from a "Coding" point of view/use with a PIC perspective.

3) What do you all think of the MEL lab-x1 dev board? I feel when making purchases its always best to ask the man(or woman) that owns one. Also, is my epic programer still gonna be ok with the new chips. Or should I invest in a USB programmer.

4) What about the PIC-AXE with the bootloader? If I am not mistaken would this not me similar to like having a Jtag port? As Ricky Ricardo would say "splain it to me"

Man, I cant tell you how refreshing it is to go to a forum and not get slammed for being ignorant...(Ignorant has in un-informed---not stupid that is different!)

Thanks again, and if anyone needs electronics help I will do my best!

Off to the MICRO-CHIPS website for some datasheets!

bill12780

skimask
- 8th June 2007, 02:57
1 - Piece of cake... Most of the PIC's in the same family are (i.e. 28 pin for 28 pin, 40 pin for 40 pin, and so on), 99% compatible at the pin level with a newer PIC having more functionality on the same pin or set of pins, about 95% compatible at the PBP level, and probably around 80% compatible at the assembly level. For instance, I built an MP3 player, started off with a 16F877A, moved to an 18F452, then an 18F4620. No change in hardware, and minor changes in the PBP source.

2 - The 74C922/74C923 aren't that easy to find anymore and they're a bit expensive. You could do the same thing with a much cheaper 18 pin PIC, and program it yourself to include things like shift keys, control keys and things like that. Can't do that with a 74C922...

3 - I don't own a dev board of any sort. There is nothing wrong with any of the boards sold by MeLabs, they're all good...however, I do believe you get a better deal with the ones from www.mikroe.com, the EasyPic4.
And I (and others will say the same thing) think one of the better programmers out there is the PICKit2, upgradeable, support direct from Microchip, it's USB, self powered, and so on. I just bought one, works great.

4 - PIC-AXE with a bootloader - all that means is that you can reprogram the chip without having a programmer, usually all you need is a serial port or something similar, but at the expense of a couple of pins and some code space. With time, you could make your own bootloader...or you could buy or download 'bootloader' code from various places on the 'net.

4a - and yes, it's similar to a JTAG port.

b1arrk5
- 8th June 2007, 03:21
I can highly recommend the LabX-USB board from ME Labs. It is set up for the 18f4550, so you can develop USB applications, it has RS-232 on board, and you can add things like Dallas 1-wire temperature sensors, etc. It has sixteen push buttons on it, so you can set up your keypad project right off the bat. It works with the EPIC programmer, but when I got my new computer I upgraded to the USB programmer, and am very happy with it. (It's getting hard to find an LPT port anymore.) The EPIC plugs right into the development board, you don't have to remove the chip to program it. I do like Melanie suggested, I output to the LCD to debug my programs, and there are a few LED's on the board if you just want to toggle something. I usually use one for a 'heart-beat' so I can tell if I screwed up and confused the microprocessor!

For quick one-off projects I like ME Labs proto-boards. I have one I put a ZIF socket on that I can put little chips like the 16f88 in if I want to try something fast and easy. Hope this helps.

Jerry.

Pic_User
- 8th June 2007, 03:32
Hi Bill,

Welcome to the forum.

3 - I don't own a dev board of any sort. There is nothing wrong with any of the boards sold by MeLabs, they're all good...however, I do believe you get a better deal with the ones from www.mikroe.com, the EasyPic4.
And I (and others will say the same thing) think one of the better programmers out there is the PICKit2, upgradeable, support direct from Microchip, it's USB, self powered, and so on. I just bought one, works great.

EasyPIC4 Development System $120
Get the accessories too while you are ordering.
http://www.mikroe.com/en/tools/easypic4/

Forum post example:
Development Board Recommendations
http://www.picbasic.co.uk/forum/showthread.php?t=5609

Forum post example:
keypad routine
http://www.picbasic.co.uk/forum/showthread.php?t=6230


“PICKit 2”, is one of the the best choices for a beginner, less problems with side-effects.

My opinions only.
-Adam-

SteveB
- 8th June 2007, 03:41
3) What do you all think of the MEL lab-x1 dev board? I feel when making purchases its always best to ask the man(or woman) that owns one. Also, is my epic programer still gonna be ok with the new chips. Or should I invest in a USB programmer.

I do own one, and I can not complain. Solid product. That said, I think the EasyPic4 (http://www.mikroe.com/en/tools/easypic4/) is much more for the money. Lots of good feedback from those who own one as well. (I'm sure Steve, a.k.a. MisterE, will chime in here eventually:)).

SteveB

mackrackit
- 8th June 2007, 08:35
Hi Bill,

My 2.5 cents worth.

Dev board = Box of $4.00 breadboards from allelectronics.
Programer = PICKit2
Chip = 16F877A no USB though

mister_e
- 8th June 2007, 13:52
I do own one, and I can not complain. Solid product. That said, I think the EasyPic4 (http://www.mikroe.com/en/tools/easypic4/) is much more for the money. Lots of good feedback from those who own one as well. (I'm sure Steve, a.k.a. MisterE, will chime in here eventually).

SteveB

YES indeed :D EasyPIC 4 all the way! And buy a couple of their EasyProto board adapter as well...
http://www.mikroe.com/en/tools/easyproto/images/easyproto_onboard_250.jpg
6 bucks it's nothing... it just don't worth to build your own now...

But yeah, assuming a tighter budget, PICKIt2, one breadboard and few parts it's a smart choice as long as the bill of material is at least under EasyPIC4 :D which should come with a 16F877A.

bill12780
- 19th June 2007, 16:51
OK everyone here is what I did.

I ordered my upgrade and manual for PBP (Should be here anyday)

I went with the Microe EasyPic4 with a few of the proto board adapters.

I have pretty much decided that I am going to use a PIC16f876 going to order some of those today.

I can not tell you how much I help you all have been. I would have been totally screwed if you guys had not spoken up and gave me some good info to work with.

I am sure once the coding begins I will be back. I will try and get in here every couple of days to see if I can help with any Electronics issues.

Thanks again! Its more appreciated they you know!

Best Regards,
Bill McFarland

muddy0409
- 19th June 2007, 19:03
I can not tell you how much I help you all have been. I would have been totally screwed if you guys had not spoken up and gave me some good info to work with.

I am sure once the coding begins I will be back

Hi Bill,
Yeah the folks in here are sure to be happy to help in any way.
Also, don't be at all afraid to ask some stupid question (that comes from experience, believe me!)

I've been a basic freak for yonks too, started with the VIC-20, remember them? Did some assembler with the 6502 but long since forgotten.

Anyway, enjoy the forum and the camaraderie(? spelling?) in here.

skimask
- 19th June 2007, 19:51
I ordered my upgrade and manual for PBP (Should be here anyday)
I went with the Microe EasyPic4 with a few of the proto board adapters.
I have pretty much decided that I am going to use a PIC16f876 going to order some of those today.
I can not tell you how much I help you all have been. I would have been totally screwed if you guys had not spoken up and gave me some good info to work with.
I am sure once the coding begins I will be back. I will try and get in here every couple of days to see if I can help with any Electronics issues.
Thanks again! Its more appreciated they you know!
Best Regards,
Bill McFarland

All good, solid choices... Just remember to start off simple (stupidlike? :) ) and work your way up. Play with everything, not only code, but config settings, learn how to manipulate them, mess with interrupts, get a button or two to work, move LEDs around (not the leds themselves, but the lighting thereof), talk back and forth with a PC thru the serial port...and so on and so on. Before you know it, we'll be asking you for answers...

mister_e
- 20th June 2007, 18:58
I've been a basic freak for yonks too, started with the VIC-20, remember them? Did some assembler with the 6502 but long since forgotten.
WOOHOO, those where the days :D

I can't imagine there's a lot of people here reminding that we used regular audio cassette to store/read our programs. This sure make me feel an old guy :(

I begun with TI-99/4A, then VIC-20, TRS-80, COCO-2, Commodore 64, 128, then 8080, 8088, etc etc ...


Anyway, enjoy the forum and the camaraderie(? spelling?) in here.

That's french :D and seems to be almost same in English..
http://www.thefreedictionary.com/camaraderie
http://www.thefreedictionary.com/comradery

malc-c
- 20th June 2007, 22:16
Steve, you and me must be of the same generation :)

I started with the Sinclair ZX81 (I think it was called the Texas 81 in the US ?) - was amazed that you could get a full "traditional" startrek game with an 8 x 8 galaxy, black holes, bases etc all in 1K of memory !

As for the audio tapes, I remember playing them on a hi-fi and you could hear the actual pitch changes representing the 1's and 0's - baud rate of about 10 I guess :D :)

mister_e
- 20th June 2007, 22:52
LMAO... I had the Zx80... just forgot to mention :D

I still have the VIC-20 schematic and programming book :eek:

bill12780
- 20th June 2007, 23:42
I feel so at home here.

I too owned a Timex-Sinclair a vic20, 64, ti-99 4/a and I remember loading programs from my cassette player! Rember how kewl it was to load the program and then 30 mins latter you could come back program AND listen to your favorite band!

then moved to a sanyo mbc-550 (pc clone, dual 5 1/4" 720K floppies! I was the man back then! first one of my friends to have a 1200 baud modem we all had 300's then)

Anyone one any apple stuff from back in the day. I had a apple IIe, a IIc and a lisa...Never bought a mac though...

We all must be 30-40 somthings....

bill12780

Pic_User
- 21st June 2007, 00:12
I feel so at home here.
I too owned a Timex-Sinclair a vic20, 64, ti-99 4/a and I remember loading programs from my cassette player! Rember how kewl it was to load the program and then 30 mins latter you could come back program AND listen to your favorite band!...

... We all must be 30-40 somthings....
bill12780
Hey! Some of us were 30 something when we got the VIC-20!:eek:
-Adam-