buZz | mornin' | 13:49 |
---|---|---|
Wizzup | yo | 13:51 |
buZz | oh man, i realized i own a second droid4 last night | 13:52 |
buZz | tried it out for battery behaviour a bit, seems -tons- better than the 'new' battery in my other one | 13:52 |
buZz | -but- dmesg still shows unable to detect the battery type | 13:52 |
buZz | yet both are legit EB41 , as far as i can tell | 13:53 |
buZz | android is happy with the batteries too, so i'm starting to think that cpcap-battery.c detection isnt working | 13:53 |
buZz | Wizzup: do you have leste running on a droid4 with legitimate EB41? could you give dmesg output? i'm curious , or pastebin /sys/class/power_supply/battery/uevent or something | 13:54 |
Wizzup | I don't have one with EB41 here atm | 13:54 |
buZz | alrighty, maybe someone else? | 13:59 |
buZz | or droid3 with original battery perhaps? | 13:59 |
Wizzup | I will have to check | 13:59 |
buZz | no hurry | 14:11 |
buZz | i wonder what the 'POWER_SUPPLY_TEMP' even means | 15:10 |
buZz | '336' its outputting here during a charge | 15:10 |
Wizzup | probably 37C | 15:11 |
Wizzup | err | 15:11 |
Wizzup | 33C | 15:11 |
buZz | oh, /10 , yeah that could work | 15:13 |
buZz | anyone else online with a recent leste that would like to share dmesg or /sys/class/power_supply/battery/uevent ? | 16:20 |
buZz | specifically while aware of batterytype | 16:20 |
buZz | oh impressive | 16:23 |
buZz | 'mplayer -nosound -fs -loop 0 bla.mp4' seems to almost fully lockup a droid4? | 16:24 |
buZz | ah, its using 'gl_nosw' as video output :) | 16:24 |
buZz | -vo sdl works :) | 16:25 |
buZz | pff, this battery in my second droid4 is somekinda superbattery? | 17:56 |
buZz | or maybe i'm finally seeing all those powersavings work :D | 17:56 |
buZz | been playing video on fullscreen with sw decoding and scaling for 90 minutes , with screen always on | 17:57 |
buZz | battery still at ~50% | 17:57 |
bencoh | so basically ... ~550mA for video decoding + display | 17:58 |
buZz | seems so, just put up backlight to max brightness | 17:58 |
buZz | trying to get a full calibration cycle in ;) | 17:58 |
bencoh | don't you use the gpu video output btw? | 17:59 |
bencoh | scaling is gpu-accelerated | 17:59 |
bencoh | (and it works great) | 17:59 |
buZz | eh, i use -vo x11 now even | 18:00 |
buZz | which gpu video output did you mean? | 18:00 |
buZz | -vo xv? | 18:00 |
buZz | i dont usually play video on the droid4 | 18:00 |
buZz | bencoh: do you run leste on your device? | 18:01 |
buZz | 16:20:42 < buZz> anyone else online with a recent leste that would like to share dmesg or /sys/class/power_supply/battery/uevent ? | 18:01 |
buZz | 16:20:55 < buZz> specifically while aware of batterytype | 18:01 |
buZz | ^^ | 18:01 |
bencoh | buZz: yeah, I run leste | 18:05 |
bencoh | I should share my mpv config file (not now though) | 18:06 |
Wizzup | uvos: btw did you saw my q yersterday about why the audio would work for tmlind ? | 18:06 |
buZz | but that request? | 18:06 |
buZz | bencoh: i'm trying to see the cpcap-battery.c work well for anyone to detect a battery :) | 18:06 |
bencoh | I don't have it right now - oh and I use stable, not -devel | 18:06 |
buZz | thats ok, should be in stable too | 18:07 |
bencoh | well, will see when I get a hold of it then :) | 18:07 |
bencoh | (do ping me in a few hours) | 18:07 |
uvos | hi Wizzup | 18:12 |
uvos | no sorry | 18:12 |
uvos | ill read the logs | 18:12 |
uvos | buZz: eeprom is exposed in sysfs | 18:12 |
buZz | eeprom? did you mean nvmem? | 18:13 |
buZz | there's no nvmem exposed in sysfs on the cpcap entries | 18:13 |
uvos | its a eeprom chip | 18:13 |
uvos | but yeah its exposed via nvmem if | 18:13 |
buZz | did you know the cpcap driver isnt even depending on nvmem? | 18:13 |
uvos | yes i know | 18:13 |
uvos | wait ill try to explain | 18:14 |
buZz | error even specifically says 'NULL device, cant find battery' | 18:14 |
uvos | yes i know | 18:14 |
buZz | on legitimate EB41 | 18:14 |
uvos | i added that | 18:14 |
buZz | i'm gonna add 'detected EB41' stuff to it aswell, once i can see it even detect something :P | 18:15 |
uvos | no dont | 18:15 |
uvos | i allready did | 18:15 |
buZz | oh, its not in the code | 18:15 |
uvos | it just got lost | 18:15 |
uvos | yeah i know it got lost | 18:15 |
buZz | i ment adding it to the code | 18:15 |
uvos | i have pachtes | 18:15 |
uvos | im currently preparing 5.16 for lestee | 18:15 |
uvos | buZz: we cant parse anything from the eeprom, its some unkown binary format thats processed by a propriary deamon on android, that motorola replaced the normal android one with | 18:16 |
uvos | buZz: additionally we also blacklist the one wire bus driver that the eeprom is on | 18:16 |
buZz | https://github.com/maemo-leste/droid4-linux/blob/wip/n900/maemo-5.15-cleaned-up/drivers/power/supply/cpcap-battery.c <- this is the one on leste now btw | 18:16 |
buZz | not what i linked yesterday | 18:16 |
buZz | uvos: oh you're saying it -never- worked? | 18:16 |
uvos | we blacklist the bus dirver because this bus has to coninously be scanned to be in spec (as to support hot plugging) | 18:17 |
uvos | unfortionally the means the device can never sleep | 18:17 |
buZz | line 424 looks weird, and 437 line and on is the detection code | 18:17 |
uvos | we would have to change the way the bus driver works | 18:17 |
buZz | so the nvmem driver? | 18:17 |
uvos | no | 18:18 |
uvos | the bus driver | 18:18 |
uvos | anyhow so yeah i never worked on leste | 18:18 |
uvos | on my device it only works because i dont have it blacklisted | 18:18 |
buZz | it* i assume :) | 18:18 |
uvos | but instead i rmmod the driver late in boot | 18:19 |
buZz | but you're not using a motorola battery i thought? | 18:19 |
uvos | then it works | 18:19 |
buZz | but 'glued in lipo' ? | 18:19 |
uvos | buZz: on one device | 18:19 |
buZz | ah ok | 18:19 |
buZz | rmmod sounds fine | 18:19 |
uvos | not really | 18:19 |
uvos | its a bad hack | 18:19 |
uvos | anyhow theres nothing wrong with cpcap_battery really | 18:21 |
uvos | just the other drivers need work (ie charger needs to negotiate and the bus driver thing) | 18:21 |
uvos | Wizzup: tmlind afaik never used calls at all, as oposed to sms/ mobile data | 18:25 |
uvos | Wizzup: there is no way i can work | 18:26 |
uvos | *it | 18:26 |
lel | IMbackK closed a pull request: https://github.com/maemo-leste/mce/pull/55 (some small typo) | 18:27 |
Wizzup | uvos: I think he did when I met him | 18:32 |
uvos | Wizzup: well its impossible with public code | 18:33 |
uvos | here ill update the bug sec | 18:33 |
uvos | Wizzup: https://github.com/maemo-leste/bugtracker/issues/584 | 19:07 |
Wizzup | maybe we need to update the issue since even speakerphone doesn't fully work right | 19:12 |
Wizzup | ah you wrote that before | 19:12 |
uvos | anyhow geting this behave right is quite the exercise in alsa expertise, i havent been able to make it work | 19:16 |
uvos | and the fokls on the alsa/asoc ml where not able to help unfortionalty | 19:17 |
uvos | or maybe im just missing how this is supposed to be implemented | 19:17 |
uvos | no driver in mainline seams to have this setup | 19:18 |
uvos | as far as i can tell | 19:18 |
uvos | but other devices must have the same problem | 19:18 |
uvos | like the pp should have the same issue iiuc how it works in hw, havent look at its driver | 19:18 |
Wizzup | ok | 19:23 |
Wizzup | > | 19:23 |
Wizzup | Anyhow if you patch the kernel to allow writes on regmaps and set CPCAP_REG_RXCOA appropriately while in a call the call audio will work absolutely fine in every way. | 19:23 |
Wizzup | I guess that would be worth a shot | 19:23 |
Wizzup | Do you have a patch to that effect somewhere | 19:24 |
uvos | Wizzup: no but if you look in the kernel where the regmap debugfs is implemented | 19:26 |
uvos | the file has a really obivous name but i dont recall | 19:27 |
uvos | theres a comment and a line you need to uncomment to make the regmaps wirtable from userspace | 19:27 |
freemangordon | this would be a terrible hack | 19:28 |
uvos | sure yeah | 19:29 |
uvos | its just for debuging | 19:29 |
freemangordon | what I don;t understand is why kernel assumes voice if to be not used | 19:29 |
uvos | it has no way of knowing its used | 19:29 |
freemangordon | so, modem is using it without kernel knowing that? | 19:30 |
uvos | yeah the kernel cant tell when the modem is playing something | 19:30 |
uvos | really whenever the kernel routes the audio to the modem it must assume that the modem is doing something | 19:31 |
uvos | but the framework dosent make this easy | 19:31 |
freemangordon | ok, but does modem have sound driver? | 19:31 |
uvos | no and the concept dosent make sense, the modem audio isent connected to cpu | 19:31 |
freemangordon | how,s that related? | 19:31 |
freemangordon | (connected to cpu) | 19:32 |
uvos | how is it not related? | 19:32 |
uvos | what would a kernel driver for modem audio even do? | 19:32 |
freemangordon | provide the bits needed to control power etc | 19:32 |
uvos | power to what? | 19:32 |
uvos | the modem | 19:32 |
uvos | the modem driver dose that | 19:32 |
freemangordon | not only | 19:32 |
uvos | anyhow in a way yes the solution is to write a modem audio driver sorta | 19:33 |
uvos | just one that dosent really comunicate with the modem | 19:33 |
uvos | but makes the framework happy | 19:33 |
freemangordon | mhm | 19:33 |
uvos | as i wrote in the bug | 19:33 |
Wizzup | freemangordon: of course it's a hack but if it helps just -testing- to see if voice calls work, I think that's nice... | 19:35 |
Wizzup | and also something I could use :) | 19:35 |
freemangordon | ah | 19:36 |
bencoh | is the mic directly connected to modem on d4? or only the speaker? | 19:38 |
uvos | both mics are directly connected ot the modem | 19:38 |
freemangordon | vute :) | 19:39 |
freemangordon | *cute | 19:39 |
uvos | however the modem cant use them | 19:39 |
uvos | without the cpus consent | 19:39 |
uvos | the cpu neds to setup the route in cpcap | 19:39 |
bencoh | which is nice | 19:39 |
bencoh | (no spying modem) | 19:39 |
freemangordon | well... | 19:39 |
uvos | on d4 and bionic (but not d3) | 19:39 |
uvos | the lte modem can setup the routes and route the mic to the modem | 19:40 |
uvos | but it cant route the mic to itself | 19:40 |
bencoh | gah ... | 19:40 |
uvos | only to the qcom modem | 19:40 |
uvos | (3g) | 19:40 |
bencoh | sounds silly | 19:40 |
uvos | so only the d3 is truely safe if the modems coperate | 19:40 |
uvos | bencoh: its just by accident | 19:40 |
bencoh | haha | 19:40 |
uvos | bencoh: the 3g modem has its own pmic | 19:40 |
uvos | the 4g modem is connected to cpcap because it uses it as its pmic | 19:40 |
uvos | btw the 4g modem's regulator is off on mainline | 19:41 |
uvos | so really it cant do anything | 19:41 |
bencoh | I see :) | 19:41 |
Wizzup | uvos: ok well if you have any hints re: what file that'd be heplful | 19:59 |
uvos | Wizzup: drivers/base/regmap/regmap-debugfs.c | 20:17 |
uvos | #undef REGMAP_ALLOW_WRITE_DEBUGFS | 20:17 |
uvos | #ifdef REGMAP_ALLOW_WRITE_DEBUGFS | 20:17 |
uvos | /* | 20:17 |
uvos | * This can be dangerous especially when we have clients such as | 20:17 |
uvos | * PMICs, therefore don't provide any real compile time configuration option | 20:17 |
uvos | * for this feature, people who want to use this will need to modify | 20:17 |
uvos | * the source code directly. | 20:17 |
uvos | */ | 20:17 |
Wizzup | ok | 20:40 |
Wizzup | maybe we need to enable this for us | 20:40 |
sicelo | callaudiod could possibly be used to toggle the register(s) when a call is established | 21:30 |
Wizzup | what is this? | 21:33 |
sicelo | Previously it was wys. It's used to handle calls when you need more than just routing audio | 21:37 |
Wizzup | wys? | 21:38 |
sicelo | Yes. Librem5 used it in the early stages of phosh | 21:38 |
Wizzup | ok, I don't know what wys is still | 21:38 |
Wizzup | uvos: ok so I guess we just change the undef into define | 21:39 |
DPA | Essentially, wys pipes some audio audio inputs to some audio outputs when there is a call (which it knows using dbus), and uses pulseaudio to do so. THe oudio devices involved are usually the modem, the speakers, and the microphone. | 21:49 |
DPA | I think callaudiod just changes some audio controls / routing instead, and may not be applicable everywhere, but I'm not entirely sure. | 21:50 |
uvos | this is not applicable to mapphones no real routing has to be done by cpu or pulse or pipewire, its all in hw | 21:58 |
uvos | i dont think enabling writable regmaps is sane for anything except on a dev machine to write a better audio dirver/ setup | 21:59 |
uvos | looking at source: callaudio just switches around pulse mixer values | 22:01 |
uvos | same thing sphone allready dose | 22:01 |
uvos | there is no problem with this part, see phinephone | 22:02 |
bencoh | buZz: http://pastebin.notk.org/pastebin.php?show=f6583f02c | 22:39 |
bencoh | buZz: http://pastebin.notk.org/pastebin.php?show=m1871afb5 battery (I changed mine a few years ago, so I'm not sure it's a legit one) | 22:40 |
bencoh | (hmm, chargefull=1371886 seems kinda low to me ...) | 22:41 |
uvos | thats really good for a oem battery | 22:41 |
bencoh | seriously? | 22:42 |
uvos | i think thats around the best oem battery i have | 22:42 |
uvos | and i have like 10 | 22:42 |
uvos | yeah | 22:42 |
bencoh | :/ | 22:42 |
uvos | i mean they are all over 10 years old | 22:42 |
bencoh | I dunno, don't they produce those for other products as well? | 22:42 |
uvos | or rather 8 the youngest i have is 8 yo | 22:42 |
uvos | bencoh: no | 22:42 |
bencoh | ah | 22:42 |
bencoh | doomed ... | 22:42 |
uvos | not really since any lipo cell will do :) | 22:43 |
uvos | the d4 having screw terminals makes this easy | 22:43 |
buZz | bencoh: 1.3Ah ? yeah pretty ok | 23:14 |
buZz | i do think we can shove more Ah in the same space | 23:15 |
buZz | bencoh: ahhh, mpv supports GLES video acceleration! nice | 23:15 |
bencoh | well, n900's polarcell holds ~1400mAh, and it's smaller, so ... yeah | 23:17 |
bencoh | buZz: I haven't looked back since I configured it (mpv/gles) | 23:17 |
buZz | bencoh: well i learnt today, the battery detection is 100% disfunctional atm :) | 23:18 |
buZz | to get it working we need a rmmod in init script somewhere | 23:18 |
buZz | as far as i understand it | 23:18 |
bencoh | ? | 23:21 |
buZz | https://www.toptal.com/developers/hastebin/raw/acikefujan | 23:21 |
buZz | that last sentence , 'i' should be 'it' | 23:24 |
bencoh | oh, that | 23:28 |
Generated by irclog2html.py 2.17.0 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!