[16F871] Power on RA4 before power on vdd?


Closed Thread
Results 1 to 15 of 15

Hybrid View

  1. #1
    Buzzz's Avatar
    Buzzz Guest

    Default [16F871] Power on RA4 before power on vdd?

    Hello folks!

    I am using a PIC16F871, with a voltage regulator (with power switch) for Vdd. I want to use RA4 as open drain output connected to a buzzer (BZ) which is powered directly from battery. Will I fry my 871 when Vbatt is connected to the buzzer, but no Vdd is present at the PIC? Or will it start buzzing when Vdd is not present?
    In other words: What will happen when the switch is opened in this schematic:
    Code:
    F871
    ----
        |        ____
    RA4 |-------|_BZ_|--------------------------      
        |                                      |   
    Vdd |------\ -----------+5V ---regulator -------- +7.2V
        |     switch
    ----
      |
    GND
    Thanks for your help!

  2. #2
    Join Date
    Jul 2003
    Posts
    2,358


    Did you find this post helpful? Yes | No

    Default

    No pin on a PIC should be at a higher potential than Vdd, and certainly NOT highter than the max rating in the Datasheet (which is usually around 5.5v). Some PICs are rated to run to 12v. Check the Datasheet.

  3. #3
    Buzzz's Avatar
    Buzzz Guest


    Did you find this post helpful? Yes | No

    Default

    I have been looking around, and it seems like I am allowed to put a higher voltage on pin RA4. Copy-paste from datasheet:

    Code:
    Absolute Maximum Ratings †
    
    Voltage on any pin with respect to VSS (except VDD, MCLR. and RA4) ... -0.3V to (VDD + 0.3V)
    Voltage on VDD with respect to VSS ................... -0.3 to +7.5V
    Voltage on MCLR with respect to VSS (Note 2) ........0 to +13.25V
    Voltage on RA4 with respect to Vss .......................0 to +8.5V
    I am using the PIC at 5V, so I thought that voltage on any pin would be Vdd + 0.3V, so that would be 5.3V max.
    The line about RA4 simply says 0 to +8.5V, so I assume that I am allowed to sink 25mA's max at 8.5V max since I am using RA4 as an Open Drain output.

    So this would leave me with the problem that I don't know whether I am allowed to connect the buzzer directly to 7.2V, and whether it will fry my PIC whenn Vdd is switched off? Also, am I getting the first part right?

  4. #4
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,650


    Did you find this post helpful? Yes | No

    Wink Fryed PICs

    Hi, Buzz

    Why not use a stupid N Mosfet ( 2N7000 or BS 170 ) to switch your Buzzer ???
    It would provide all the insulation you need ...

    just invert your output level ( better for Power-on response of the Buzzer... hmmmm ? ) or use a P-Mosfet ( BS 250 ) and buzzer between Drain and ground ...

    Alain

    PS : 13v ... doesn't make you remember something about programming your PIC ??? ... jam at sight !!!
    Last edited by Acetronics2; - 1st September 2005 at 08:27.

  5. #5
    Buzzz's Avatar
    Buzzz Guest


    Did you find this post helpful? Yes | No

    Default

    Yes, a stupid mosfet or even a cheap ass transistor could be the solution. Problem is, that I already have a PCB, and even with redesign really no space for extra components, not even a TO92...
    So that's why I would like to fix this with just a piece of wire between the (now unused) pin RA4 and the buzzer.

  6. #6
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,650


    Did you find this post helpful? Yes | No

    Talking

    Never soldered some components on your copper tracks and played with the cutter ??? ...
    Time to learn !!!

    Alain

    PS: why not put your "piece of wire" to the 5v instead of 7v2 ??? just a track to cut ...
    5v Buzzers also exist !!!
    Last edited by Acetronics2; - 1st September 2005 at 08:41.

Similar Threads

  1. Pin won't stay high during Repeat...Until loop??
    By jellis00 in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 16th August 2009, 23:57
  2. Battery powered applications
    By NavMicroSystems in forum Off Topic
    Replies: 7
    Last Post: - 22nd June 2009, 07:12
  3. Pic getting part power from Analog Port
    By ShaneMichael in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 22nd April 2009, 10:34
  4. PIC power backup with "super capacitor"
    By flotulopex in forum mel PIC BASIC Pro
    Replies: 10
    Last Post: - 24th January 2007, 23:51
  5. 12 Servo's together does not seem to work, Power problem
    By macx75 in forum mel PIC BASIC Pro
    Replies: 14
    Last Post: - 13th December 2006, 19:30

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts