Author Topic: What do I need to get started?  (Read 6552 times)

0 Members and 1 Guest are viewing this topic.

Offline Peter1964Topic starter

  • Contributor
  • Posts: 33
  • Country: dk
What do I need to get started?
« on: January 11, 2015, 02:28:08 pm »
Hi EEV's
I want to do a timer-project and was at first looking at old-school timer IC's and so on.
We are in the modern computer-age now - so I decided on a micro controller like PIC16F628A and a 2 by 16 lcd display to show what is going on.

Now the problems starts.
What hardware (beside the PIC) should I buy?
What software to do C or Pascal programming?

It only for hobby so I do need something that works but not cost a fortune.
I did take a look at a lot of videos and articles on the net - but it seems kind of confusing and some very expensive.

I am a programmer (that is what I do for a living).

Regards Peter
 

Offline mc

  • Regular Contributor
  • *
  • Posts: 155
  • Country: scotland
Re: What do I need to get started?
« Reply #1 on: January 11, 2015, 03:36:00 pm »
Hardware - whatever you need to program your chosen chip, and whatever else it needs to run.
Software - C, or some variety of C.

Personally, for somebody new to this, I'd be more inclined to recommend something Arduino.
You can pick up cheap Arduino clones for not much money, they have everything onboard to program them, and the Arduino IDE is free. The Arduino IDE is a bit simplistic and uses C++, however there are lots of examples to get you going, and if you then want to use C, you can.
I know lots of people criticise those that use Arduino, but I think it's a very good complete solution for anybody looking to use micros for the first time.

Another option would be some of the ARM development boards that work with the mbed system.

As a beginner, I'd avoid jumping straight into any of the more commercial orientated systems, as they can prove to be very overwhelming if you've never programmed a chip before.
 

Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8221
  • Country: 00
Re: What do I need to get started?
« Reply #2 on: January 11, 2015, 03:50:37 pm »
Quote
What hardware (beside the PIC) should I buy?

You need a programmer and whatever additional devices you may need - like transistors, lcd displays, buttons, etc.

I use pickit2 a lot and really likely it. If you want to use newer parts, get a pickit3 for example.

Quote
What software to do C or Pascal programming?

Depending on your approach. Most people code in C. For pic10/12/16/18 parts, you can get XC8 + mplab or mplab x. For pic24/32 parts, I would recommend C30/32 + emblocks. I have found the lower-end PICs easy to work with but hard to code for.

If you haven't settled on the PIC, I think you should consider other alternatives, like the AVR, or STM8 or the newer 32-bit chips - they offer much better value but have much steeper learning curves too.
================================
https://dannyelectronics.wordpress.com/
 

Offline Wilksey

  • Super Contributor
  • ***
  • Posts: 1329
Re: What do I need to get started?
« Reply #3 on: January 11, 2015, 05:36:07 pm »
Get yourself a PIC dev kit, all you really need is a button and LEDs, I had a PICKIT 2 starter kit years back which included a small PIC dev board, they probably have one similar now with the PK3, personally I would use the PK3 as support is better for them on later chips and with the MPLAB IDE, same as the ICD2 vs ICD3, I now use the 3's as support is much better.

Look on the usual, Element14 / Farnell, Digikey, RS, Mouser, etc for kits
 

Offline picandmix

  • Frequent Contributor
  • **
  • Posts: 395
  • Country: gb
Re: What do I need to get started?
« Reply #4 on: January 11, 2015, 06:12:56 pm »
You have details above for both the Arduino and Pic options which I can add little to.

However , you said Pics , so wonder what has taken you towards them  ?

A cheap ebay Arduino Uno clone is the simplest and most complete way to get going, though C++ can leave you a bit remote from the detailed functions of the micro.

With Pics and C you have a more detailed approach or even Assembly if you want to really get down low and dirty  ;D

While everyone thinks of getting hardware programmer and dev board, don't forget you do not actually need them to get programming.

