Electronic Projects, forums and more.

Go Back   Electronic Circuits Projects Diagrams Free > Electronics Categories > Micro Controllers


Micro Controllers Discuss all aspects of micro controllers - building them, coding them, etc. All controllers are welcome - PIC, BASIC, Z8 Encore!, etc.

Reply
 
Tools
Old 17th March 2008, 12:08 PM   #1
Default Suggestions for a prototyping PIC board

Howdy All,
I am a newbie to using microcontrollers and have just finished puting together the Inchworm+. I think it's working ok since I was able to load the operation system. But now I would like to start playing around with it. I assume there are two way to use the programmer. The first is build a project and connect the Inchwork to the finished project to program the pic. The second is to have a carrier board with a ZIF socket and program the pic then put the pic in the project. Can someone suggest a ready made/kit carrier board with a zif socket maybe a prototyping board that works with the Inchworm. Thanks for any help advice.
kf8rd is offline  
Old 17th March 2008, 01:16 PM   #2
Default

Quote:
Originally Posted by kf8rd
Howdy All,
I am a newbie to using microcontrollers and have just finished puting together the Inchworm+. I think it's working ok since I was able to load the operation system. But now I would like to start playing around with it. I assume there are two way to use the programmer. The first is build a project and connect the Inchwork to the finished project to program the pic. The second is to have a carrier board with a ZIF socket and program the pic then put the pic in the project. Can someone suggest a ready made/kit carrier board with a zif socket maybe a prototyping board that works with the Inchworm. Thanks for any help advice.
There is a companion board for the Inchworm called the Firefly with a 16F88 target for learning and an ZIF socket for programming. The 16F88 is a good chip to start with if you are going the 16F route
__________________
Please post questions to the forums. PM's are for personal communication.

BCHS/3v0's Tutorials
Junebug USB PIC programmer kit., USB Bit Whacker,
The 15 Minute Printed Circuit Board! (+drill time)
3v0 is online now  
Old 17th March 2008, 01:22 PM   #3
Default

The Firefly was designed as a ZIF socket and / or a 16F88 Tutor.
ZIF is handy for bulk programming but ICD can offer both programming and debugging.
You can also connect the Inchworms ICD connector to a breadboard and your target PIC.
__________________
Bill
Smart Kits build Smart People

http://www.blueroomelectronics.com/
blueroomelectronics is offline  
Old 17th March 2008, 03:57 PM   #4
Default

Thanks for the info! I did not make the connection (no pun intended) for the total use of the Firefly. I think I will place an order for the TZ. That will allow me to learn the PIC with the 16F88 and then use it to program other models for the projects I have in mind. I guess the Inchwork+ and the Firefly make a nice learning/development environment.
kf8rd is offline  
Old 17th March 2008, 04:12 PM   #5
Default

Quote:
Originally Posted by kf8rd
Thanks for the info! I did not make the connection (no pun intended) for the total use of the Firefly. I think I will place an order for the TZ. That will allow me to learn the PIC with the 16F88 and then use it to program other models for the projects I have in mind. I guess the Inchwork+ and the Firefly make a nice learning/development environment.
The Firefly is a fine product (I own one) , but you should also have some solderless breadboards and wires and a basic selection of resistors, capacitors, transistors, switches, LEDs, chips, PICs, etc. Then you're able to try out anything you want - not just what's built into the dev board you have.

Like this. Just imagine your Inchworm+ sitting where that PICkit2 is: http://www.electro-tech-online.com/a...g?d=1205565788
__________________
=========================
Futz's Microcontrollers & Robotics
=========================

Last edited by futz; 17th March 2008 at 04:17 PM.
futz is online now  
Old 17th March 2008, 04:33 PM   #6
Default

I have a lot of components and breadboards but the PIC is new to me. I was playing around with basic stamp but that seems to be an expensive way to go just to play around so I thought I would learn the Microchips. So, if I have this right. I would use the combination of Inchworm+ and Firefly to program the PIC with the Firefly just being an easy way to attach the PIC to the programmer (and also a tutor to learn) The breadboard would be used to prototype my circuit and I just add the PIC I just programmed using the Inchworm/Firefly?
kf8rd is offline  
Old 17th March 2008, 04:41 PM   #7
Default

Quote:
Originally Posted by kf8rd
So, if I have this right. I would use the combination of Inchworm+ and Firefly to program the PIC with the Firefly just being an easy way to attach the PIC to the programmer
Not really. The ZIF socket is much more difficult and more a pain in the butt than using a simple ICSP connector to your target PIC circuit. ZIF's have their place. They're fine for certain things, but not for everyday experimenting.

