Battery monitor for Dingo Alpha5
NathanO,
For 3.01 Brad_chuck made a battery monitor, I think he made it into a dotpup package, search the forum. I made a pet package out of one of his early versions that I've been using up until Dingo (doesn't work in dingo). I'll attach it.
For 3.01 Brad_chuck made a battery monitor, I think he made it into a dotpup package, search the forum. I made a pet package out of one of his early versions that I've been using up until Dingo (doesn't work in dingo). I'll attach it.
- Attachments
-
- Battery-monitor.pet
- Pet package of Brad_chuck's battery monitor. For 3.01 or earlier. Will not work in Dingo.
- (9.36 KiB) Downloaded 1294 times
I can duplicate this by specifying a non-existent battery.
What do you get for
ls /proc/acpi/battery
try
asapm -bat BAT1
instead or whatever your battery gets listed as
What do you get for
ls /proc/acpi/battery
try
asapm -bat BAT1
instead or whatever your battery gets listed as
Will
contribute: [url=http://www.puppylinux.org]community website[/url], [url=http://tinyurl.com/6c3nm6]screenshots[/url], [url=http://tinyurl.com/6j2gbz]puplets[/url], [url=http://tinyurl.com/57gykn]wiki[/url], [url=http://tinyurl.com/5dgr83]rss[/url]
contribute: [url=http://www.puppylinux.org]community website[/url], [url=http://tinyurl.com/6c3nm6]screenshots[/url], [url=http://tinyurl.com/6j2gbz]puplets[/url], [url=http://tinyurl.com/57gykn]wiki[/url], [url=http://tinyurl.com/5dgr83]rss[/url]
-
- Posts: 195
- Joined: Sat 21 Jan 2006, 05:35
- Location: Bedfordshire, UK
Code: Select all
# asapm
Battery BAT1 is available
asapm: open_apm_device_file: The file does not exist.
In the meantime I've been looking at the System Information (pretty funky). It says 66% and is dropping.
I have just restarted JWM and now the tray says 94%.
I'm going to boot Windows (oh the shame) and see what it reckons to the level of charge. Back soon.
- Attachments
-
- battmon2.jpg
- (2.52 KiB) Downloaded 1989 times
-
- Posts: 195
- Joined: Sat 21 Jan 2006, 05:35
- Location: Bedfordshire, UK
Code: Select all
# asapm -bat BAT1
asapm: open_apm_device_file: The file does not exist.
# asapm -bat BAT1
asapm: open_apm_device_file: The file does not exist.
# asapm -bat BAT1
asapm: open_apm_device_file: The file does not exist.
# asapm
asapm: open_apm_device_file: The file does not exist.
# asapm
Battery BAT1 is available
asapm: open_apm_device_file: The file does not exist.
So all the pieces seem to be there, but just not joined together in my case.
Perhaps it needs to load something else, which isn't instant, thus the asapm needs to be run a minute or 2 after getting the desktop?
Also bottom of the 88% is chopped off sightly. Maybe it's a function of the screen size I've got, but a 1024x768 must be pretty common?
The value from this matches with that in Windows, so I think the System Information has the wrong maximum capacity.
So Rickrandom, your saying that it's behavior is intermittent or random ? But seriously, that makes it difficult. Sometimes when you boot ram only Puppy can't find all of the kernel modules (eg drm modules won't load when ram only), don't know if that could be the problem or maybe a poor acpi implementation for your laptop or some problem with the app. If it's too unstable for you to use, you could try booting with acpi=off apm=on. Asapm supports apm too. This is assuming apm is supported on your laptop and it's safe to use. Safe meaning the fan still works.
Noticed on the Bug thread you were booting grub from ntfs? Is that grub4dos? Also the root=/dev/ram0 is no longer needed.
In order to see the whole battery monitor, /root/.jwmrc-tray line 2 height="26" should be changed to height="28". I reported this to Barry on the Dingo A6 thread.Also bottom of the 88% is chopped off sightly. Maybe it's a function of the screen size I've got, but a 1024x768 must be pretty common?
Noticed on the Bug thread you were booting grub from ntfs? Is that grub4dos? Also the root=/dev/ram0 is no longer needed.
-
- Posts: 195
- Joined: Sat 21 Jan 2006, 05:35
- Location: Bedfordshire, UK
Code: Select all
# asapm
asapm: open_apm_device_file: The file does not exist.
# asapm -bat BAT1
asapm: open_apm_device_file: The file does not exist.
# asapm
asapm: open_apm_device_file: The file does not exist.
# asapm
asapm: open_apm_device_file: The file does not exist.
# asapm
asapm: open_apm_device_file: The file does not exist.
# asapm -bat BAT1
Battery BAT1 is available
asapm: open_apm_device_file: The file does not exist.
#
I've adjusted the height, fine now, thanks.
I guess I could delete the root= stuff.
Not sure what GRUB I've got, but files are:
- Attachments
-
- GRUB.jpg
- (39.34 KiB) Downloaded 1427 times
I just installed Dingo-bat.pet on my laptop, running puppy 3.01. (I then restored the original .jwrmc-tray, with height adapted to 28 and with the asapm swallow pasted in).
Works okay.
Kudos to kirk!
Works okay.
Kudos to kirk!
[size=84][i]If it ain't broke, don't fix it.[/i] --- erikson
hp/compaq nx9030 (1.6GHz/480MB/37.2GB), ADSL, Linksys wireless router
[url]http://www.desonville.net/[/url]
Puppy page: [url]http://www.desonville.net/en/joere.puppy.htm[/url][/size]
hp/compaq nx9030 (1.6GHz/480MB/37.2GB), ADSL, Linksys wireless router
[url]http://www.desonville.net/[/url]
Puppy page: [url]http://www.desonville.net/en/joere.puppy.htm[/url][/size]
- Dougal
- Posts: 2502
- Joined: Wed 19 Oct 2005, 13:06
- Location: Hell more grotesque than any medieval woodcut
I rearranged the layout of the applet a bit, made it smaller and simpler, so it integrates better with different size panels and is more clear.
I'm attaching the source code, in case anyone is interested.
(note that I didn't modify the "embossed" background, so don't try using it that way)
I'm attaching the source code, in case anyone is interested.
(note that I didn't modify the "embossed" background, so don't try using it that way)
Last edited by Dougal on Sun 12 Apr 2009, 09:51, edited 1 time in total.
What's the ugliest part of your body?
Some say your nose
Some say your toes
But I think it's your mind
Some say your nose
Some say your toes
But I think it's your mind
I guess this belongs here rather than a Dingo thread:
This runs automatically on my desktop pc (which has no battery) in Dingo alpha 7, but not alpha 6. My quick read of this thread suggests that it shouldn't run for me. Is this correct?
This runs automatically on my desktop pc (which has no battery) in Dingo alpha 7, but not alpha 6. My quick read of this thread suggests that it shouldn't run for me. Is this correct?
Do you know a good gtkdialog program? Please post a link here
Classic Puppy quotes
ROOT FOREVER
GTK2 FOREVER
Classic Puppy quotes
ROOT FOREVER
GTK2 FOREVER
Yes and no, it does run at boot, but should not show up in the tray. I didn't think there was any changes between alpha 6 and alpha 7 that would effect it. If you have some time to investigate, first try booting up with the "puppy pfix=ram" option so we can make sure it's not something in your pup_save file. If it still shows up in the tray then I need some more info:This runs automatically on my desktop pc (which has no battery) in Dingo alpha 7, but not alpha 6. My quick read of this thread suggests that it shouldn't run for me. Is this correct?
1) Are you booting with any acpi=XXXXXX boot options?
2) Open a terminal and type:
lsmod
Post the output here. To copy from rxvt, highlight the text and then hold down the shift key and hit the delete key.
3) From the terminal type:
ls /proc/acpi/battery
and post the output, if any, here.
4) If ls /proc/acpi/battery gave you BAT0 and or BAT1, then from the terminal type:
cat /proc/acpi/battery/BAT0/*
also do BAT1 if it was listed and post the output here.
Thanks
Yes, it still shows up with pfix=ram
1. No
2. # lsmod
Module Size Used by
lp 12616 0
snd_mixer_oss 16896 0
snd_seq_midi 8736 0
snd_seq_midi_event 7296 1 snd_seq_midi
snd_opl3_synth 15108 0
snd_seq_instr 7552 1 snd_opl3_synth
snd_seq_midi_emul 6784 1 snd_opl3_synth
snd_seq 48080 5 snd_seq_midi,snd_seq_midi_event,snd_opl3_synth,snd_seq_instr,snd_seq_midi_emul
snd_ainstr_fm 2560 1 snd_opl3_synth
tulip 51360 0
usblp 14080 0
apm 20304 0
lmc 28808 0
syncppp 16188 1 lmc
fm801_gp 4224 0
snd_fm801 19424 0
snd_tea575x_tuner 3840 1 snd_fm801
videodev 27904 1 snd_tea575x_tuner
v4l2_common 16896 1 videodev
v4l1_compat 14596 1 videodev
snd_opl3_lib 10624 2 snd_opl3_synth,snd_fm801
snd_hwdep 9220 1 snd_opl3_lib
snd_via82xx 28056 0
gameport 14856 3 fm801_gp,snd_via82xx
snd_ac97_codec 101668 2 snd_fm801,snd_via82xx
ac97_bus 2304 1 snd_ac97_codec
snd_pcm 75656 3 snd_fm801,snd_via82xx,snd_ac97_codec
snd_timer 22020 3 snd_seq,snd_opl3_lib,snd_pcm
snd_page_alloc 10120 2 snd_via82xx,snd_pcm
snd_mpu401_uart 8320 2 snd_fm801,snd_via82xx
snd_rawmidi 23584 2 snd_seq_midi,snd_mpu401_uart
snd_seq_device 8460 5 snd_seq_midi,snd_opl3_synth,snd_seq,snd_opl3_lib,snd_rawmidi
snd 52068 15 snd_mixer_oss,snd_opl3_synth,snd_seq_instr,snd_seq,snd_fm801,snd_tea575x_tuner,snd_opl3_lib,snd_hwdep,snd_via82xx,snd_ac97_codec,snd_pcm,snd_timer,snd_mpu401_uart,snd_rawmidi,snd_seq_device
soundcore 7520 1 snd
i2c_viapro 9236 0
i2c_core 22032 1 i2c_viapro
parport_pc 31716 1
parport 35528 2 lp,parport_pc
via_agp 10240 1
agpgart 34128 1 via_agp
fuse 44052 0
unionfs 83732 1
nls_iso8859_1 4224 2
nls_cp437 5888 2
usbhid 24928 0
usb_storage 83264 0
ehci_hcd 31116 0
ohci_hcd 21252 0
uhci_hcd 24076 0
usbcore 127128 7 usblp,usbhid,usb_storage,ehci_hcd,ohci_hcd,uhci_hcd
sr_mod 17188 0
ide_cd 39200 0
cdrom 36768 2 sr_mod,ide_cd
squashfs 46856 1
3. # ls /proc/acpi/battery
ls: cannot access /proc/acpi/battery: No such file or directory
1. No
2. # lsmod
Module Size Used by
lp 12616 0
snd_mixer_oss 16896 0
snd_seq_midi 8736 0
snd_seq_midi_event 7296 1 snd_seq_midi
snd_opl3_synth 15108 0
snd_seq_instr 7552 1 snd_opl3_synth
snd_seq_midi_emul 6784 1 snd_opl3_synth
snd_seq 48080 5 snd_seq_midi,snd_seq_midi_event,snd_opl3_synth,snd_seq_instr,snd_seq_midi_emul
snd_ainstr_fm 2560 1 snd_opl3_synth
tulip 51360 0
usblp 14080 0
apm 20304 0
lmc 28808 0
syncppp 16188 1 lmc
fm801_gp 4224 0
snd_fm801 19424 0
snd_tea575x_tuner 3840 1 snd_fm801
videodev 27904 1 snd_tea575x_tuner
v4l2_common 16896 1 videodev
v4l1_compat 14596 1 videodev
snd_opl3_lib 10624 2 snd_opl3_synth,snd_fm801
snd_hwdep 9220 1 snd_opl3_lib
snd_via82xx 28056 0
gameport 14856 3 fm801_gp,snd_via82xx
snd_ac97_codec 101668 2 snd_fm801,snd_via82xx
ac97_bus 2304 1 snd_ac97_codec
snd_pcm 75656 3 snd_fm801,snd_via82xx,snd_ac97_codec
snd_timer 22020 3 snd_seq,snd_opl3_lib,snd_pcm
snd_page_alloc 10120 2 snd_via82xx,snd_pcm
snd_mpu401_uart 8320 2 snd_fm801,snd_via82xx
snd_rawmidi 23584 2 snd_seq_midi,snd_mpu401_uart
snd_seq_device 8460 5 snd_seq_midi,snd_opl3_synth,snd_seq,snd_opl3_lib,snd_rawmidi
snd 52068 15 snd_mixer_oss,snd_opl3_synth,snd_seq_instr,snd_seq,snd_fm801,snd_tea575x_tuner,snd_opl3_lib,snd_hwdep,snd_via82xx,snd_ac97_codec,snd_pcm,snd_timer,snd_mpu401_uart,snd_rawmidi,snd_seq_device
soundcore 7520 1 snd
i2c_viapro 9236 0
i2c_core 22032 1 i2c_viapro
parport_pc 31716 1
parport 35528 2 lp,parport_pc
via_agp 10240 1
agpgart 34128 1 via_agp
fuse 44052 0
unionfs 83732 1
nls_iso8859_1 4224 2
nls_cp437 5888 2
usbhid 24928 0
usb_storage 83264 0
ehci_hcd 31116 0
ohci_hcd 21252 0
uhci_hcd 24076 0
usbcore 127128 7 usblp,usbhid,usb_storage,ehci_hcd,ohci_hcd,uhci_hcd
sr_mod 17188 0
ide_cd 39200 0
cdrom 36768 2 sr_mod,ide_cd
squashfs 46856 1
3. # ls /proc/acpi/battery
ls: cannot access /proc/acpi/battery: No such file or directory
Do you know a good gtkdialog program? Please post a link here
Classic Puppy quotes
ROOT FOREVER
GTK2 FOREVER
Classic Puppy quotes
ROOT FOREVER
GTK2 FOREVER
Thanks for that. Looks like the the apm module is loaded. How old is your computer? Anyway, alpha7 changed to an older kernel. Maybe that kernel has a problem with the apm module or maybe this will be a common problem with apm computers.
Edit /root/.jwmrc-tray, you'll see this on line 23:
asapm -u 4
Change it to :
asapm -acpi -u 4
Save and then restart JWM.
Edit /root/.jwmrc-tray, you'll see this on line 23:
asapm -u 4
Change it to :
asapm -acpi -u 4
Save and then restart JWM.
Yes, that made it go away.
Computer is 7 years old, but actually has ACPI support anyway. I'm not sure why Puppy doesn't realise that.
Computer is 7 years old, but actually has ACPI support anyway. I'm not sure why Puppy doesn't realise that.
Do you know a good gtkdialog program? Please post a link here
Classic Puppy quotes
ROOT FOREVER
GTK2 FOREVER
Classic Puppy quotes
ROOT FOREVER
GTK2 FOREVER
Thanks for the feedback,
Hopefully we won't have to resort to that fix, since it just disables the battery monitor for apm. There may be a number of laptops around, that are over seven years old and would miss the battery monitor.
Barry was looking for 2.6.25 for Puppy 4 final, so maybe this is just a problem with with the apm module in 2.6.21.7. If not we could disable apm as I posted above or try to figure out when we're on a laptop if apm is loaded. I don't have a laptop that supports apm, so it's hard to test.
If one of the beta versions of Dingo gets a newer kernel would you mind giving more feedback?
Thanks again.
Hopefully we won't have to resort to that fix, since it just disables the battery monitor for apm. There may be a number of laptops around, that are over seven years old and would miss the battery monitor.
Barry was looking for 2.6.25 for Puppy 4 final, so maybe this is just a problem with with the apm module in 2.6.21.7. If not we could disable apm as I posted above or try to figure out when we're on a laptop if apm is loaded. I don't have a laptop that supports apm, so it's hard to test.
If one of the beta versions of Dingo gets a newer kernel would you mind giving more feedback?
Thanks again.
Try booting with acpi=off apm=onkirk wrote:I don't have a laptop that supports apm, so it's hard to test.
Will
contribute: [url=http://www.puppylinux.org]community website[/url], [url=http://tinyurl.com/6c3nm6]screenshots[/url], [url=http://tinyurl.com/6j2gbz]puplets[/url], [url=http://tinyurl.com/57gykn]wiki[/url], [url=http://tinyurl.com/5dgr83]rss[/url]
contribute: [url=http://www.puppylinux.org]community website[/url], [url=http://tinyurl.com/6c3nm6]screenshots[/url], [url=http://tinyurl.com/6j2gbz]puplets[/url], [url=http://tinyurl.com/57gykn]wiki[/url], [url=http://tinyurl.com/5dgr83]rss[/url]
- Dougal
- Posts: 2502
- Joined: Wed 19 Oct 2005, 13:06
- Location: Hell more grotesque than any medieval woodcut
The guy who originally wrote asapm made it refresh the display 100 times a second! Much more than we need.
I fixed it to something more reasonable, so it wakes up the cpu less.
I fixed it to something more reasonable, so it wakes up the cpu less.
Last edited by Dougal on Sun 12 Apr 2009, 09:57, edited 1 time in total.
What's the ugliest part of your body?
Some say your nose
Some say your toes
But I think it's your mind
Some say your nose
Some say your toes
But I think it's your mind
I'm running Dingo on a Compaq Presario 1200, and I've tried all the configurations mentioned, and two different battery monitors. It appears that the monitors work fine, but the OS is just not recognizing my battery.
I'd send you the results of running lsmod, but the copy function you've discussed in rxvt doesn't work, either.
Edit: I did start up Windows and check, and I have an acpi battery.
I'd send you the results of running lsmod, but the copy function you've discussed in rxvt doesn't work, either.
Edit: I did start up Windows and check, and I have an acpi battery.