Arduino and Microchips IDEs are free as are the programming languages C++, Assembly and versions of C,; plus there are free Simulators where you can draw your circuit and run your code, so you can really try before you buy.

There are also masses of free tutorials /ytubes/projects for all the mentioned programming languages, even ones for doing exactly what you mention, just search and have a good look around and see how things are done and enjoy !
 

Offline mathsquid

  • Regular Contributor
  • *
  • Posts: 247
  • Country: us
  • I like math.
Re: What do I need to get started?
« Reply #5 on: January 11, 2015, 06:33:42 pm »
Personally, for somebody new to this, I'd be more inclined to recommend something Arduino.
You can pick up cheap Arduino clones for not much money, they have everything onboard to program them, and the Arduino IDE is free. The Arduino IDE is a bit simplistic and uses C++, however there are lots of examples to get you going, and if you then want to use C, you can.
I know lots of people criticise those that use Arduino, but I think it's a very good complete solution for anybody looking to use micros for the first time.

I agree with this completely.  For someone new to microcontrollers, there's a lot to be said for having an integrated toolchain/IDE and not needing any extra hardware to program it with.    I'd recommend starting with an arduino nano, a breadboard, some LEDs and resistors, and an LCD module.
 

Offline nctnico

  • Super Contributor
  • ***
  • Posts: 26891
  • Country: nl
    • NCT Developments
Re: What do I need to get started?
« Reply #6 on: January 11, 2015, 06:36:28 pm »
Look at this thread:
https://www.eevblog.com/forum/microcontrollers/introducing-the-arm-pro-mini-board-arm-made-eazy/

It doesn't get much easier. Why bother to mess with an obsolete architecture like PIC?
There are small lies, big lies and then there is what is on the screen of your oscilloscope.
 

Offline miguelvp

  • Super Contributor
  • ***
  • Posts: 5550
  • Country: us
Re: What do I need to get started?
« Reply #7 on: January 11, 2015, 07:05:49 pm »
Get something that has good documented projects that are easy to follow, for example:

http://www.element14.com/community/thread/23736/l/100-projects-in-100-days
 

Offline Peter1964Topic starter

  • Contributor
  • Posts: 33
  • Country: dk
Re: What do I need to get started?
« Reply #8 on: January 11, 2015, 08:16:00 pm »
I have now looked at Arduino and think I will get a Nano Rev. 3 board and a LCD1602 Keypad Shield for Arduino - the rest I do have (breadboard and a lot of electronic).
I am in denmark and here are links to those two:
Uno Rev. 3: https://www.elextra.dk/main.aspx?page=article&artno=H31941
LCD with keypad: https://www.elextra.dk/main.aspx?page=article&artno=H36463

This will get the fun begins with a ATmega328 microcontroller.
One question I did not find an answer to are: Can I take out the chip and solder it into a real board and have a running project? (This I can with a PIC)

I read somewhere the chip need a Bootloader? Is that right and how do one do that?
The goal will be to have a chip soldered into a finished project where the code are fixed even without power - still Arduino?

Thanks for advice in this manner.
 

Offline Thor-Arne

  • Supporter
  • ****
  • Posts: 500
  • Country: no
  • tinker - tinker, little noob.....
Re: What do I need to get started?
« Reply #9 on: January 12, 2015, 07:44:55 am »
I read somewhere the chip need a Bootloader? Is that right and how do one do that?
The goal will be to have a chip soldered into a finished project where the code are fixed even without power - still Arduino?

The 328 chip comes with the bootloader already loaded when you buy a Arduino.

You can buy the 328 with the bootloader already loaded, or use a programmer to copy the one you have.

When using the 328 in a circuit you only need a crystal and a couple of capacitors.
 

Offline westfw

  • Super Contributor
  • ***
  • Posts: 4199
  • Country: us