When using a ZIF for programming, you pry your PIC out of its socket, put it in the ZIF, program it, pull it out, put it back in its socket, test it, pry it out... Over and over and over hundreds of times. This gets REALLY old really really fast. It's slow and tedious.

With an ICSP connector on your target board (whether it be breadboard or dev board) you simply change your program and tell the programmer to program the chip. No removal of the chip from its circuit is necessary. It's simple and quick.

Quote:
(and also a tutor to learn)
The tutor is nice. It's a good way to learn some things. The Firefly has an ICSP connector, so you won't be prying its PIC in and out constantly.
__________________
=========================
Futz's Microcontrollers & Robotics
=========================

Last edited by futz; 17th March 2008 at 05:35 PM.
futz is online now  
Old 17th March 2008, 04:44 PM   #8
Default

Oh, another thing. With many PICs, using ICSP, you can do on-chip debugging. You can start and stop your program, single step it, use breakpoints, examine and change registers and memory, all right on the chip, while it's running your program.

Breadboards are the way to go for experimenting, but a good dev board can be a good starting point too. And you can connect the dev board to the breadboard as a way to expand the dev board's capabilities.

For instance, here's a homebuilt dev board connected to a breadboard with a ribbon cable so I can do temporary things without having to solder everything in. The dev board PIC is the brains, but the circuit being controlled is on the breadboard. The small ribbon is the ICSP cable for programming the 18F452 on the dev board.



In case you think I'm full of crap cuz I have different programmer than you, I also own an Inchworm+ and the Unicorn USB upgrade for it too. I just use the Junebug/PICkit2 more often these days.
__________________
=========================
Futz's Microcontrollers & Robotics
=========================

Last edited by futz; 17th March 2008 at 05:23 PM.
futz is online now  
Old 17th March 2008, 06:20 PM   #9
Default

Thanks for the info...I think I got it! I think what I was missing was not understanding the "What do you need to program the PIC" So, if I got it right this time, I can breadboard my entire circuit PIC and all on a solderless breadboard and include the needed ICSD pins (VPP, VDD, GND, PGD, PGC ) and connect this to the Inchworm and i'm good to go. I the Firefly would still be a good learning platform.
kf8rd is offline  
Old 17th March 2008, 06:38 PM   #10
Default

Quote:
Originally Posted by kf8rd
Thanks for the info...I think I got it! I think what I was missing was not understanding the "What do you need to program the PIC" So, if I got it right this time, I can breadboard my entire circuit PIC and all on a solderless breadboard and include the needed ICSD pins (VPP, VDD, GND, PGD, PGC ) and connect this to the Inchworm and i'm good to go. I the Firefly would still be a good learning platform.
Yes. You got it.

Build yourself one or more of these for connecting your ICSP cable to the breadboard. The male connectors are cheap and easily available. The reason the header is missing one pin is that it was a USB connector that was salvaged off an old computer mainboard. That pin isn't needed anyway so I didn't cut a new piece of header:
Suggestions for a prototyping PIC board-icsp_conn001sm.jpgSuggestions for a prototyping PIC board-icsp_conn002sm.jpgSuggestions for a prototyping PIC board-icsp_conn003sm.jpgSuggestions for a prototyping PIC board-icsp_conn004sm.jpg
You can get free programming cables by ripping parts from ancient pre-pentium computers and assembling two old serial cables into one programming cable. Or you can buy them new from SparkFun or other company. Or just buy the connectors and build your own cables using ribbon from old floppy/IDE cables.
__________________
=========================
Futz's Microcontrollers & Robotics
=========================

Last edited by futz; 18th March 2008 at 03:07 AM.
futz is online now  
Old 17th March 2008, 10:11 PM   #11
Default

Another option which I found handy was to choose a PIC with "self programming" capabilty and program it once with a "bootloader". After that I would download new programs onto the PIC via the bootloader using the PIC and PC serial ports and Hyperterminal 'front end'... No programmer necessary...
Mike, K8LH is offline  
Old 17th March 2008, 10:16 PM   #12
Default

Quote:
Originally Posted by Mike, K8LH
Another option which I found handy was to choose a PIC with "self programming" capabilty and program it once with a "bootloader". After that I would download new programs onto the PIC via the bootloader using the PIC and PC serial ports and Hyperterminal 'front end'... No programmer necessary...
Ya, bootloaders are ok. But you already have a programmer. Why bother with a bootloader that eats up part of your memory, programs slowly, and adds unnecessary complexity (not that much really) to your programs.

You own a programmer. A bootloader isn't necessary anymore. Whether you have to put a ICSP connector or a serial connector on your target board makes almost no difference. Either way you put some kind of connector on there. Probably the ICSP is easier anyway.
__________________
=========================
Futz's Microcontrollers & Robotics
=========================
futz is online now  
Old 17th March 2008, 11:27 PM   #13
Default

If you prefer having your Laptop, Programmer, and Project board all laid out in front of you during your development sessions, that's fine. There's nothing wrong with that. Myself, I find it faster and more convenient using just my Laptop and Project board (programmed with a serial bootloader) which also seems to be a bit more portable (I always carry my Laptop and my Project board may be small enough to fit in a shirt pocket). I also don't have to dedicate (sacrifice) my PIC ICSP pins or take up board space for an ICSP connector.

Bootloaders aren't for everybody and I haven't found one I really liked and so I write my own. Both 16F' and 18F' versions use less than 256 words of program memory. My bootloaders don't require a proprietary PC 'front end' but use Hyperterminal instead (which comes with the PC). I also use any existing pin that's connected to a switch or speaker or something like that as the bootloader 'trigger'. That is, if there's a switch connected to RC0 for example, the bootloader simply tests to see if that switch is pressed during "power up" or after a "reset" to 'trigger' the bootloader. This makes it extremely easy to get into and out of the bootloader during the development process. For example, I press and hold the switch connected to RC0 and press the "reset" push button to bring up the bootloader. I download the new hex file using Hyperterminal. Then I press "reset" again to restart the Project board with the newly downloaded program. The whole process takes only a few seconds.

Yes, you do need to modify your application programs to operate correctly with a bootloader. This is easy for assembly language programs but requires a little more work for C or BASIC programs;
Code:
;
;  16F' assembly language example
;
Start   equ     h'0100'         ; bootloader present

        org     Start+0         ; 0000 or 0100 (bootloader)

Reset_Vector
        clrf    STATUS          ; force bank 0, IRP 0             |B0
        goto    Main            ;                                 |B0

        org     Start+4         ; 0004 or 0104 (bootloader)

Interrupt_Vector
Regards, Mike

< picture below of Hyperterminal screen after a program download and just before pressing "reset" on the Project board to start the new program>
Attached Thumbnails
Suggestions for a prototyping PIC board-16f88-bootloader.png  

Last edited by Mike, K8LH; 17th March 2008 at 11:34 PM.
Mike, K8LH is offline  
Old 17th March 2008, 11:36 PM   #14
Default

I use a bootloader only if I want the customer to update the firmware sans programmer. It's not a great development tool IMO.

Neat trick, the Junebug (PICkit2) has a USB bootloader when you hold down the button when powering it on. I think I saw a FT232 emulator that uses it.
__________________
Bill
Smart Kits build Smart People

http://www.blueroomelectronics.com/
blueroomelectronics is offline  
Old 17th March 2008, 11:53 PM   #15
Default

Well, some people (you included if I recall correctly) object to dedicating a pin to 'trigger' the bootloader and so that's why I try to use an existing pin with something attached to it. A switch is most convenient but since almost all of my projects include a piezo speaker connected directly to a pin for switch press beep feedback, I layout pcb's with a pull-up resistor on that pin and a jumper between the pin and the piezo speaker. This allows me to pull the jumper and the bootloader will read a '1' on that pin after "reset" or read a '0' with the jumper in place. And so I don't have to dedicate a pin just for the bootloader 'trigger'.

Yes, the ability for a customer to download an updated program without a programmer could come in handy but in that case I think I would use a custom PIC firmware and custom PC 'front end' to make the process as bullet proof as possible.

Mike
Mike, K8LH is offline  
Reply

Tags
board, pic, prototyping, suggestions

Thread Tools
Display Modes


Similar
Title Starter Forum Replies Latest
Home made PCB's markland556 General Electronics Chat 27 22nd February 2008 03:31 PM
Adding LEDs to ICs (PIC - MAX232) Suggestions? johankj Electronic Projects Design/Ideas/Reviews 2 18th February 2008 02:27 PM
CPLD prototyping board. jrz126 General Electronics Chat 1 18th October 2007 02:39 PM
Blueroomelectronics PB01 Prototyping board, Opinions welcome (picture) blueroomelectronics Electronic Projects Design/Ideas/Reviews 7 4th February 2007 12:58 PM
why is the prototyping board called "breadboard"? janetsmith2000@yahoo.com General Electronics Chat 3 25th July 2005 02:45 PM



All times are GMT. The time now is 04:53 PM.


Electronic Circuits  |  Learning Electronics
eXTReMe Tracker