Questions on microcontrollers  - Page 1
Forum section: electronics / beginners

author: bluevd
author_rank: Contributor
timestamp: October 13, 2013, 11:46:09 am
content: Hello folks,I'm pretty sure I'll get some flaming for this, but heck, here goes:I need some help on selecting a microcontroller. Now, before you jump in asking what it needs to do, etc., I need to mention out 2 things: one, I have no clue about microcontrollers and two, I'd rather get some explanations that would help me choose the right controller rather than asking every time.So I know about the AVR and the PIC wars and I don't want to start one in this thread. I'm inclining towards a PIC solution (since it does seem to be friendlier to newcommers with the pickit2 or pickit3 stuff). However, if you know a cheap AVR kit, please mention it (no Arduino stuff!).Now the characteristics I'm interested in the microcontroller:1) Low current consumption (this is critical)2) 4 inputs and 1 outputI know these requirements are far too generic, so when you're done laughing, here's what else should be taken into account: I'm interested in a max 8 pin config controller, is possible surface mounted. It has to have self-write capability. The speed doesn't matter since the top frequency I'm dealing with is maximum 40 hz.Based upon these parameters, I did a search on Microchip's page and came up with PIC12F1840 (http://www.microchip.com/wwwproducts/Devices.aspx?dDocName=en549758#documentation)I didn't search yet for an Atmel equivalent.Now, the intended use for this chip is in a mosfet build for airsoft gearboxes. However, since I know little about microcontroller and electronics in general, this has an educational purpose also. So, if you can point me to any good documentation (other than google and the likes) and have a little patience with a newbie, I'd be very grateful.Thanks!

author: Christopher
author_rank: Frequent Contributor
timestamp: October 13, 2013, 11:57:45 am
content: Microchip have a better selection, I used to use atmels but PICs are the industry standard so why the hell not?Most of the new microcontrollers have really nice peripherals (hardware SPI/i2c, uart)most of us write in a high-level language, all you really need is a good datasheet and you can do a lot. It doesn't matter what micro you use, they're all gonna be about the same kinda thing.Top tip: use PIC with the pickit 3

author: Unknown
author_rank: Unknown
timestamp: October 13, 2013, 12:07:27 pm
content: Like you say, your generic requirements can easily be met by almost any micro family. Especially since you don't qualify low power consumption. From Atmel an ATtiny13A would probably fit the bill. Could be programmed using any ISP programmer like the Atmel AVRISP MK. II. Something like a TI MSP430G2230 might also work, although it's only available in SOIC. I see no compelling reason to choose for either of these, and all have decent tools and community support.

author: casper.bang
author_rank: Frequent Contributor
timestamp: October 13, 2013, 01:08:27 pm
content: I dived into hobby MCU fun less than ½ year ago and was wondering about whether to go PIC or AVR. After some research, I ended up taking the AVR road, since it seemed to be more open-source/community friendly - and I was not disapointed. Specifically having an awful lot of fun with the pico-power ATtiny13A, which sounds exactly like what you need as well (draws 90nA while sleeping). An AVRISP MK. II, a breadboard ISP setup and the GCC compiler is all that's needed really.The great thing now is that this class of MCU's are so useful that, more often than not, I now end up implementing a project using these (currently a dawn-dusk relay with adjustable hysteresis and timer). I am sure you can have success with the PIC stuff too, but they seem more industrial/professional (asm programming rather than C, memory bank selection, perefial selection etc.).

author: geraldjhg
author_rank: Regular Contributor
timestamp: October 14, 2013, 01:22:55 pm
content: hithe argument is wiich is the best IDE (INTEGRATED DEVELOPMENT ENVIROMENT)AND EASIEST/FASTEST TO USEeasy use any avr for example mega88 etcget sample bascomavr from mcs electronis (dutch)www.mcselec.commake a very simple programmer (2 resistors)find a pc with parallel portleArn abit of basicGO TO avrfreaks.netyou can do things likeset portb.1 to put a selected pin in a high statehave lots of funsaludos