IRC log of #maemo-devel for Friday, 2010-06-18

*** aquilo has quit IRC00:02
LullenIf I make a program that makes you add stuff, for example a exercise. Should it be in a dialog or in a window to be "maemo-style"00:06
SpeedEvilWell - if you take the example of adding a new alarm, it should pop up into a new deeply annoying window with stupid scrolly bits.00:11
Lullenokey then I'll keep it like that00:28
LullenHmm I can not even install my own app, what a failure00:29
*** SpeedEvil has quit IRC00:29
*** SpeedEvil has joined #maemo-devel00:29
Lullenhow does the autobuilder works? When going to my project page to download the .deb file I get a 110kb file, when creating the deb file on my computer it is ~7MB. It is the same code, pro file, debian folder so what can make this problem?00:37
lcukLullen, the command you are giving to dpkg_buildpackage will be different01:00
lcukand the most likely scenario is you are leaving your .git folder inside the package01:02
lcuk;)01:02
Lullenwich mean? :D01:03
lcukwell, you tell me how you build a package01:03
lcukon your machine, what command do you give01:03
Lullendpkg_buildpackage01:03
Lullento upload i use dpkg_buildpackage -sa -S01:04
lcukhave you tried extracting the package to see what extra is inside it..01:06
Lullenno I did not even know that I could do that, but why I am asking is when I download the .deb file from the project page it won't install as it is incombitable01:08
*** DocScrutinizer is now known as joerg4201:11
azakaiHello all, is there a good way to measure how much power is being used? (to check how efficient a program is, how much it will affect battery life) I can't find something clear in the wiki or forums. And things like Kill-A-Watt don't have milliwatt resolution which would be needed here01:13
SpeedEvilSeveral issues.01:15
*** joerg42 is now known as DocScrutinizer5101:15
SpeedEvilhttp://wiki.maemo.org/N900_Hardware_Power_Consumption is an overview of consumption.01:16
SpeedEvilI need to write a software power consuption page.01:16
SpeedEvilI'm in hte middle of writing a power nanalyser - but it's very much proto code as yet.01:16
SpeedEvilFirstly.01:16
SpeedEvilWhen idle, be truly idle.01:16
SpeedEvilstrace is plenty for this - your app should not be making any calls when idle, unless it truly has to.01:17
azakaiSpeedEvil: well, I am now in the process of reducing wakeups in our code (mobile firefox), and I keep getting asked "how much more battery life" will your work give. So I'd like actual battery figures, and not just # of wakeups or something else completely in software01:17
SpeedEvilSecondly, powertop gives an idea of wakeups - your app should not increase from a baseline level wakeups, when it is running but idle.01:17
SpeedEvilah - fair enough01:18
SpeedEvilAt this stage, the easiest way to do this is to install the 'power kernel' from extras-devel - and then modprobe the bq27x00_battery (or whatever it's called) module.01:18
SpeedEvilThen look at /sys/wherever/current_now01:19
azakaiis that reliable? hal-device bme results seem to show only numbers at resolution 10% or so01:19
SpeedEvilyes.01:19
SpeedEvilhangon01:19
azakaiok01:19
SpeedEvilYou sound like not a noob. This is some code stskeeps wrote to probe the battery meter.01:20
DocScrutinizer51anyway not directly correlatable to particular process01:20
azakaiah, that sounds useful01:20
SpeedEvilThis is some very prototype code - bq27200.sh probes the battery meter directly - hi.sh reads it out in a more high resolution fashion - and i2cget is used by it to read the meter.01:23
SpeedEvilwww.mauve.plus.com/bat.tar.gz01:23
SpeedEvilhttp://wiki.maemo.org/N900_Hardware_Charge_Meter has links to the datasheet for the chip01:24
SpeedEvilbriefly01:24
azakaiSpeedEvil: thanks! checking it out01:24
SpeedEvil./bq27220.sh -r01:24
SpeedEvilLOOPMODE=501:24
SpeedEvil      mv   RSOC CSOC mA   NAC  CACD CACT TTF   TTE   TEMP EDV101:24
SpeedEvil23:24 4115 100  100  180  1221 1221 1221 0     65535 303 001:24
azakaihmm, the page says I need a replacement BME?01:25
SpeedEvilit's being run in loopmode - it polls every 5 secs. Eventually, that's not relevant to this01:25
DocScrutinizer51only usefull values are mAh, current and voltage. forget the rest01:25
SpeedEvilmv = current voltage. RSOC/CSOC = state of charge in % - the difffference isn't really important. mA - positive is charging.01:25
azakaiok, cool01:25
SpeedEvilThe other ones are probably not very usefull.01:26
azakaido I need the 'power kernel' mentioned before01:26
azakai?01:26
DocScrutinizer51charge% is largely BS01:26
SpeedEvilno01:26
azakaiok01:26
SpeedEvilDocScrutinizer: Actually - once it's learned it's not.01:26
SpeedEvilBut yes, as it probably won't initially learn, it's largely bs.01:27
DocScrutinizer51but you harly ever get learn complete01:27
SpeedEvilBut - when idle - it will get around 10-12mA01:27
SpeedEvilThe battery capacity is around 1200mAh or so - so it lasts around a hundred hours fairly easily.01:27
DocScrutinizer51current now  in mA is highly accurate avrg over last Ts01:28
DocScrutinizer515s01:28
SpeedEvilReading this every 5s does not affect the power use that much. It adds a small constant, but it is fairly small.01:28
DocScrutinizer51given you have correct RS01:28
azakaihmm01:29
azakaimAh would be the battery remaining, but that isn't listed?01:29
DocScrutinizer51which regrettably Nokia fails to disclose01:29
SpeedEvilNAC = normally available capacity in mAh01:29
SpeedEvilThis will be inaccurate.01:30
SpeedEvilHowever.01:30
DocScrutinizer51might be considerably off01:30
SpeedEvilWhen discharging, it will decrease monotonically at the correct rate01:30
DocScrutinizer51diff in mAh is accurate01:30
DocScrutinizer51abs value is not01:30
azakaihmm those numbers look similar to what I saw before with hal-device bme | grep reporting, is that the same, or is this more accurate?01:30
SpeedEvilSo if it says NAC=1200 - then half an hour later - 1100 - you've used 100mAh in 1/2 hour01:30
SpeedEvilThese are more accurate in some ways.01:31
DocScrutinizer51yep01:31
azakaiok, that sounds good :)01:31
SpeedEvilIf you force several learn cycles, the battery charge meter can be really very accurate01:31
SpeedEvilBut that currently involves stopping BME, as it won't do a learn cycle without it.01:31
DocScrutinizer51btw the script isn't from stskeeps01:31
SpeedEvilI suggest skimming the datasheet on the charge meter page.01:32
SpeedEvilIt's not?01:32
SpeedEvilthe hi.sh one is the bq27200 script hacked a bit by me to just do current charge level reporting, and standby current01:32
* SpeedEvil wishes the charge counter was 32 bits - but meh.01:32
DocScrutinizer51shadowjk01:33
SpeedEvilerr01:33
SpeedEvilyes01:33
DocScrutinizer51and mine is much older still :-P01:34
SpeedEvilIn short - do ./bq27200 -r >log01:34
* SpeedEvil needs to get on with his energy profiler script.01:35
azakaiok, I will try that. Thanks guys!01:35
DocScrutinizer51yw01:35
SpeedEvilBasically poll most twiddles I can find, and try to associate wakeups and energy use to a process, and store that value.01:35
DocScrutinizer51and don't worry bout bme01:35
SpeedEvilGood luck!01:35
DocScrutinizer51SpeedEvil: timeslice*=100 might help01:36
SpeedEvil?01:36
DocScrutinizer51scheduler timeslice01:37
SpeedEvilSorry - not following01:37
DocScrutinizer51prolly 20ms now01:37
SpeedEvilah01:37
SpeedEvilPerhaps.01:37
SpeedEvilI'm not yet at that stage yet01:37
SpeedEvilI'm trying to work out what kernel structures it's sane to poll every 5s.01:37
SpeedEvilAnd what ones are too heavyweight01:38
SpeedEvilFor example - /proc/*/smaps might be nice, but...01:38
DocScrutinizer51basically proc is heavy01:38
SpeedEvilyes01:38
DocScrutinizer51man ps01:38
SpeedEvilI know that much.01:39
SpeedEvilMy questions are more what bits of proc are unacceptably heavy.01:39
DocScrutinizer51hmm difficult01:39
SpeedEvilFor example, it would be nice if I could readout per-proceess net-meters.01:39
SpeedEvilBut I think that would at least require iptables hackery01:40
SpeedEviland a recent kernel01:40
DocScrutinizer51I honestly read in a older szsop guide you shouldn't use ps too lightly01:40
SpeedEvilWell - yes - but...01:40
SpeedEvilIn some ways the processor speed has made that not so important.01:40
SpeedEvilFor example - if a wakeup takes 20ms - and polling /proc takes 10ms - you're not going to save much energy by shaving that to 1ms.01:41
DocScrutinizer51(netmeter) I wonder how cpu usage is done01:41
DocScrutinizer51probably net usage could work similar01:41
SpeedEvilThat, and it would be nice to have a more detailed breakdown of MHz/state01:42
SpeedEvilFor example - I see 34 'wakeups'01:42
SpeedEvilHow many of those were clustered in the same millisecond.01:42
SpeedEvilIn which case, they're really lightweight.01:42
SpeedEvilBut if the processor was woken out of C4...01:43
DocScrutinizer2what you want is transitions, not states01:43
* DocScrutinizer2 pops beer bottle to start the more relaxed part of evening01:43
SpeedEvilyes01:45
SpeedEvilWhat initiated the series is also more interesting thatn the series of course. For example - sms-widget polling the SMS database every 5 seconds.01:46
SpeedEvilmost of the wakeups are in other stuff.01:46
DocScrutinizer2maemo is doing really interesting stuff, like grouping alarms01:47
SpeedEvilyes - there is some really clever stuff in bits.01:48
SpeedEvilTrying to work out where it's being clever, and where it's being dumb is going to take more reading.01:48
DocScrutinizer2all that is prolly SmartReflex(TM)_the_sw_part01:49
*** DocScrutinizer2 is now known as DocScrutinizer01:49
SpeedEvilI guess that's what much of the 'i2c_omap' when idle is.01:50
DocScrutinizeri2c_omap is SmartReflex - regulator stuff01:51
DocScrutinizerI'd guess01:51
SpeedEvilCurrently also wondering if you can configure the FM radio to go direct to the phones01:51
DocScrutinizerdirect?01:52
SpeedEvilAs at the moment FMradio (a bit of software that is at least workable in its latest incarnation) goes through a/d, and d/a to get to the phones01:52
DocScrutinizeraiui it's inside BT chip01:52
SpeedEvilSo it can keep it awake01:52
SpeedEvilyeah01:52
SpeedEvilbut it comes out as L+R audio, that goes into the audio codec01:52
DocScrutinizerreally?01:52
DocScrutinizerlemme check01:53
SpeedEvilhttp://wiki.maemo.org/N900_Hardware_Schematic01:54
SpeedEvilpages 8 and 9 looks like01:55
DocScrutinizerLINE2x_PA01:55
SpeedEvilIt goes into one of the line in ports of the codec - but I haven't looked through the internal diagram of the codec to see about it properly.01:55
DocScrutinizeryep01:55
DocScrutinizerit's 2 codecs back2back01:55
DocScrutinizerweird shit01:56
DocScrutinizerL3/4 has some details01:56
SpeedEvilAnd lots of fun routers.01:56
SpeedEvilWas playing earlier with audio minimum power - got it down by some 30-40% over normal case - but still seeing 100 wakeups/second - even on aplay /dev/zero01:58
SpeedEvilWhich I guess is due to the small audio buffer.01:58
DocScrutinizer--buffer-time=5000000 (us!)01:59
DocScrutinizereven 1000000001:59
DocScrutinizeror02:00
SpeedEvilyes02:00
SpeedEvildiddn't work02:00
DocScrutinizer--period-time=100000002:00
SpeedEvil''02:00
DocScrutinizer:-/02:00
DocScrutinizerPA crap02:00
SpeedEvilno02:00
SpeedEvilPA dead02:00
DocScrutinizerooh02:00
SpeedEvilPlayed audio through headphones, captured state02:00
DocScrutinizerweird02:00
SpeedEvilkilled pulse, reset state, then aplay02:01
SpeedEvilworked fine02:01
DocScrutinizerI guess the crappy codec just has next to zero buffer02:01
SpeedEvilthe codec has exactly zero buffer02:02
SpeedEvilit's in the SoC02:03
DocScrutinizerso basically things are double buffered. one is the app buffer which you config with --period-time= and which is passing its segments to the driver. the other is a 4 words buffer in the codec and what you see are the wakeups when this one gets empty and driver needs to refill via I2S02:03
DocScrutinizerMCBSP2(4:0)02:06
DocScrutinizerCPU > OMAP343002:06
DocScrutinizerSoC -> codec digital audio02:06
DocScrutinizer.02:07
DocScrutinizerMONO_LOM_A02:08
DocScrutinizerMONO_LOP_A02:08
DocScrutinizerLINE2RM_B02:08
DocScrutinizerLINE2RP_B02:08
DocScrutinizeris the bridge between the 2 half codecs02:08
*** swc|666 has quit IRC02:11
DocScrutinizerSpeedEvil: "audio concept" 6-18 p.17802:12
DocScrutinizerin L3/402:12
SpeedEvilhmm02:13
SpeedEvilThe wakeups are not 10000 times a second - but 10002:14
SpeedEvilSo I'm assuming they are the internal SOC 'soundcard'02:14
SpeedEvilHmm - so if the two halves can be bridged under programmatic control - it should be possible to simply with the right mixer config - play radio with no CPU?02:15
DocScrutinizererr, lemme check02:16
DocScrutinizergot a ds for AIC34?02:18
SpeedEvilyes02:18
SpeedEvilhttp://focus.ti.com/docs/prod/folders/print/tlv320aic34.html02:19
DocScrutinizerty02:19
SpeedEvilI've started linking the schematic pages.02:21
DocScrutinizerLINE2xX_A is routed to A block Mixing/Muxing Volume Controls and then to LEFT/RIGHTxOx_A and HP-AMP02:26
DocScrutinizerso the answer is: positively yes, FMRX to HP is possible without any CPU02:27
*** csaavedra has quit IRC02:27
SpeedEvilneat!02:29
SpeedEvilNow - what's the betting you can't actually achieve this with the stock config :)02:29
DocScrutinizerhard to find anybody holding the bet02:29
DocScrutinizerwell, we got I2Ctools :-P02:30
SpeedEvil:)02:30
SpeedEvilI suspect alsamixer will actually do just fine02:30
DocScrutinizerI2C_202:30
DocScrutinizershould02:31
SpeedEvilyou need to add pcm.real {02:31
SpeedEviltype hw02:31
SpeedEvilcard 002:31
SpeedEvil}02:31
SpeedEvil /... to /etc/asound.conf though02:31
DocScrutinizerLOL02:31
*** t7g_ has joined #maemo-devel02:32
SpeedEvilotherwise the default goes to pulseaudio02:32
DocScrutinizerthose FR****NG F****NG bastards02:32
DocScrutinizerI guess I should sanitize the whole ALSA config02:33
DocScrutinizerthen *maybe* let in PA as a guest, later on :-P02:34
DocScrutinizernot to PCM though, maybe to DMIX02:34
SpeedEvilI wonder how much of the stock software actually talks to pulse, and how muhc just uses alsa02:35
DocScrutinizerthat's the nice thing in ALSA, each plugin's ABI is identical, and so is the PCM02:35
*** T7g has quit IRC02:36
DocScrutinizera lot uses ALSA, alas that'S the ALSA->PA comaptibility implementation (I don't want to call that a plugin)02:36
DocScrutinizernothing is using generic ALSA02:37
DocScrutinizerexcept PA02:37
DocScrutinizerand probably that's a PITA as all the policy enforcing engine is a PA bastard02:38
DocScrutinizerso none of the "scenario" switching will work without PA02:39
DocScrutinizerafk, scientific TV02:39
SpeedEvilah02:40
SpeedEvilwave02:40
DocScrutinizer51forgot this one :-P02:40
*** macbeth8c has quit IRC02:52
*** njsf_ has joined #maemo-devel03:00
*** njsf_ has quit IRC03:00
*** njsf_ has joined #maemo-devel03:00
*** SpeedEvil has quit IRC03:29
*** SpeedEvil has joined #maemo-devel03:29
*** rcampbell has joined #maemo-devel03:34
*** Aranel has joined #maemo-devel03:38
*** Aranel has quit IRC03:38
*** Aranel has joined #maemo-devel03:38
*** swc|666 has joined #maemo-devel03:38
*** swc|666 has joined #maemo-devel03:39
*** Aranel has quit IRC03:39
*** Aranel has joined #maemo-devel03:57
*** ptl has quit IRC04:09
*** ptl has joined #maemo-devel04:20
*** ptl has quit IRC04:20
*** ptl has joined #maemo-devel04:20
*** njsf_ has quit IRC04:26
*** ptl has quit IRC04:39
*** azakai has quit IRC04:40
*** GeneralAntilles has joined #maemo-devel04:44
*** ptl has joined #maemo-devel04:55
*** ptl has quit IRC04:55
*** ptl has joined #maemo-devel04:55
*** GeneralAntilles has quit IRC05:20
*** njsf_ has joined #maemo-devel05:26
*** swc|666 has quit IRC05:37
*** GeneralAntilles has joined #maemo-devel05:39
*** GeneralAntilles has quit IRC06:19
*** swc|666 has joined #maemo-devel06:20
*** GeneralAntilles has joined #maemo-devel06:26
*** uv__ has joined #maemo-devel06:54
*** uv__ is now known as uvatbc06:54
*** uv has joined #maemo-devel06:57
uvHi everyone, I'm trying to make an app that uses telepathy-qt4. I have it compiled and running on my linux machine and inside scratchbox06:58
uvI want to be able to compile it using the Nokia SDK. Here's what I've thought of trying:06:58
uvdownload tp-qt4 and extract it. Load it as a project in qtcreator, compile it, link it against my application (also loaded) in qtcreator06:59
uvand compile everything06:59
uvThe gotcha in this is tp-qt4 requires to run ./configure (I could make that a build step)07:00
uvbut is there any cleaner way?07:00
uvIdeally I'd like to be able to setup the environment to cross compile using the Nokia SDK, then compile tp-qt4 and install the compiled binaries into the Nokia SDK directories.07:01
*** GeneralAntilles has quit IRC07:06
*** Aranel has quit IRC07:07
*** GeneralAntilles has joined #maemo-devel07:12
*** njsf_ has quit IRC07:23
*** DocScrutinizer is now known as DocScrutinizer207:24
*** DocScrutinizer2 has quit IRC07:30
*** DocScrutinizer has joined #maemo-devel07:30
*** rcampbell has quit IRC07:51
*** kamui__ has joined #maemo-devel08:03
*** shinkamui has quit IRC08:07
*** timoph|AFK is now known as timoph08:15
*** tealbird has joined #maemo-devel08:22
*** kamui__ is now known as shinkamui08:33
*** uv has quit IRC09:04
*** uvatbc has quit IRC09:04
*** bricks has joined #maemo-devel09:11
*** DocScrutinizer51 has quit IRC09:17
*** DocAvalance has joined #maemo-devel09:24
*** DocAvalance is now known as DocScrutinizer5109:25
*** DocScrutinizer51 has joined #maemo-devel09:25
*** DocScrutinizer51 has quit IRC09:34
*** DocAvalance has joined #maemo-devel09:36
*** pgas has quit IRC09:39
*** frals_ has joined #maemo-devel09:51
*** frals_ has quit IRC10:05
*** frals_ has joined #maemo-devel10:09
*** pgas has joined #maemo-devel10:18
*** amigadave has joined #maemo-devel10:21
*** DocAvalance is now known as DocScrutinizer5110:27
*** DocScrutinizer51 has quit IRC10:27
*** DocScrutinizer51 has joined #maemo-devel10:27
*** achipa has joined #maemo-devel10:34
*** swc|666 has quit IRC10:34
*** csaavedra has joined #maemo-devel10:35
*** tealbird has quit IRC11:57
*** tealbird has joined #maemo-devel12:09
LullenHmm... I just succeeded to upload a package to the autobuilder(wich succeeded) that is 0kb and have no dependency... How can this be? http://maemo.org/packages/package_instance/view/fremantle_extras-devel_free_i386/qexercise/0.1-2/12:25
LullenAll I done from 0.1-1 is adding a icon, desktop file and edit the section in the control file12:25
lcukLullen, i guess the change i nthe control file did something unexpected!12:27
Lulleni can post it12:33
Lullenhttp://pastebin.ca/188565412:34
lcukLullen, and what was it before..12:36
lcuk(it might not be this but from the mods you have made its the only one that has potential to effect things12:36
Lullenhmm12:37
Lullenit was unknown at the section I guess12:38
Lullenand I removed the homepage line12:38
Lullenand editied the last line12:39
Lullen(the description)12:39
frals_Lullen: it takes one import cycle before you can see your package in packages interface13:11
frals_ie, if you check that link now its fine13:12
Lullennow it seems okey only that the homepage is not removed but anyhow... It have been imported and the section is user/utilities. I can not find it in application manager and when I try to use "apg-get install qexercise" I get the following error: "Package qexercise is not available, but is referred to by an other package. This may mean that the package is missing, has been obsoleted, or is only available from another source"13:23
frals_did you check that its imported in to -devel on maemo.org/packages/view/qexercise?13:37
*** lizardo has joined #maemo-devel13:41
LullenRepositoryLatest version13:41
LullenFremantle Extras-devel free armelqexercise 0.1-313:41
Lullenit should be right13:41
frals_sounds about right13:42
fluxis there some maemo application around that makes use of libnotify and has sources available?13:42
frals_and you did apt-get update before trying to install?13:42
Lullenyes13:42
fluxI'm trying to replicate what happens when I get new sms messages: however many messages I get, only one notification bubble is visible (I get a new one for each message)13:43
fluxalso, clicking the notification window opens the application that sent the notification; in my use, it opens a new window (which goes away when opened)13:43
frals_Lullen: apt-get install qexercise works fine for me13:44
Lullenreally?13:45
Lullenstrange...13:45
Lullencan you open up the program too?13:45
frals_flux: i think you might have to create a new "notification" group in /etc/something/rtcomgroups or something like that to get the same behavior13:46
frals_Lullen: it opened yeah13:47
fluxfrals_, ah, thanks. I found /etc/hildon-desktop/notification-groups.conf13:47
LullenThanks I'll try to reflash my device13:47
frals_flux: fwiw i tried messing with that at some point but never really got it to working despite setting the category to my own and restarting hildon-desktop13:47
frals_flux: but i was just trying to hack it quick, if you manage to solve it id love to hear about it :)13:48
fluxfrals_, I'll make a TODO note about that :-).13:48
fluxah, hildon-desktop has its sources available13:50
frals_yeah so does libhildonnotify and err13:50
frals_i think hildonsvnotificationdaemon or such13:50
fluxhmph, except hildon-desktop apparently has nothing to do with that13:50
frals_which might be interesting as well13:50
fluxyou mean hildon-sv-notification-daemon13:52
fluxapparently it's only for sound and vibra13:52
fluxbut maye the description is misleading :)13:52
fluxUnable to find a source package for hildon-plugins-notify-sv :(13:52
fluxhildon-home knows about notification groups13:53
*** csaavedra has quit IRC13:53
fluxfrals_, so maybe you were on the right track, but you should've restarted hildon-home instead?14:01
*** bricks has quit IRC14:10
frals_might have been, but i think i even rebooted device without it working :)14:16
*** tealbird has quit IRC14:26
*** csaavedra has joined #maemo-devel14:47
*** ktzqbp has joined #maemo-devel14:54
*** GeneralAntilles has quit IRC15:42
*** GeneralAntilles has joined #maemo-devel15:49
*** fiferboy has joined #maemo-devel15:58
*** fiferboy has quit IRC15:58
*** fiferboy has joined #maemo-devel15:58
LullenAnyone knows why labels don't update when changing the text when doing it in a function before(or directly after) I call window.show() ?16:15
LullenI have tried to update & repaint the label & the whole window directly after but nothing updates. If I make a button that calls label.update when pushed everything is right16:21
*** madsy has quit IRC16:22
w00t_Lullen: got a source snippet?16:24
w00t_(http://pastebin.com)16:24
*** edisson has joined #maemo-devel16:39
*** madsy has joined #maemo-devel16:54
*** achipa has quit IRC16:58
*** frals_ has quit IRC17:07
*** amigadave has quit IRC17:36
*** hellodave has joined #maemo-devel17:54
*** hellodave has left #maemo-devel17:56
*** macbeth8c has joined #maemo-devel18:20
macbeth8chi SpeedEvil18:20
macbeth8chow to set the code fragment to compile only on device?18:20
SpeedEvil?18:21
SpeedEvilDunno18:21
SpeedEvilwhat gode fragment18:21
SpeedEvilcode18:21
macbeth8cI want to use accelerometer18:21
macbeth8cif on device18:21
macbeth8c#ifdef something18:21
SpeedEvilWhy?18:21
SpeedEvilIf(exist("/sys/whatever"))18:22
macbeth8c#ifdef ARM ?18:22
lcukmacbeth8c, many arm devices exist with and without accelerometer18:25
lcukjust do as SpeedEvil suggests and test existence?18:25
macbeth8cin my case the app will be used only on N900 and PC18:27
fragmentmmee18:27
macbeth8clcuk, I am reading your post in the forum in accelerometers connected thread :D18:33
lcukmacbeth8c, i make lots of posts - link?18:33
macbeth8chttp://talk.maemo.org/showthread.php?p=28899018:33
lcukheh that was ages ago18:34
macbeth8clcuk, can I setup the accelerometer to work with scratchbox?18:39
macbeth8c(with Ubuntu)18:39
lcukwhenever i do that i find it a bit heavy and unweildy to tilt my desktop18:39
SpeedEvilMy laptop has an accel. :)18:40
lcukyeah i know :p18:40
lcukthey dont have the same branch tho18:40
macbeth8clcuk, I mean to setup some configuration what should it return18:40
lcukmacbeth8c, it just says file not found..18:41
lcukbecause hte filesystem doesnt have it - what we should have done with accelerometer is kernel driver to forward the i2c to the proper normal expected location of accelerometer stuffs18:41
lcukthen same apps would work on different machines (like laptops) without any fuding18:42
lcukfudging18:42
macbeth8chas someone done it?18:43
lcukwell i just had a function to read from the alternative location if the first one failed18:43
lcuktho i havent used it in a while18:43
macbeth8cok18:43
macbeth8c /sys/class/i2c-adapter/i2c-3/3-001d/coord18:47
macbeth8cis it regular text file on the device?18:48
lcukyes18:49
lcukrs=fscanf((FILE*) fd,"%i %i %i",ax,ay,az);18:49
macbeth8cyea I see the example18:50
macbeth8cnice18:50
macbeth8c:)18:50
macbeth8cbut why they have those oa? variables?18:52
macbeth8cstatic int ocnt=0;18:53
macbeth8cstatic int oax=0;18:53
macbeth8cstatic int oay=0;18:53
macbeth8cstatic int oaz=0;18:53
lcukmacbeth8c, original versions, reading the values raw - theres a lot of jitter18:55
lcukso the smoothing only moves a fraction towards the reported value18:56
lcukand so after ~10 calls to the function its nice and smooth :)18:56
macbeth8cok18:56
*** azakai has joined #maemo-devel19:02
macbeth8clcuk, thats good, I need to allign the picture so that it is easier for me to detect the face :)19:04
lcukcool19:05
*** timoph is now known as timoph|AFK19:08
macbeth8clcuk, beautiful I have the code for rotation. I will test it this evening on the device :-)19:15
lcukmacbeth8c, what are you writing it in?19:15
DocScrutinizer51lcuk: actually smoothing should be done in LIS30219:24
lcukDocScrutinizer51, many things should be there - is there an api for it (and calibration too)19:25
DocScrutinizer51lcuk: it's not like we want to poll LIS302 with 400Hz. Rather it should be set so it generates an IRQ whenever smoothed values change19:26
lcukexamples of it happening elsewhere?19:26
lcukand that would be worse - it only gets read per frame19:26
lcukand does change19:27
lcukmazimum is 58hz at fullres19:27
DocScrutinizer51lis302 has an adjustable highpass filter and theshold for that purpose19:27
lcukmaximum19:27
lcukso how is it spoken to19:27
*** azakai has quit IRC19:29
*** azakai has joined #maemo-devel19:30
DocScrutinizer51damn disconnects19:30
DocScrutinizer51lcuk: it's not like we want to poll LIS302 with 400Hz. Rather it should be set so it generates an IRQ whenever smoothed values change19:31
DocScrutinizer51lis302 has an adjustable highpass filter and theshold for that purpose19:31
lcuk<lcuk> examples of it happening elsewhere?19:32
lcuk<lcuk> and that would be worse - it only gets read per frame19:32
lcuk<lcuk> and does change19:32
lcuk<lcuk> mazimum is 58hz at fullres19:32
lcuk<lcuk> maximum19:32
lcuk<lcuk> so how is it spoken to19:32
*** kamui__ has joined #maemo-devel20:03
*** amigadave has joined #maemo-devel20:03
*** shinkamui has quit IRC20:07
*** janu has joined #maemo-devel20:14
janucan anyone tell how to get SIM card info ??? which API ?20:15
SpeedEvilWhat sort of info?20:17
januSIM unique info20:18
janumy application should be able to guess if the SIM has been changed20:18
SpeedEvilgconftool-2 --dump / |less20:29
SpeedEvilsearch on imsi in lower-case20:29
SpeedEvilIt's in there20:29
*** Venemo has joined #maemo-devel20:49
DocScrutinizerlcuk: what got frames to do with lis302?20:53
DocScrutinizerI mean, the whole API is fsckd up. You'd have to specify a minimum delta and a upper transit freq for a lowpass filter to smooth out "jitter", and then the LIS302 shouldn't wake CPU until there's actually a new value tuple to report, within bounds of granularity the app specified20:56
DocScrutinizerbtw almost identical considerations apply to libts20:57
DocScrutinizeras well as virtually every analog sensor you could think of20:58
lcukDocScrutinizer, i mean the orientation is read as part of the frame refresh code - just like any game etc21:04
lcuki personally dont care whether they have changed, they are just plugged into the equation21:05
DocScrutinizerhmm, for an app doing a high load sheduled workthread like video playback per-frame that's for sure ok. But what with daemons like the one that rises the dialer on turning to portrait. I don't think you'd want that one poll a sysnode on a regular basis. Rather you open a blocking read and wait for the data dropping in, so the whole proces is idle on central wait until sysnode delivers trigger in form of new data21:08
lcukDocScrutinizer, and that doesnt happen21:09
lcuktheres events for that afaik21:09
DocScrutinizerwhat's an 'event' here?21:09
DocScrutinizerevent like readf() returning with a buffer full of data?21:10
lcukDocScrutinizer, not sure, never looked into how the rotation support was implemented21:13
lcukbut afaik it comes in as either a dbus event21:13
lcukor through gtk whatnots21:14
lcukDocScrutinizer, can you get rid of the "WARNING: Trolls will be booted on first troll" from the top21:14
DocScrutinizerlcuk: if there's no other redundant way to handle e.g. accelerometer, then the coords sysnode is lowest level, and no matter which process/app/daemon/handler is dealing with it, it simply mustn't be polled21:14
DocScrutinizerme? nope21:15
lcuktheres no need at all for such a crappy warning - i dont think anyone has ever even opped up in here21:15
DocScrutinizerno chanop here21:15
*** dazol has quit IRC21:15
lcukand it just sits there talking about trolls to everyone whos here21:15
DocScrutinizeri'm^21:17
DocScrutinizerping one of the ops for it21:17
lcukwouldnt know who21:17
lcukonly op i know is you21:18
DocScrutinizerseems stskeeps has resigned on that role - thought he's been the original owner of this chan21:18
DocScrutinizer/msg chanserv access #maemo-devel list21:18
lcukta DocScrutinizer21:19
DocScrutinizernp21:20
*** Mek has quit IRC21:20
*** swc|666 has joined #maemo-devel21:22
*** Aranel has joined #maemo-devel21:23
*** Aranel has quit IRC21:23
*** Aranel has joined #maemo-devel21:23
*** Mek has joined #maemo-devel21:23
janucan anyone tell how to get SIM card info(SIM unique) ??? which API ?21:27
Venemoperhaps Mobility API?21:28
Venemobut I don't know if it is possible, because of obvious security reasons21:28
*** edisson has quit IRC21:29
lcukGeneralAntilles, are you at home21:33
*** amigadave has quit IRC21:42
*** tealbird has joined #maemo-devel21:42
*** GAN900 has joined #maemo-devel21:45
*** ChanServ sets mode: +o GAN90021:45
*** GAN900 changes topic to "Welcome to #maemo-devel | Logs: http://mg.pov.lt/maemo-devel-irclog/ | http://maemo.org/development/"21:45
*** GAN900 sets mode: -o GAN90021:46
lcuk\o/21:46
lcukkickass thanks GAN90021:46
*** amigadave has joined #maemo-devel21:48
*** amigadave has quit IRC21:49
*** ktzqbp has quit IRC21:56
*** tealbird has quit IRC22:01
Venemohi people22:03
VenemoI have a question for those who are familiar with gconf22:03
VenemoI have this line of code:22:04
Venemogconf_value_get_int(gconf_entry_get_value(gconf_client_get_entry(gconfClient, "/apps/osso/hildon-desktop/views/current", NULL, true, NULL)));22:04
Venemodoes it introduce a memory leak?22:04
VenemoI mean, should I put each of those function calls in pointers and then delete them afterwards?22:05
*** kW has joined #maemo-devel22:07
*** GAN900 has left #maemo-devel22:07
lcukVenemo, i think you should - it looks to me like it would22:09
lcuknot necessarily delete - but release afterwards22:09
Venemowhat do you mean?22:09
Venemoto me, release means the delete operator in C++22:09
Venemoor free() in C22:09
Venemolcuk: so, what do you mean by "not delete but release"?22:11
*** kW_ has quit IRC22:11
lcukgconf_entry_unref (applet_entry);22:11
Venemooh.22:11
Venemookay, thank you22:13
lcukneed to double check, but looking at code which uses the get_entry() seems to have associated entry_unref() after finishing22:13
lcuknp Venemo good luck22:13
*** BluesLee has joined #maemo-devel22:27
macbeth8cVenemo, hi :-)22:31
macbeth8cVenemo, have you solved pkg config issues?22:31
*** BluesLee has quit IRC22:31
lcukmacbeth8c, you never said what you were writing your stuff in22:35
macbeth8clcuk, you mean the lang?22:37
lcukyeah22:37
macbeth8cC++22:37
lcukin qt or just native c++ on gtk?22:37
macbeth8cqt22:38
lcukcool beans22:38
macbeth8clcuk, I hope the application will work on other smartphones as well22:39
macbeth8clike IPhone OS or Android22:39
lcukihpone wont - theres no qt allowed is there?22:39
lcukiphone rather22:39
lcukand android is written in java22:40
macbeth8coh22:40
lcuksymbian devices will work tho :)22:40
w00t_supposedly, static compilation on iPhone might be allowed. but as Qt isn't yet ported there, that's a bit academic22:40
w00t_and there is a Qt port to android22:40
lcukqt on android?22:40
lcukas in compiled to java?22:40
w00t_http://code.google.com/p/android-lighthouse/22:41
w00t_"Before we start let's clarify what is an android application? Android applications are java apps packed into a package. In this package you can also embed one or more (shared) libs which can be loaded from java code and can interact with java using JNI. Currently you can't have a binary application in the package so, qt application, embedded in this bundle, are in fact shared libs."22:41
w00t_it's a pretty awesome hack22:41
lcuknot really as the qt side would also need to interact back wit hthe java stack22:42
Venemomachbeth8c: yes, I did22:43
Venemomachbeth8c: it seems that I unnecessarily added some packages - after removing those, I don't get a timeout from sh_libdeps22:43
lcukw00t_, static compilation of X framework on iphone was pretty much mooted since you have to write xcode dont you?22:43
w00t_lcuk: http://blip.tv/file/3232378 is one of the earlier examples22:43
w00t_lcuk: no idea, I don't bother myself with i*.. just repeating some discussion that I came across the other week from people who *do* care about it :-p22:44
* lcuk nods22:46
macbeth8cw00t_, my supervisor not gonna be very happy - he is an iMan ;-)22:46
w00t_macbeth8c: well, they're a nice enough package.. i don't dislike them for the sake of it.. I just don't appreciate the lockdown and some other practices there22:47
*** silbo_ has joined #maemo-devel22:53
*** njsf_ has joined #maemo-devel23:03
macbeth8cw00t_, I must say Maemo is a good platform. TI can find only one disadvantage with the weight of device (N900)23:03
w00t_:)23:03
macbeth8chope they gonna improve weight in next releases23:03
SpeedEvilI personally don't have a problem bench pressing 180 grams.23:04
SpeedEvilHave you considered investing in a gym membership?23:05
macbeth8cSpeedEvil, you read mu mind ;-)23:05
SpeedEvilWell - the primary way to reduce weight would be by nuking the keyboard.23:05
SpeedEvilWhich I'm not really a fan of.23:05
macbeth8c*my23:06
macbeth8cSpeedEvil, do you really think the keyboard is the major factor. I had an impression that most of the weight was placed in the upper part of the device where the screen was23:11
SpeedEvilmacbeth8c: yes.23:11
SpeedEvilmacbeth8c: the keyboard itself weighs almost nothing.23:11
SpeedEvilBut that's missing the point.23:11
SpeedEvilIf you lose the keyboard, you lose the mass of the keyboard.23:12
SpeedEvilBut more importantly, you lose the mass of the slider.23:12
SpeedEvilYou lose the mass of the top of the keyboard and the bottom of the screen23:12
macbeth8cyea23:12
SpeedEvilAnd you can slim down the sides, as they are now uninterrupted, and you can get the same stiffness with less plastic.23:12
macbeth8ctrue23:12
SpeedEvilI would guess that would slice off at least 35-45g23:13
*** Venemo has left #maemo-devel23:48
*** lizardo has quit IRC23:52

Generated by irclog2html.py 2.15.1 by Marius Gedminas - find it at mg.pov.lt!