Re: What do I need to get started?
« Reply #10 on: January 12, 2015, 08:22:50 am »
Quote
Can I take out the chip [from an Arduino Uno] and solder it into a real board and have a running project?
Yes.  You'll need a bit of support circuitry (crystal or resonator, bypass caps); the same as you would with a PIC.
Also, on the "real board" you will lose the ability to talk to the chip via plug-in USB cable (unless you replace that capability on your board.)
 

Offline picandmix

  • Frequent Contributor
  • **
  • Posts: 395
  • Country: gb
Re: What do I need to get started?
« Reply #11 on: January 12, 2015, 10:23:49 am »
I have now looked at Arduino and think I will get a Nano Rev. 3 board and a LCD1602 Keypad Shield for Arduino - the rest I do have (breadboard and a lot of electronic).
I am in denmark and here are links to those two:
Uno Rev. 3: https://www.elextra.dk/main.aspx?page=article&artno=H31941
LCD with keypad: https://www.elextra.dk/main.aspx?page=article&artno=H36463

This will get the fun begins with a ATmega328 microcontroller.
One question I did not find an answer to are: Can I take out the chip and solder it into a real board and have a running project? (This I can with a PIC)

I read somewhere the chip need a Bootloader? Is that right and how do one do that?
The goal will be to have a chip soldered into a finished project where the code are fixed even without power - still Arduino?

Thanks for advice in this manner.


Think you can find a lot cheaper boards on Ebay than those you mention.

This clone even has a couple of  user switches built on to the board for a fraction of the price.
http://www.ebay.co.uk/itm/Version-Board-ATmega328P-UNO-R3-CH340T-Instead-16U2-USB-Cable-for-Arduino-UK-BT-/111468707118?pt=UK_Computing_Other_Computing_Networking&hash=item19f40d7d2e
http://www.ebay.co.uk/itm/Hobby-Components-Uno-R3-fully-arduino-compatible-Free-USB-Cable-/141365503458?pt=UK_BOI_Electrical_Components_Supplies_ET&hash=item20ea0a65e2
Same with the lcd shield.
http://www.ebay.co.uk/itm/HOBBY-COMPONENTS-UK-LCD-1602-16x2-Keypad-Shield-For-Arduino-/131142448379?pt=UK_BOI_Electrical_Components_Supplies_ET&hash=item1e88b2f4fb

Have both boards and both worked well for ages..
 

Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8221
  • Country: 00
Re: What do I need to get started?
« Reply #12 on: January 12, 2015, 12:05:01 pm »
-Can I take out the chip and solder it into a real board and have a running project? (This I can with a PIC)-

The answer to that is a little convoluted.

If you want to use the boot loader to program the chip, you will have to have a crystal at a minimum.

However, you can use the arduino IDE to code and the resulting hex file can be burned into the chip via a standalone programmer. This approach allows you to use the internal rc oscillator, like on your pic.


I buy a lot of arduino clones and never used its boot loader.
================================
https://dannyelectronics.wordpress.com/
 

Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8221
  • Country: 00
Re: What do I need to get started?
« Reply #13 on: January 12, 2015, 12:22:17 pm »
Just so you know, you can simply buy an avr, plus a programmer, and burn the boot loader to it, then you have an arduino.

The chip will be a couple dollars and the programmer another couple.

Alternatively, the newer Leonardo is like 10 USD off eBay.
================================
https://dannyelectronics.wordpress.com/
 

Offline Lesterwyatt

  • Regular Contributor
  • *
  • Posts: 73
  • Country: gb
    • My YouTube Channel
Re: What do I need to get started?
« Reply #14 on: January 12, 2015, 04:27:29 pm »
I have used Aurduino for many projects, and for a beginner it's great because it's quite strait forward to get a project up and running. However if your really interested in how your project runs under the hood I would suggest going for the pic16 and the pickit3 with MPLabx. And programming in assembler. There are plenty of books out there on the net. Just google. I have learned more in the last couple of months about micros then I ever did in 2 years with aurduino!

