1. Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.
    Dismiss Notice

pic compiling/programming questions

Discussion in 'Microcontrollers' started by breadboardguy, May 7, 2009.

  1. skyhawk

    skyhawk New Member

    Joined:
    Feb 9, 2007
    Messages:
    235
    Likes:
    7
    Location:
    Morgantown, WV
    PGM is the low voltage programming pin. It allows the PIC to be programmed without using 12V, but you lose the pin as an I/O.
     
    Last edited: May 19, 2009
  2. breadboardguy

    breadboardguy New Member

    Joined:
    Apr 27, 2009
    Messages:
    140
    Likes:
    0
    Location:
    montreal, Canada
    So instead of using vpp at 12 volts, i put pgm at? I wont be able to use it as input/ouput pin after programming?why so?
     
  3. be80be

    be80be Well-Known Member

    Joined:
    Aug 23, 2008
    Messages:
    4,869
    Likes:
    144
    Location:
    morristown,tn
    ONLINE
    Last edited: May 17, 2009
    • Like Like x 1
  4. dave

    Dave New Member

    Joined:
    Jan 12, 1997
    Messages:
    -
    Likes:
    0


     
  5. skyhawk

    skyhawk New Member

    Joined:
    Feb 9, 2007
    Messages:
    235
    Likes:
    7
    Location:
    Morgantown, WV

    Because until LVP is disabled in the configuration word PGM must be held at ground in order for the PIC to run. LVP can only be disabled from the high voltage programming mode.

    Here is the link for 16F627A/16F628A/16F648A programming specifications:

    http://www.electro-tech-online.com/custompdfs/2009/05/41196g.pdf

    You can read all the details there.
     
    Last edited: May 17, 2009
  6. breadboardguy

    breadboardguy New Member

    Joined:
    Apr 27, 2009
    Messages:
    140
    Likes:
    0
    Location:
    montreal, Canada
    So actually, i just need 4 wires (data in,out, programming voltage and clock)to the computer to program a pic. And ic-prog will send the right data trough the data wire and make the clock wire oscillate.
    After looking at propicII i am convinced that its how it works, so now how can i configure ic-prog to put clock , vpp and data in,out where on the db9 serial port? Can i re-use the propicII configuration? So then i will have to usedo, d3, d5 and ACK.
    IC-Prog Prototype Programmer, programs : 12C508, 16C84, 16F84, PIC 16F877, 24C16, 24C32, 93C46, 90S1200, 59C11, 89C2051, 89S53, 250x0, PIC, AVR , 80C51 etc.

    Is data out (d0 in this case) is nescessary or a feature?(Because they dont talk of it in the prog datasheet, but it may be a needed thing for ic-prog).
     
    Last edited: May 18, 2009
  7. Sceadwian

    Sceadwian Banned

    Joined:
    Oct 27, 2006
    Messages:
    14,047
    Likes:
    141
    Location:
    Rochester, US
    Breadboardguy what programmer are you using? You can't just wire an RS232 cable to a PIC and program it with this software.
     
  8. breadboardguy

    breadboardguy New Member

    Joined:
    Apr 27, 2009
    Messages:
    140
    Likes:
    0
    Location:
    montreal, Canada
    I (will) use a "lighter" version of propicII by only using the wires and circuitry that is need to program the 16f628a (Wich pins are shown in my last post) so it will be alot smaller but will program a limited range of pic. That is all what i was searching for.
     
  9. skyhawk

    skyhawk New Member

    Joined:
    Feb 9, 2007
    Messages:
    235
    Likes:
    7
    Location:
    Morgantown, WV
    Data out is the same pin on the PIC as data in, just program data. Its purpose is to verify correct programming, i.e. the programmer reads the program that has been entered and compares it with what was intended.

    Also don't forget that the computer ground and the programmer ground must be connected together.
     
    • Like Like x 1
  10. breadboardguy

    breadboardguy New Member

    Joined:
    Apr 27, 2009
    Messages:
    140
    Likes:
    0
    Location:
    montreal, Canada
    Okay, i think that i know all what i need, i will order my pics (16f628a) very soon.
    Thank for your help, i gaved you some more reputation.

    I think that there is an error in propic2 sechematic, its written 4k7 for a resistor.Is it 4.7 k?
     
    Last edited: May 19, 2009
  11. blueroomelectronics

    blueroomelectronics Well-Known Member

    Joined:
    Jan 21, 2007
    Messages:
    12,536
    Likes:
    170
    Location:
    Toronto, Canada
    4K7 is just the European way of saying 4.7K
    Actually I got quite fond of it when I used to read my old Elektor magazines.
     
  12. breadboardguy

    breadboardguy New Member

    Joined:
    Apr 27, 2009
    Messages:
    140
    Likes:
    0
    Location:
    montreal, Canada
    What does power com means on the schematic?
     
  13. blueroomelectronics

    blueroomelectronics Well-Known Member

    Joined:
    Jan 21, 2007
    Messages:
    12,536
    Likes:
    170
    Location:
    Toronto, Canada
    Power usually 5V and common represents GND
     
  14. breadboardguy

    breadboardguy New Member

    Joined:
    Apr 27, 2009
    Messages:
    140
    Likes:
    0
    Location:
    montreal, Canada
    For what purposes there is 4 diodes arrangement just after the power com?
     
  15. skyhawk

    skyhawk New Member

    Joined:
    Feb 9, 2007
    Messages:
    235
    Likes:
    7
    Location:
    Morgantown, WV
    I believe that it reads "power conn" meaning power connector, in this case the connection to the bridge rectifier (4 diodes you refer to).
     
    Last edited: May 19, 2009
  16. skyhawk

    skyhawk New Member

    Joined:
    Feb 9, 2007
    Messages:
    235
    Likes:
    7
    Location:
    Morgantown, WV
    It rectifies ac or provides polarity protection in case of dc. You can build from four diodes or buy as a single component.
     
    Last edited: May 19, 2009
  17. breadboardguy

    breadboardguy New Member

    Joined:
    Apr 27, 2009
    Messages:
    140
    Likes:
    0
    Location:
    montreal, Canada
    Can a breadboard support all the dip microcontrollers?Then i better buy this then a zif socket, wich cost 2 time more.
     
  18. be80be

    be80be Well-Known Member

    Joined:
    Aug 23, 2008
    Messages:
    4,869
    Likes:
    144
    Location:
    morristown,tn
    ONLINE
    Yes here a 18f1320 on one [​IMG] Just bread board it make sure you get p-dip chips like 16f628a-I/P
     
    Last edited: May 20, 2009
  19. breadboardguy

    breadboardguy New Member

    Joined:
    Apr 27, 2009
    Messages:
    140
    Likes:
    0
    Location:
    montreal, Canada
    I think that i will get some 18f too, they have 20x more ram.
     
  20. Sceadwian

    Sceadwian Banned

    Joined:
    Oct 27, 2006
    Messages:
    14,047
    Likes:
    141
    Location:
    Rochester, US
    High frequency (basically anything over about 10mhz) crystals can't usually be run on a breadboard, this isn't a problem if you use the internal oscilator, but if you intend to use crystals you'll need to keep it in mind.
     
    Last edited: May 20, 2009
  21. 3v0

    3v0 Coop Build Coordinator Forum Supporter

    Joined:
    Jul 14, 2006
    Messages:
    9,404
    Likes:
    227
    Location:
    OKLAHOMA USA
    Some PIC's include a PLL which can be used with an extrenal crystal (and sometimes the internal osc) to multiply by 4. With the PLL you can use a 10MHz crystal on the breadboard in conjunction with the PLL to get a 40MHz clock.
     

Share This Page