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

data loss, PIC get crazy!?

Discussion in 'Microcontrollers' started by bananasiong, Mar 26, 2007.

  1. bananasiong

    bananasiong New Member

    Joined:
    Mar 7, 2006
    Messages:
    1,893
    Likes:
    7
    Location:
    Malaysia
    Hi,
    I'm using two PIC12F629A with two receivers of my RF module and they worked fine a few days ago. Yesterday, I tested them again (without reprogramming them) with the RF module, they didn't work, both the PIC's!!! That IC has only 8 pins, so I'm sure the connection is correct. And I found that the PIC is getting hot.
    Then I remove from the breadboard and reprogrammed it (with the same .hex file) and plug into the same hole of the breadboard, then one worked and the other PIC is burned.
    How come this can happen? Has anyone had this problem too?

    EDIT: Before they're reprogrammed, the ammeter from the PSU showed 1 A when it is turned on, then I quickly turned it off and removed the RF module, turned it on again, the current was still 1 A. So that must be the PIC's problem. It is okay after being reprogrammed.

    Thanks
     
    Last edited: Mar 26, 2007
  2. Sceadwian

    Sceadwian Banned

    Joined:
    Oct 27, 2006
    Messages:
    14,047
    Likes:
    141
    Location:
    Rochester, US
    Sounds like you didn't put a current limiting resistor on an I/O that needs it and shorted the supply to an I/O pin.
    In order to figure out where the fault is you're going to have to post a complete schematic of the entire circuit you have so far.
     
  3. bananasiong

    bananasiong New Member

    Joined:
    Mar 7, 2006
    Messages:
    1,893
    Likes:
    7
    Location:
    Malaysia
    I didn't include the current limiting resistor for the LED, is it the main reason? If it is, now only I realize how important it is. Then I should always put the resistor for good practice.

    Thanks
     

    Attached Files:

  4. dave

    Dave New Member

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


     
  5. Sceadwian

    Sceadwian Banned

    Joined:
    Oct 27, 2006
    Messages:
    14,047
    Likes:
    141
    Location:
    Rochester, US

    Oh yeah, you HAVE to use a current limiting resistor on an LED, and many other components and data interfaces. It is just a diode after all, there's no limit to how much current it will let through, there is however a limit to how much current the I/O pin and the LED itself will let through before burning up.
     
  6. bananasiong

    bananasiong New Member

    Joined:
    Mar 7, 2006
    Messages:
    1,893
    Likes:
    7
    Location:
    Malaysia
    Thanks for that, I'll use a 220 :eek:hm: for that.
    In my college, we have done a lot digital experiment which LED is being used. But we never use resistor with the LED, even from the output of 555 timer as well (not CMOS type).
    If this didn't happen to me, I won't realize how important it is.

    Thanks
     
  7. Sceadwian

    Sceadwian Banned

    Joined:
    Oct 27, 2006
    Messages:
    14,047
    Likes:
    141
    Location:
    Rochester, US
    If you're in college for digital electronics and you don't know why a resistor needs to be used on an LED to limit current something is seriously wrong with your college, or you've not been paying attention.
     
  8. bananasiong

    bananasiong New Member

    Joined:
    Mar 7, 2006
    Messages:
    1,893
    Likes:
    7
    Location:
    Malaysia
    :D No way, I pay attention all the time. The schematic given in our study material don't have the current limiting resistor, for example egg timer circuit. There is no even a bypass capacitor at pin 5 of the 555 timer. I think I learn more from here :D:D
     
  9. Sceadwian

    Sceadwian Banned

    Joined:
    Oct 27, 2006
    Messages:
    14,047
    Likes:
    141
    Location:
    Rochester, US
    Simple knowledge of a diode's V/I curve will easily tell you that you need a current limiting resistor. If this isn't taught in school....
     
  10. blueroomelectronics

    blueroomelectronics Well-Known Member

    Joined:
    Jan 21, 2007
    Messages:
    12,536
    Likes:
    170
    Location:
    Toronto, Canada
    Last edited: Mar 26, 2007
  11. Pommie

    Pommie Well-Known Member Most Helpful Member

    Joined:
    Mar 18, 2005
    Messages:
    10,162
    Likes:
    340
    Location:
    Brisbane Australia
    Maybe the LEDs used in college are the 5V ones - IE with the current limiting resistor built in.

    Mike.
     
  12. Hero999

    Hero999 Banned

    Joined:
    Apr 6, 2006
    Messages:
    14,902
    Likes:
    79
    Location:
    England
    Some LEDs even have a built constant current IC and will work from 4.5V to 15V.
     
  13. Ayne

    Ayne New Member

    Joined:
    Apr 30, 2006
    Messages:
    415
    Likes:
    0
    Location:
    Multan, Pakistan.
    Oh it means a simple LED can burn a PIC!!!

    I think the problem is not LED cuz if LED is the problem then it should be demaged one I/O port, not the whole PIC...

    I think the problem is, u have applied more than 5 volts to PIC VCC...
     
  14. bananasiong

    bananasiong New Member

    Joined:
    Mar 7, 2006
    Messages:
    1,893
    Likes:
    7
    Location:
    Malaysia
    Yes I have.

    Is this kind of LED existing? I mean with the resistor built in? I don't think we have this in our college.

    No, I'm sure. Definitely not more than 5.1 V :D
     
  15. mas

    mas New Member

    Joined:
    Dec 23, 2006
    Messages:
    10
    Likes:
    0
    For the Input ports ..

    should the input voltage be connected across a resistor ???

    I don't use a resistor for inputs !!!! .. Will this make mt pic burn or damage ??
     
  16. Nigel Goodwin

    Nigel Goodwin Super Moderator Most Helpful Member

    Joined:
    Nov 17, 2003
    Messages:
    39,331
    Likes:
    653
    Location:
    Derbyshire, UK
    ONLINE
    As you don't give any idea what you're trying to do it's impossible to say, but the inputs are normal CMOS inputs. PIC's are very hardy devices, you have to do pretty stupid things to damage them (and even then they often survive).
     
  17. Hero999

    Hero999 Banned

    Joined:
    Apr 6, 2006
    Messages:
    14,902
    Likes:
    79
    Location:
    England
    Yes, some LEDs have resistors built in, some even have a constant current IC so the LED draws the same current regardless of the voltage across it.
    I don't know, ask the lecturer.
     
  18. bananasiong

    bananasiong New Member

    Joined:
    Mar 7, 2006
    Messages:
    1,893
    Likes:
    7
    Location:
    Malaysia
    They don't know much about the lab, I should ask the lab technician. But he has resigned recently, so nobody take care of the lab anymore :D
    But I'm sure that normal cheap LED's are used over here. I've experienced once, the polarity is opposite o_O
     
  19. Souper man

    Souper man Guest

    ONLINE
    I suggest you use a 16 DIP resistor package to limit the current going through the curcuit. They work pretty good.
     
  20. bananasiong

    bananasiong New Member

    Joined:
    Mar 7, 2006
    Messages:
    1,893
    Likes:
    7
    Location:
    Malaysia
    16? PIC12F629 has only 6 IO pins and I'm using only one pin for the LED :D
     
  21. Souper man

    Souper man Guest

    ONLINE
    I was reffering to when i used 2 of them for a BS2 project
     

Share This Page