Lester
 

Offline Peter1964Topic starter

  • Contributor
  • Posts: 33
  • Country: dk
Re: What do I need to get started?
« Reply #15 on: January 12, 2015, 07:32:14 pm »
I have used Aurduino for many projects, and for a beginner it's great because it's quite strait forward to get a project up and running. However if your really interested in how your project runs under the hood I would suggest going for the pic16 and the pickit3 with MPLabx. And programming in assembler. There are plenty of books out there on the net. Just google. I have learned more in the last couple of months about micros then I ever did in 2 years with aurduino!

Lester

My worry with MPLabx are the price of a compiler - really expensive.
Never thought going the assembler way - but I actually do understand assembler, did code an OS for  a Motorola 68000 years ago.
 

Offline picandmix

  • Frequent Contributor
  • **
  • Posts: 395
  • Country: gb
Re: What do I need to get started?
« Reply #16 on: January 12, 2015, 09:04:39 pm »
Quote
My worry with MPLabx are the price of a compiler - really expensive.
Never thought going the assembler way - but I actually do understand assembler, did code an OS for  a Motorola 68000 years ago.

MplabX   has a perfectly useable free compiler XC8 should you need it.

MPlab X and even the old  MPlab IDE V8.92 ( PC only)   come with Assembler built in.

Suggest you load one up and start a little Assembler project off and see if you can follow it.
You don't have to buy any books, masses of tutorials and info.
Heres just one , its done using the old Mplab but should be easy enough with Mplab X.
The chip used is the 16f84 which can be readily replaced with the 16f628A

Have a try, plenty of help here ...

http://www.amqrp.org/elmer160/lessons/


If you are using a PC and want to download the old style  MPlab V8.92 for that tutorial you can download it from here.
It runs ok alongside X if you have it installed already.
http://www.microchip.com/pagehandler/en-us/devtools/dev-tools-parts.html
« Last Edit: January 12, 2015, 09:10:00 pm by picandmix »
 

Offline Peter1964Topic starter

  • Contributor
  • Posts: 33
  • Country: dk
Re: What do I need to get started?
« Reply #17 on: January 14, 2015, 01:11:04 am »
Thank you all for advise.

I have now bought an Arduino UNU board (original verision to support the project) and some LCD screens to get started.

I have installed:
Arduino IDE
Fritzing - to be able to do schematics and order PCB's - maybe there are a better tool for free - well I will make a donation so not completely free.

I skipped the assembler idea. I like the C-style better.

Regards Peter
 

Offline Brutte

  • Frequent Contributor
  • **
  • Posts: 614
Re: What do I need to get started?
« Reply #18 on: January 14, 2015, 04:55:43 pm »
Arduino UNU board
Must be some niche product.

AFAIK arduino is not debuggable. You are a programmer so I won't explain consequences of that. Besides, to debug these AVR tinies you have to use Atmel's dW debugger ($50) and ASes (Atmel Studio) as nothing else works with these.

Not the smartest move.
 

Offline Rick Law

  • Super Contributor
  • ***
  • Posts: 3439
  • Country: us
Re: What do I need to get started?
« Reply #19 on: February 05, 2015, 11:12:42 pm »
Thank you all for advise.

I have now bought an Arduino UNU board (original verision to support the project) and some LCD screens to get started.

I have installed:
Arduino IDE
Fritzing - to be able to do schematics and order PCB's - maybe there are a better tool for free - well I will make a donation so not completely free.

I skipped the assembler idea. I like the C-style better.

Regards Peter

Good choice.  The NANO V3 would be a good choice too, but would have given you a bit less available current when tapping into the 3.3V or the 5V pin.

What about input?  You need some way to say "Start Timer" and perhaps Time-for-how-long.  You need a tac switch or something like that.

If you have not purchased the LCD yet, consider the 20x4.  It will give you a bit more screen space to display debugging messages/values as needed.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf