sleep problem help plz >>>.


Closed Thread
Results 1 to 21 of 21

Hybrid View

  1. #1
    Join Date
    Jul 2008
    Location
    TURKIYE-KONYA
    Posts
    51


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Mus.me View Post
    sorry i did mistikes , all wat i need is to put pic in sleep mode but very low current like datasheet says 2 uA im gettin 3 mA when it sleeps . plz help
    is there any voltage regulator on your board.(7805 - 78l05)

    measure only the current off pic.

  2. #2
    Join Date
    May 2009
    Posts
    66


    Did you find this post helpful? Yes | No

    Question

    Quote Originally Posted by mehmetOzdemir View Post
    is there any voltage regulator on your board.(7805 - 78l05)

    measure only the current off pic.
    hi mehmetOzdemir , no im useing 3.7 battery i just think the problem in the code i dont know how to desables everythings during sleep mode. help plz

  3. #3
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default

    Code:
    DEFINE CONFIG_WORD_$3F31 
    DEFINE INT_OSC 8
    Are you putting those in there for some other purpose?

    They have no effect on your PIC.
    Including setting the proper configs and OSC.
    <br>
    DT

  4. #4
    Join Date
    May 2009
    Posts
    66


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Darrel Taylor View Post
    Code:
    DEFINE CONFIG_WORD_$3F31 
    DEFINE INT_OSC 8
    Are you putting those in there for some other purpose?

    They have no effect on your PIC.
    Including setting the proper configs and OSC.
    <br>
    thanks DT ive took them off but still the same problem

  5. #5
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Mus.me View Post
    thanks DT ive took them off but still the same problem
    And what did you replace them with?
    <br>
    DT

  6. #6
    Join Date
    May 2009
    Posts
    66


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Darrel Taylor View Post
    And what did you replace them with?
    <br>
    well config words is $3F31 wdte off i did sett them in the programmer loader
    im sure i didnt disable somethings like comparators or registers or acd im new in pbp ,i dont understand to much the datasheet . and using internal osc .tank DT for reply ..

  7. #7


    Did you find this post helpful? Yes | No

    Default Hardware issues

    You don't tell us what your hardware configuration is. You do not appear to be setting TRIS for ports A, C and E. They will probably have defaulted to inputs and if any are floating they can be in an undefined state and drawing high current. Make sure all unused inputs are tied high or low and are not allowed to float some mid voltage where the CMOS inputs draw high current.

    Better to make all unused pins outputs and force them high or low as appropriate for your hardware.

    Also, when the system goes to sleep, the high/low status of any outputs are preserved. You might find the processor is asleep but a pin is high and sourcing current to a load like your buzzer. Piezo buzzers can have high leakage. Equally the pin might be low and sinking current from the supply. Use a voltmeter and check that all i/o pins are doing exactly what you want. The WatchDog, brownout and other timers and peripherals all draw additional current and the datasheet gives the most favourable sleep current with all these devices turned off.

    I find it helpful to explicitly define every hardware pin on all ports, whether used or not, with something like

    Code:
    'PortA
    AccelY      var porta.0    ' accelerometer Y axis
    AccelX      var porta.1    ' accelerometer X axis
    ECG         var porta.2    ' analog heart input
    MemD        var porta.3    ' M25Pxx Data TO memchip
    MemClk      var porta.4    ' M25Pxx clock
    LED         var porta.5    ' Active HIGH  
    SpareA6     var porta.6    '
    SpareA7     var porta.7    '
    TRISA = %00001111          ' lowest power
    PORTA = %00000000          ' lowest power
    PBP assumes the WatchDog prescaler is set to 512. SLEEP xx is only accurate if the WDTPS is 512. SLEEP causes a fairly high current spike each time the chip wakes up, approximately once per second. If you set the WDTPS to something like 2048 the sleep times are off by a factor of 4 but the wakeup current spike is reduced in frequency by a factor of 4 as well.

    Getting down to lowest power is hard and needs a sensitive microammeter in my experience. I have spent months getting to minimum current on a data logger and have now got a system down below 500 nA with a PIC18F4620 at 3.7 volts. That includes 256 Mbits of memory and all peripherals.

    HTH
    BrianT
    Last edited by BrianT; - 15th November 2009 at 01:05. Reason: [code] ..... [/code]

Similar Threads

  1. Problem with ports help plz
    By Mus.me in forum mel PIC BASIC Pro
    Replies: 33
    Last Post: - 2nd August 2009, 21:51
  2. Won't go back to SLEEP after 1st Interrupt
    By jellis00 in forum mel PIC BASIC Pro
    Replies: 32
    Last Post: - 29th June 2009, 09:00
  3. ESC problem plz help
    By al000y in forum mel PIC BASIC Pro
    Replies: 11
    Last Post: - 21st January 2007, 10:21
  4. interupt & Sleep Problem - HELP!!
    By Santana in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 23rd November 2004, 10:39
  5. Problem with intensity.. plz help
    By Srigopal007 in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 7th October 2004, 17:25

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