Difference between revisions of "Power modes"
m (→Is it be able to run from the AC Adaptor alone?: changed "be able" to "possible")
(→What about the power cable?)
|Line 24:||Line 24:|
A PSP power supply will work fine with the Pandora [http://forum.openpandora.org/viewtopic.php?f=17&t=41&st=0&sk=t&sd=a].
A PSP power supply will work fine with the Pandora [http://forum.openpandora.org/viewtopic.php?f=17&t=41&st=0&sk=t&sd=a].
==Is it possible to run from the AC Adaptor alone?==
==Is it possible to run from the AC Adaptor alone?==
Latest revision as of 16:38, 3 November 2014
- 1 Power Supply
- 1.1 Can it charge from USB?
- 1.2 What kind of battery does it have?
- 1.3 How long does the battery last?
- 1.4 What about the power cable?
- 1.5 Is it possible to run from the AC Adaptor alone?
- 1.6 Does the Pandora have 'sleep' or 'hibernate' modes?
- 1.7 Power Modes
- 1.8 Events
- 1.9 Charging
- 1.10 Operating Point
- 1.11 Times
- 1.12 Battery Calibration
- 1.13 Battery Care
- 1.14 My Pandora does not start, even with the mains adapter plugged in
- 1.15 Controlling LEDs and backlight
- 1.16 Data provided by battery and power driver
- 1.17 Fuel Gauge/ Battery Monitoring
- 1.18 Power Management IC
- 1.19 Charging
Can it charge from USB?
Yes, through the mini-AB OTG port. However, whilst the Pandora is in use the charge rate may be so low as to make it impractical for normal purposes. 
What kind of battery does it have?
The Pandora has a 4000mAh Lithium Polymer battery.
Batteries are user-replaceable and spares are sold by Pandora retailers.
How long does the battery last?
- The actual battery runtime varies based on the the software being run, peripherals in use, and consequently the power mode in which the Pandora operates.
- For instance, using Wifi constantly, or having it constantly polling will reduce the life by a couple hours, compared to disabling the wifi altogether.
- Starting with the OS SuperZaxxon, Beta 2, using kernel 3.2.1, the Pandora has:
- a total standby of averagely 180 hours,
- an active runtime of 10 to 30 hours (screen on & WiFi on, PND app(s) which utilize more/less CPU)
- up to 75 hours (idle system, screen & WiFi off).
- Source: Study by user porg
What about the power cable?
The Pandora ships with a switching power supply with a standard cord socket which should function with 110V and 240V AC power. These are either localised, or shipped with an appropriate adaptor.
A PSP power supply will work fine with the Pandora .
The barrel jack is 4mm Ø 1.7mm inside and 9.5mm long + on the inside
Is it possible to run from the AC Adaptor alone?
Originally, it was thought not, due to the design of the OMAP chipset appearing to require a battery to be connected.  However, it has now been confirmed that the Pandora DOES now work without a battery installed, although some features (like backlight) may have to be turned off via software to enable this. The hardware tweak or tweaks have been performed as part of Pandora development, and are not something that the end user will have to worry about/perform.
Information from Mweston  When no battery is found on AC adapter insertion, the unit goes into constant voltage mode which provides a constant 4.0V on the battery net. It doesn't like it if you put a battery in at this point because the TI chip doesn't appear to be designed to jump back to normal mode without a power cycle. It could do weird things like dump ridiculous amounts of current into the battery without software control. I liked the idea of letting customers power without a battery so we left this feature in but be aware of this restriction:
IF YOU POWERED THE SYSTEM WITHOUT A BATTERY, SHUT IT OFF BEFORE STICKING THE BATTERY BACK IN. (not an angry sentence, just making it clear.) :)
When the battery is inserted first, the system will power up using the normal mode. When the AC adapter is plugged in after this, it will power the system and charge the battery up to the limits set in software. Currently, Notaz and I have chosen 1A on the AC adapter and 600mA from the USB input. It can be changed by sending commands to the chip to alter these set numbers but that is a software lesson better learned from someone else. With the LCD off (lid closed perhaps) idling on the desktop, something like 750mA will go to the battery for a 6 hour charge time or so. With the system doing stuff and demanding more power, less current will go to the battery and it will charge slower. 1A was also chosen to consider thermal dissipation because the regulator of the TI chip is linear and wastes energy dropping the voltage from the 5V down to just above the cell voltage. You may notice the system feels warmer when the battery is more discharged than when it is full which is normal.
I haven't had much luck hot swapping batteries while the system is live but I think it worked for ED once. For me, as soon as I pull the battery, the system resets. The power management chip seems to rely on the status of the thermistor in the battery and it if disappears, it can trigger events. Maybe there are software work arounds but I don't know.
Does the Pandora have 'sleep' or 'hibernate' modes?
Pandora supports suspend-to-RAM (sleep) but not suspend-to-disk (hibernate). Entering these power saving modes will be controlled by software and can be configured to happen when you press the power switch, close the lid, or only on demand.
Without switching the device entirely off, it may be placed into low power mode or regular power mode; simply pressing the power button will toggle modes. Note that as of hotfix3, opening the lid in low power mode has no effect.
This is the normal operating mode, display on, WiFi and Bluetooth on if requested. CPU speed can be selected by the user, and has a small impact on battery life. Screen brightness will also have a significant effect on battery life. The CPU should automatically self-regulate to the current task, and 10-20 hours battery life is possible depending on usage. This is mostly independent of the set CPU speed for any given task. At any time, the battery gauge will show the remaining battery life if the usage remains the same as over the past some seconds. See  for a detailed breakdown of power consumption.
The only change with the lid closed is to turn off the LCD backlight and the display itself. This improves battery life, allowing music playback and streaming to continue. As of Hotfix2, the screen remains on if the device is powered up with the lid closed. It is also possible to set xfce to blank the screen after a period of inactivity, which helps with battery.
Low power mode is toggled by a short press of the power switch to the right. The screen is off, the radios are disabled, the CPU max speed is set to 14 MHz. The device is still silently on, allowing for alarms to go off or it to be turned on again instantly. The power LED will be dimmed, and may appear to be off if you are outside in the sunshine.
Low power mode is probably going to be used as the normal "off" for most people, with true off (device powered down entirely, unable to respond to alarms or wake up quickly) available to conserve battery power. Turning the Pandora off completely is the best option if you don't plan on using it for few days or longer.
Since the Pandora has to be powered whilst it is charging, low power mode is best for fastest charging, and will even allow a full charge to be achieved from USB. It is also the best way to use the Pandora as a USB charger for other devices.
Opening the screen whilst in low power mode has no effect (screen stays off, clocks stay low), and you will need to use the power switch to resume.
At the moment, there is no clear advantage in slowing the clocks (other than being an effective pause button when playing MP3). The only saving is through disabling the radios. This is likely to be improved in due course since there are features in the omap processor for power saving which are being added to the linux kernel.
Select Logout then Shutdown from the window manager to power off. If a charger is connected, the device will re-boot immediately. It is possible to get into a state where you believe it is powered off, but in fact it is using power at the normal screen off rate - so after 12 hours, 50% of your battery is gone. The Power green LED ought to be a tell-tale. It is possible that some bugs exist in this area, but nothing has been clearly identified
A common problem seems to be that if you switch off before unplugging, your Pandora will re-boot even though it is now left unplugged. This problem is compounded by the low battery shutdown script being called repeatedly (and actually preventing shutdown).
To do a hard-reset of the Pandora (in case of software crashes), press and hold the Pandora key and flick the power button to the right.
To do a hard-shutdown of the Pandora, press and hold the Pandora key with right shoulder button held and flick the power button to the right, and then select shutdown from the menu.
The events which control power can be customised . Lid switch, Power Switch, battery threshold and Window Manager shutdown commands. Note that the battery manager in xfce will also take action when the battery is low, by default forcing a shutdown at 5% (so you may observe a full boot process, the window manager appears, then immediately shuts down)
It is possible to charge from the mains charger (use the supplied one or a GENUINE PSP adaptor only) or USB cable. While a charger is connected, remaining battery level is displayed, but the time displays 00:00. If charging from USB, it is possible that the battery will still discharge slowly, since the Pandora takes more current (in normal mode) than the USB can supply. Mains charge is configured to draw 1000mA, USB charge is more like 600mA.
It is not possible to charge the Pandora without turning it on - connecting the mains charger or the USB cable will turn it on automatically. The normal charging circuits rely on the CPU for configuration. In practice, this has minimal impact on usage, except that after charging, you might wish to unplug the charger and explicitly turn off if you don't intend to use the Pandora soon.
Full discharge charging: The pandora will shutdown in case of low battery power. However there is a protection circuit in the battery itself which will cut off the power output of the battery. The battery and the pandora seems to be dead in this condition, but it's not. If you plug in the power you'll see nothing happen - but the battery will be recharged very slowly until the battery is above it's cutoff level. This could take up to 30 minutes. Then the pandora will startup and the normal CPU controlled faster charging will continue. 
If your Pandora's battery is at less than 1% (actually configurable in XFCE), then you may have problems in using USB to charge the Pandora. Currently, USB is not recognised by the XFCE battery monitor so it will shutdown with no warning. As a workaround, you can put your Pandora into low power mode as soon as the flashing mouse icon (XFCE startup) appears. This should significantly delay loading the battery monitor widget, and even if the charge hasn't passed 1% by the time it checks, on the next try you should be there.
The OPP is a TI term which reflects the fact that low clock speeds can be achieved with lower supply voltage than the higher clock speeds. Increasing OPP will reduce the lifetime of the device significantly (from 10 years to 5 years of continuous use.) OPP3 is the default as shipped by OpenPandora.
Since at least SuperZaxxon 1.52, the system has shipped with a utility to modify the maximum OPP. It is part of the CPU-Settings app (found in your Settings menu). Select the option 'Set the max OPP level', select 'Change Setting' and read the following warning. Agreeing to it will allow you to set the maximum OPP in the range 3-5.
As of Hotfix4, it is possible to set a maximum OPP in the range 1-5 (for example, to 5):
echo 5 | sudo tee -a /proc/pandora/cpu_opp_max
This will then increase OPP to suit the requested CPU max, as pre-determined by a table built in to the kernel. These thresholds use OPP1 for below 125 MHz, and OPP5 for above 720 MHz . It is possible to set the limiter and maybe run at 500 MHz in OPP2 (depending on your specific chip). See this forum thread for actual results.
|Using anything above OPP3 WILL shorten the lifetime of your Pandora, although it should still outlive the 1 year warranty. Using anything above OPP5 and 1Ghz will void your warranty (see here)|
- This data originates from different studies performed under different OS versions and use cases.
- Please add the source and a short note about the conditions you used, and if necessary more detailed ones to the Talk page. You can use Pandora System Info to monitor power consumption.
|Active applications/games||8-18 hours||SZ 1.52|
|Low load, low backlight brightness||20-25 hours||SZ 1.52|
|Drain the battery as fast as possible||4 hours||SZ 1.52, backlight at max brightness, constant wifi activity (big download), CPU stress test running at OPP5 and overclocking above 900 MHz, copying huge files from one SD card to the other, USB host and bluetooth activated (but nothing connected)|
|MP3 play, screen off||43 hours||MP3 playback in Audacious in OS SuperZaxxon, Beta 2, Kernel 3.2.1|
|Low Power Mode||30-75 hours||OS SuperZaxxon, Beta 2, Kernel 3.2.1|
|Power off||5% charge loss per week||although there are reports of much faster drain?|
|Standby Mode (no longer applicable?)||160-200 hours||OS SuperZaxxon, Beta 2, Kernel 3.2.1|
|Mains charge, lid closed||4 hours||SuperZaxxon 1.52|
|USB Charge, operating||20 hours||inactive, screen+wifi on, may charge or discharge depending on load|
|USB Charge, low power||20 hours||estimate|
- Fully charge to 100%, turn off the Pandora and leave it for 5 hours.
- A full charge is when, while charging,"cat /sys/class/power_supply/bq27500-0/voltage_now" reads around 4200000 and "cat /sys/class/power_supply/bq27500-0/current_now" reads around 800000. If the meter reads 100%, make sure to check these two files to ensure it's actually FULL. Realistically a charge current below 100000 is close enough.
- Then fully discharge (make sure that "cat /sys/class/power_supply/bq27500-0/voltage_now" returns about 300000), turn it off again for 5 hours.
- That's the process for recalibrating the fuel gauge.
- You can charge your battery to full charge, the charging circuits will then reduce the current to avoid overheating
- If you won't use the battery for more than a week, it is best to leave it at about 40% charged (as opposed to full)
- Don't worry about running it down too low, there are protection circuits to avoid a damagingly low discharge.
- Avoid leaving the battery completely discharged though. When the power runs out, the system will be unable to shutdown cleanly, and might corrupt your files or the system.
- No harm will come if you only partially recharge it. If you've only got 10 free minutes to charge before leaving, go ahead. You'll put an hour of usage back into the battery, and you can always charge it more later.
- For best accuracy, the battery meter relies on watching the battery discharge over most of it's range (down to say 10%).
- This will only affect the 'time to run' indication
- If you're not going to be using your battery for a very long time, the extremely best thing you can do for it is to discharge to 40%, seal it in an airtight bag, and put it in the fridge. Even years later, you pull it out, and it will be almost as good as when you put it in.
My Pandora does not start, even with the mains adapter plugged in
When a battery is inserted, the power goes into the battery, charges it and the battery powers the Pandora. When no battery is inserted, the power goes through the charging circuit directly into the Pandora.
What this means is, if the battery is really empty, the Pandora won't power on when connected to AC until the battery reaches a certain voltage level. Let it charge the battery (it could take 10 or more minutes before it starts to charge) or remove the battery and plug in the mains adaptor, it then should start.
|If you powered the system without a battery, shut it off before sticking the battery back in!|
Controlling LEDs and backlight
Data provided by battery and power driver
Information from the battery and power supply in the pandora when it is booted. It lists readout data that is provided so that you for example can write your own applet showing current power status or include some power information in your application.
Power information is available via sysfs. This is the dmesg information about the battery:
bq27x00-battery 3-0055: support ver. 1.1.0 enabled
Fuel Gauge/ Battery Monitoring
/sys/class/power_supply/bq27500-0 reports how long the battery will run for.
Here is a list of the provided information and how to interpret the values:
|capacity||remaining capacity in %||100=full, 0=empty|
|current_now||discharging/loading rate||µA; negative: discharging; positive: loading|
|present||is a battery inserted?||1=yes; 0=no|
|temp||monitoring IC temperature||decidegree celsius, value of 250 = 25.0°C|
|time_to_empty_avg||battery time left based on drain on some average; not used in XFCE applet||seconds; only relevant/existing when discharging!|
|time_to_empty_now||time left based on current drain; used in the XFCE applet||seconds; only relevant/existing when discharging!|
|time_to_full_now||time left for charging with the current usage; not used in XFCE applet||seconds; only relevant/existing when charging!|
|type||should always read "Battery" since it is a battery...|
|voltage_now||current voltage left||µV|
Power Management IC
/sys/class/power_supply/twl4030_bci_battery/ Manages charging, from the mains charger or from USB.
- 0 = No charger
- 2 = Mains charger
- 3 = USB charge
The mains charger takes precedence if USB and mains charger are plugged in. Pandora seems not to take power from both inputs for charging. Charging by USB only works with a powered system. If the system is off or the battery is empty, it is not possible to boot the system only by USB power (only tested on one Pandora, please recheck).
Please do keep in mind that all time values are plain estimates and can be "jumpy" depending on current system load, display brightness, WiFi/Bluetooth activity and things like the phase of the moon.
/sys/class/power_supply/twl4030_*/*. Enable/disable charging through those files. The charger chip has trouble operating in automatic mode (overcharges the battery), so pndevmapperd uses enable/disable to prevent that.