View previous topic :: View next topic |
Author |
Message |
temtronic
Joined: 01 Jul 2010 Posts: 9221 Location: Greensville,Ontario
|
|
Posted: Sat Apr 27, 2024 9:23 am |
|
|
I don't use the WDT but the function of 'restart_wdt()' does imply the WDT peripheral has been 'enabled' somewhere... say 'fuses' ??
hmm.. is this powered from a battery or a PSU ?
have you disconnected ALL 'things' attached to the PIC , like the LCD module ? |
|
|
bulut_01
Joined: 24 Feb 2024 Posts: 62
|
|
Posted: Sat Apr 27, 2024 9:33 am |
|
|
I disconnected the lcd and other connections, gnd and vdd. The power comes from the regulated power supply. Yes, the psu wdt is off, I deleted it from the code, no matter what I do, I cannot go below 100 uA. Does the oscillator continue to operate at 64 mhz during sleep? |
|
|
bulut_01
Joined: 24 Feb 2024 Posts: 62
|
|
Posted: Sat Apr 27, 2024 9:38 am |
|
|
...
Last edited by bulut_01 on Fri May 03, 2024 10:44 am; edited 1 time in total |
|
|
bulut_01
Joined: 24 Feb 2024 Posts: 62
|
|
Posted: Sun Apr 28, 2024 4:20 am |
|
|
What is your comment about this latest situation?
Does the oscillator continue to operate at 64 mhz while the mcu is sleeping? Is that why I can't go below 100uA? |
|
|
temtronic
Joined: 01 Jul 2010 Posts: 9221 Location: Greensville,Ontario
|
|
Posted: Sun Apr 28, 2024 5:15 am |
|
|
I had to download the datasheet.. section 6.2 says CPU clock is 'disabled',however that doesn't mean it's NOT oscillating, rather the signal is not sent to the CPU. Section 4.1 shows diagram for this.
I didn't see a 'sleep' enable on the actual OSC block, it makes sense it's always on,so there's no delay from awaking from sleep.
You'll need to read the entire chapter 6 as there's a LOT of information about what internals are still operating in 'sleep' mode !
I don't use that PIC but it seems to have a LOT of internals that need to be properly configured to get minimal power.
Begs the question, why are you concerned as you're running off a 'mains' PSU ? |
|
|
bulut_01
Joined: 24 Feb 2024 Posts: 62
|
|
Posted: Sun Apr 28, 2024 5:54 am |
|
|
@temtronic
At the circuit design stage, this remote control will work with a battery. The CR2450 will last only 150 days with this battery and 140uA sleep current. My goal is to go down to 5-10 uA levels, but no matter what I did, it didn't go below 100uA. I turned off all the peripherals. All of the peripherals from pmd0 to pmd5 are off, you can see it in the code above. Only timer0 is active, other than that, I turn off all peripherals. This processor is giving me a lot of trouble. I am making a similar circuit with 16Lf1826 sleep() ; When I do it, it goes down to nA level and it doesn't bother me. This is 18Lf25K40. I have another situation that I don't know about. The current value does not go down to nA level. I hope I was able to explain it. |
|
|
temtronic
Joined: 01 Jul 2010 Posts: 9221 Location: Greensville,Ontario
|
|
Posted: Sun Apr 28, 2024 6:13 am |
|
|
hmm, goto Microship's website / forum and look around there.
simple test ...change clock from 64MHz to a really slow speed,see if current goes down ?
Historically CMOS consumes power on the 'transitions' not in 'steady state'.
hmm, are weak pullups disabled ?
Only so many straws in my hay pile to pull at !!! |
|
|
bulut_01
Joined: 24 Feb 2024 Posts: 62
|
|
Posted: Sun Apr 28, 2024 6:45 am |
|
|
I don't understand what you are saying, translate is making me say nonsense. |
|
|
temtronic
Joined: 01 Jul 2010 Posts: 9221 Location: Greensville,Ontario
|
|
Posted: Mon Apr 29, 2024 7:56 pm |
|
|
you have to reduce clock speed to reduce power also vdd if that chip has selectable vdd to the core. |
|
|
bulut_01
Joined: 24 Feb 2024 Posts: 62
|
|
Posted: Wed May 01, 2024 6:23 pm |
|
|
Thank you to my friends who helped me. The problem is, the code below has not been added. Even if I do not use mclr, I need to configure it as input. Currently, my sleep value is 50 nA current.
set_tris_E(0XFF); |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19495
|
|
Posted: Thu May 02, 2024 4:12 am |
|
|
I pointed that out in my post last Saturday..... |
|
|
|