maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   n810 as a biking computer? (https://talk.maemo.org/showthread.php?t=27773)

aki 2009-03-22 21:28

n810 as a biking computer?
 
Since I didn't see anything like it yet, I've just thrown this up.

It's an incredibly crude program (It's my very first maemo app and even C!) so good luck with it ;) It works for me so perhaps someone else might possibly find it useful

http://disconti.nu/n810/cycling/bikecomp-a00.png.

It shows the
  1. current speed
  2. distance travelled
  3. time elapsed since program start
  4. a 500 second graph of speed
  5. current time
It throws the data it gets from gpsd into a file in the same directory as the binary called "gps_log.txt". I was hoping that I could get the nmea data but couldn't quite figure it out. It also keeps the screen on during use via display_blanking_pause osso call.

I've given up on the internal GPS and use an external bluetooth one instead.

It's just a single binary and you can download the bashed together version

Note, I had to update /var/lib/gps/gps_BT_devices before it recognized my external gps. Not sure what's up with that. Writing in gtk/hildon/etc is still kind of voodoo for me.

It's rather inaccurate. I'm up to 5km/h sitting down and when walking around, I've managed to get to 15km/h. I've got really long legs! :) Tried using the velocity data from gpsd but I only received that information intermittently so I'm now just calculating the velocity myself using a 5 second average.

If anyone thinks they could do a better, job, well, PLEASE DO! :D I got a wee bit desperate so ended up throwing this together. I'd be thrilled if someone that knew what they were doing could code something.

Thesandlord 2009-03-22 21:34

Re: n810 as a biking computer?
 
There is an app called speedometer, and it does relatively the same. Also, there is eCoach, which is perfect for this kind of thing.

aki 2009-03-23 01:05

Re: n810 as a biking computer?
 
Thanks for that, I've never heard of either of those apps. Speedometer looks quite promising. Unfortunately, while ecoach looks absolutely awesome, it's probably not for me: I must be getting old, I can't read text that small when I'm riding :(. Might end up using both at the same time though since the post-analysis abilities are intriguing.

Cheers!

ciroip 2009-03-23 13:02

Re: n810 as a biking computer?
 
Quote:

Originally Posted by aki (Post 273777)
Since I didn't see anything like it yet, I've just thrown this up.

I was planning to make a gps application with a biga** display like your but Im still limited to my poor python skills (that should access pretty easily to gps through 'easy' module . I was thinking to dive a bit into C so I would love study your code for 'inspiration' :) :
any chance to have the source?
In any case Kudos and thank you for sharing.

aki 2009-03-23 16:02

Re: n810 as a biking computer?
 
Quote:

Originally Posted by ciroip (Post 273876)
I was thinking to dive a bit into C so I would love study your code for 'inspiration' :) :
any chance to have the source?

Sure, please feel free. I'll release it to the public domain. Do it become so if I just say it? I hope so, it'll be like magic! *waves arms* it is away! If it makes anyone so frustrated about bad code that they hurt themselves, it's not my fault! ;)

I would say though, that you should probably study someone else's code if you want to learn something. Speedometer seems to have some nice stuff in there regarding event hooks and such. This code was mostly auto-generated via glade-2 with my little bits and bobs bunged into main.c

ciroip 2009-03-23 16:12

Re: n810 as a biking computer?
 
Quote:

Originally Posted by aki (Post 273901)
Sure, please feel free. I'll release it to the public domain. Do it become so if I just say it? I hope so, it'll be like magic! *waves arms* it is away! If it makes anyone so frustrated about bad code that they hurt themselves, it's not my fault! ;)

I would say though, that you should probably study someone else's code if you want to learn something. Speedometer seems to have some nice stuff in there regarding event hooks and such. This code was mostly auto-generated via glade-2 with my little bits and bobs bunged into main.c

I like challenges and I'm from the 'bad code fast release' school.
If it'll hurt too much I can always give up with serious high alcohol programming and return drinking my python milkshake...

aki 2009-03-23 16:39

Re: n810 as a biking computer?
 
Quote:

Originally Posted by ciroip (Post 273904)
I like challenges and I'm from the 'bad code fast release' school.... python milkshake...

Wait..., "bad code fast release" and "python"? I didn't think that was possible.

I'm normally a perl programmer: I thought that's what python coders teased perl programmers about. ;)

sondjata 2009-03-23 17:53

Re: n810 as a biking computer?
 
It would be nice to have the elevation changes recorded as well and available as a graph as you did with speed.

sondjata 2009-03-23 17:54

Re: n810 as a biking computer?
 
Perhaps like how they do for Le Tour

danramos 2009-03-23 18:58

Re: n810 as a biking computer?
 
Personally.. I would prefer to see this application continued. I like where it's going as a dedicated biking app--the idea of show elevation and/or showing it as a 500 second graph alongside or instead of the speed graph would be EXCELLENT.

It would be darned near perfect if it would also write out a trip file so that it can later be reviewed on Google Maps or in some fitness sites or software.

Thanks for releasing the source, btw. As far as what you need to do, you're automatically the copyright owner--just put your license (public domain, GPL version x, etc.) in the C header. I think that's all you need to do.

aki 2009-03-25 21:15

Re: n810 as a biking computer?
 
I've decided and started to just recode the thing from scratch.

Anyone around here a cyclist/hci person that I can ping for advice?

And what features do people want? I'm going to start small but may try to work in more as time goes on.

superbondbond 2009-03-25 22:21

Re: n810 as a biking computer?
 
Quote:

Originally Posted by danramos (Post 273950)
It would be darned near perfect if it would also write out a trip file so that it can later be reviewed on Google Maps or in some fitness sites or software.

I second that danramos. The program could simply save a gpx track of the trip, with a start/stop/reset toggle to tell it what to do.

sondjata 2009-03-25 22:43

Re: n810 as a biking computer?
 
My needs are simple. I'd like a record of how fast I was going over time. You may decide to show a set of that speed on screen as you showed us, but to have that stored and available after the ride would be nice.

Also a record of our altitude over time would be very helpfull since many of us will want to know how fast we've gotton going uphill. If you saw the last Tour then you know how important that is.

To have a summary screen that showed the changes in altitude over the duration of the ride overlaid with speed (say altitude in greeen and speed in red) would make such things easy to read.

Since I have no intention of mounting my n800 on my handlebars I really don't care too much about the interface but I would love to be able to see the aformentioned data when I'm done. Others of course will have different needs.

sondjata 2009-03-25 22:44

Re: n810 as a biking computer?
 
Oh yeah. If it would be possible to show the altitude graph like they do in coverage of the Tour (with categories) it would be appreciated. I assume that would involve some sort of calculation of the change in altitude over a given distance.

rattking 2009-03-25 22:50

Re: n810 as a biking computer?
 
Hey this sounds cool
you could also add Calories burned.. i think its calculated from bmi and speed

Thesandlord 2009-03-25 22:59

Re: n810 as a biking computer?
 
Personally, I run speedometer to measure speed, eCoach for post-analysis, and Navit for maps. Oh how I love multitasking...

sondjata 2009-03-25 23:32

Re: n810 as a biking computer?
 
e-coach looks good but the Speed/altitude picture looks really odd. Is that a test screen? because those changes in altitude are nuts!


All times are GMT. The time now is 13:30.

vBulletin® Version 3.8.8