Right microcontroller

Thread Starter

nathomas

Joined Mar 3, 2011
82
My need is a microcontroller with

- 3 analog inputs
- 6 outputs
-1 relay driving
-1 pwm
-1 analog
-2 digital reading
-2 led outputs

Could anyone recommend a microcontroller for the purpose which is easy to program and i could buy the programming and test kit fast.

Thanks.
 

BillO

Joined Nov 24, 2008
999
Sounds like you are new to the game.

If ultimate speed is not a major concern, I'd recommend the PICAXE 20M2. Costs about $6. It needs no programmer, just a serial cable, and the development environment and BASIC language are free.

If speed is a major concern, the the pic it is based on (don't know off hand the part number) would be a better choice, but you'll need to buy a programmer. A limited version of 'C' is available for it for free, but for anything complex, you will have to pay.
 

Markd77

Joined Sep 7, 2009
2,806
You will almost certainly need a transistor for the relay, so a normal output can be used.
How fast and how accurate do the analog inputs and output need to be? Analog output is fairly rare but if it doesen't need to be very fast then pwm and a filter can be used.
 

Thread Starter

nathomas

Joined Mar 3, 2011
82
This is a temp control circuit. Using an rtd. I have used microcontrollers before but a long time back and those were for measly projects. The circuit should be fairly accurate to around 1deg change and speed is not a major concern. but eventually i might change the analog reading to digital that is why i need the digital led outputs too. i would need pwm to control a fan. the other thing is whether a pic is easier in programming or is ther anything better. i am good at c programming. this has to be sturdy and reliable. what abt the atmega 16L8au. or the pic 18f452.?
 

retched

Joined Dec 5, 2009
5,207
Grab an arduino or a picaxe.

$30 and you are off and running.

Picaxe can be programmed in BASIC and the Arduino in C-ish ;)

Both have enough to do what you want.

Flipping a coin will be MUCH easier than asking for the best. Too many fanboys.
 

Thread Starter

nathomas

Joined Mar 3, 2011
82
well the problem with the arduino or the picaxe is that I want this on a breadboard that fits my specs. as a development kit it is fine but eventually i need to know which microcontroller i can use.
 

Markd77

Joined Sep 7, 2009
2,806
The PICAXE chips are just that, available in DIP or surface mount, so you can use them on your own boards.
If you want to use a PIC with C then you can download MPLab IDE and one of the C compilers for free to test it out without buying anything. I think the same is true for Amtel.
They are probably both about as easy (or hard) to use.
I'm still a bit confused about the outputs. Is the analog output for a panel meter? What is the digital LED output device that you wanted to use?
 

John P

Joined Oct 14, 2008
2,026
I don't think any common microcontroller has an analog output. As Markd77 said, you can fake it with PWM if it's not a high-performance situation.

My favorite is the PIC16F690; it has lots of stuff in a 20-pin chip. But in general the best advice in selecting a processor is "whichever one you feel most comfortable with". Because if you have to learn the processor and write the program at the same time, you've got two intersecting problems.
 

hgmjr

Joined Jan 28, 2005
9,027
You will be able to do all you want to do with AVR or PIC microcontrollers. The relay drive will entail the use of a driver stage with either of these microcontrollers. The suggestion of PICAXE or ARDUINO are good ones if you want to avoid the need to design your own board. I can speak to the fact that with the Arduino you will not need to buy either programming software or a microcontroller programmer. Either PICAXE or ARDUINO are great ways to get near instant gratification.

hgmjr
 

BillO

Joined Nov 24, 2008
999
I don't think any common microcontroller has an analog output. As Markd77 said, you can fake it with PWM if it's not a high-performance situation.
The PICAXE 20M2 has a DAC. This chip will fit his needs for under $10 total.

Go here : http://www.rev-ed.co.uk/picaxe/ and look for the 20M2.

EDIT: Just checked. Looks like they have been working hard to make a liar out of me. The PICAXE-20M2 has now been superseded by the PICAXE-20X2, which does not have a DAC. However, it does have 2 high precision PWM outputs, so they might work just fine with filtering. You might aslo still be able to get the 20M2 from old stock somewhere.
 
Last edited:

t06afre

Joined May 11, 2009
5,934
Get a PICKIT 2 or 3 programmer. Then bread-board with any chip that suit you. Do not go down the PICAXE alley. PICAXE is just flim-flam.
 

retched

Joined Dec 5, 2009
5,207
You can pull the arduino off of the board and use it on the breadboard.

You can also use many AVR(Atmel) chips and load the Arduino bootloader on to it, (requires a friend with a programmer ;) )
 

t06afre

Joined May 11, 2009
5,934
You can pull the arduino off of the board and use it on the breadboard.
If you do that. put a an extra socket on the MCU. So you are working on the socket, not the chip. The you take it in and out of the circuit. The chip pins will very quckly break. If you do not protect them in a socket.
 
Top