webOS Nation Forums >  Homebrew >  webOS homebrew apps > Carpenter's Level
Carpenter's Level

  Reply
 
LinkBack Thread Tools Display Modes
Old 07/24/2009, 10:07 PM   #1 (permalink)
Member
 
Join Date: Jun 2009
Location: Chicago
Posts: 316
Likes Received: 0
Thanks: 32
Thanked 166 Times in 26 Posts
Default Carpenter's Level

This is a spirit level or carpenter's level that uses the accelerometer to determine the orientation. I don't find it to be very accurate, but its a fun tool to have. In the code I adjust for how the Pre doesn't sit quite straight. In my Pre this allows it to just about zero out accurately. From my testing it is accurate withing +/-.2 degrees.

As you will see, the graphics are atrocious. This app can't reach its potential without killer graphics. I, unfortunately, can't make them so it is up to you guys.

Usage info
  • have slider closed
  • place pre battery side down
  • app takes a couple seconds to zero in on the correct angle (there maybe be some jumping around)
  • remember this is an app in progress and in beta testing stages
  • card must be maximized otherwise it will pause (for battery reasons)

Well, that is it download below and leave feedback

Download the latest version from the Homebrew Apps Gallery: Carpenter's Level
Attached Images
File Type: jpg carpenterslevel_2009-24-07_220609.jpg (24.7 KB, 1191 views) Email Attachment
Attached Files
File Type: ipk carpenterslevel_0.1.0_all.ipk (26.1 KB, 1750 views) Email Attachment
Download URL:

Last edited by Milominderbinder; 08/09/2009 at 09:06 AM. Reason: add link to new homebrew apps gallery where new versions will be maintained
kmax12 is offline   Reply With Quote
Old 07/24/2009, 10:14 PM   #2 (permalink)
Member
 
Join Date: May 2009
Posts: 185
Likes Received: 0
Thanks: 13
Thanked 13 Times in 11 Posts
Default

Going to try this out...was waiting for an app like this to come along! Thanks!
drummer12 is offline   Reply With Quote
Old 07/24/2009, 10:16 PM   #3 (permalink)
Member
 
daba's Avatar
 
Join Date: Jun 2009
Posts: 26
Likes Received: 0
Thanks: 5
Thanked 2 Times in 2 Posts
Default

kmax12
Love ur apps keep up the good work. Reading and studying to someday release my own apps. Thanks
daba is offline   Reply With Quote
Old 07/24/2009, 10:16 PM   #4 (permalink)
Member
 
Join Date: May 2009
Posts: 185
Likes Received: 0
Thanks: 13
Thanked 13 Times in 11 Posts
Default

Well, works as documented...wish it was faster...oh well. Works in a pinch!
drummer12 is offline   Reply With Quote
Old 07/24/2009, 10:23 PM   #5 (permalink)
Member
 
Join Date: May 2009
Posts: 375
Likes Received: 1
Thanks: 26
Thanked 43 Times in 23 Posts
Default

I guess this is the only time I would wish the Pre had some flat edges!
dcoaster is offline   Reply With Quote
Old 07/24/2009, 10:29 PM   #6 (permalink)
Member
 
Join Date: Jun 2009
Posts: 118
Likes Received: 6
Thanks: 10
Thanked 11 Times in 9 Posts
Default

cool! of course with all the curves, leveling is difficult with the Pre. still neat, though.

Looks like some code optimizing is needed, the updates are very slow. I'm sure the hardware on the Pre is robust enough to smooth out the movement.

Keep up the good work!
sweet greggo is offline   Reply With Quote
Old 07/24/2009, 10:34 PM   #7 (permalink)
Member

 
Join Date: Apr 2003
Location: Boston-area
Posts: 6,973
Likes Received: 116
Thanks: 418
Thanked 1,252 Times in 710 Posts
Default

Quote:
Originally Posted by sweet greggo View Post
cool! of course with all the curves, leveling is difficult with the Pre. still neat, though.

Looks like some code optimizing is needed, the updates are very slow. I'm sure the hardware on the Pre is robust enough to smooth out the movement.

Keep up the good work!
Part of that is limited number of updates for the accelerometer too.
jhoff80 is offline   Reply With Quote
Old 07/24/2009, 10:36 PM   #8 (permalink)
Member
 
Join Date: Jun 2009
Location: Chicago
Posts: 316
Likes Received: 0
Thanks: 32
Thanked 166 Times in 26 Posts
Default

Quote:
Originally Posted by sweet greggo View Post
cool! of course with all the curves, leveling is difficult with the Pre. still neat, though.

Looks like some code optimizing is needed, the updates are very slow. I'm sure the hardware on the Pre is robust enough to smooth out the movement.

Keep up the good work!
actually the sdk only allows getting info from the accelerometer 4 times a second, I think I read somewhere that the iphone is 20 (maybe it was 40). Unless this is changed, it is going to be jerky. However, I am gonna try to smooth the bubble movement by animating the in between frames so it at least gives the appearance of smoothness.
kmax12 is offline   Reply With Quote
Old 07/25/2009, 12:05 AM   #9 (permalink)
Member
 
Felipe's Avatar
 
Join Date: Nov 1999
Location: Brooklyn, New York
Posts: 4,778
Likes Received: 15
Thanks: 56
Thanked 45 Times in 33 Posts
Default

hey, there is an app for that.
__________________
Felipe
On the road to 5,000 posts
Life is what happens between Firmware releases.
Felipe is offline   Reply With Quote
Old 07/25/2009, 12:57 AM   #10 (permalink)
Member
 
Join Date: Jul 2009
Posts: 22
Likes Received: 0
Thanks: 3
Thanked 1 Time in 1 Post
Default

great concept!!
oaponte is offline   Reply With Quote
Old 07/25/2009, 01:46 AM   #11 (permalink)
Member
 
Join Date: Jul 2009
Posts: 10
Likes Received: 0
Thanks: 2
Thanked 0 Times in 0 Posts
Default

Just the app I need to balance my pre on it side
uphat is offline   Reply With Quote
Old 07/25/2009, 01:49 AM   #12 (permalink)
Member
 
Join Date: Feb 2009
Posts: 8
Likes Received: 0
Thanks: 13
Thanked 2 Times in 1 Post
Default

Excellent idea. You should continue working on this app.
bogdanobi is offline   Reply With Quote
Old 07/25/2009, 01:53 AM   #13 (permalink)
Member
 
mrloserpunk's Avatar
 
Join Date: Jul 2008
Location: Syracuse
Posts: 2,564
Likes Received: 0
Thanks: 740
Thanked 442 Times in 327 Posts
Default

Quote:
Originally Posted by kmax12 View Post
actually the sdk only allows getting info from the accelerometer 4 times a second, I think I read somewhere that the iphone is 20 (maybe it was 40). Unless this is changed, it is going to be jerky. However, I am gonna try to smooth the bubble movement by animating the in between frames so it at least gives the appearance of smoothness.
is that something that can be changed or is it stuck at 4 a second?
__________________
"When there is no more room in hell, the dead will walk the earth"


PM me your questions, If I cant find an answer, I'll show you who can.
mrloserpunk is offline   Reply With Quote
Old 07/25/2009, 02:36 AM   #14 (permalink)
Member
 
Join Date: Jun 2009
Posts: 10
Likes Received: 0
Thanks: 12
Thanked 0 Times in 0 Posts
Default

Haven't tried it yet but already got a request . I always thought it would be cool to have an adjusted zero button. That way I could use it in any orientation or to replicate different readings. Thanks! Hope you continue the app!

Last edited by JWille; 07/25/2009 at 03:46 AM.
JWille is offline   Reply With Quote
Old 07/25/2009, 03:54 AM   #15 (permalink)
Member

 
Join Date: Apr 2003
Location: Boston-area
Posts: 6,973
Likes Received: 116
Thanks: 418
Thanked 1,252 Times in 710 Posts
Default

Quote:
Originally Posted by mrloserpunk View Post
is that something that can be changed or is it stuck at 4 a second?
It's the max Palm allows at the moment, so it's stuck.
jhoff80 is offline   Reply With Quote
Old 07/25/2009, 04:31 AM   #16 (permalink)
Member
 
Join Date: Jun 2009
Posts: 36
Likes Received: 0
Thanks: 1
Thanked 0 Times in 0 Posts
Default

could this be adapted to measure G-forces in a car? you know... for on-track use?
clerick44 is offline   Reply With Quote
Old 07/25/2009, 05:28 AM   #17 (permalink)
Member
 
Join Date: Jul 2009
Posts: 14
Likes Received: 0
Thanks: 14
Thanked 0 Times in 0 Posts
Default

I hope Palm increases the update refresh rate!
boxboy is offline   Reply With Quote
Old 07/25/2009, 08:41 AM   #18 (permalink)
Member
 
Join Date: Jun 2009
Location: Chicago
Posts: 316
Likes Received: 0
Thanks: 32
Thanked 166 Times in 26 Posts
Default

Quote:
Originally Posted by clerick44 View Post
could this be adapted to measure G-forces in a car? you know... for on-track use?
there is api's on plams website for G forces so it is possible. how would this be incooperated? is it just a numerical output or are there asociated graphics?
also would you only need one axis or all 3?
kmax12 is offline   Reply With Quote
Old 07/25/2009, 09:05 AM   #19 (permalink)
Member
 
Join Date: Jun 2009
Posts: 36
Likes Received: 0
Thanks: 1
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by kmax12 View Post
there is api's on plams website for G forces so it is possible. how would this be incooperated? is it just a numerical output or are there asociated graphics?
also would you only need one axis or all 3?

I would imagine a simple X/Y plot marked from 3 to -3 in .2g intervals on the Y axis and, -1.2 to 1.2 in .05g increments for the X axis. Y would represent the acceleration/braking and the X would be lateral G's. There would be a dot floating around that plots with parameters at the same time and an Actual read out that would show instantaneous and max values in each of the four directions.

AND if the programming gods smiled bright on me it would have the ability to measure and/or graph speed versus time.

Am I being greedy?
clerick44 is offline   Reply With Quote
Old 07/25/2009, 10:21 AM   #20 (permalink)
Member
 
Join Date: Jun 2009
Posts: 118
Likes Received: 6
Thanks: 10
Thanked 11 Times in 9 Posts
Default

Quote:
Originally Posted by kmax12 View Post
actually the sdk only allows getting info from the accelerometer 4 times a second, I think I read somewhere that the iphone is 20 (maybe it was 40). Unless this is changed, it is going to be jerky. However, I am gonna try to smooth the bubble movement by animating the in between frames so it at least gives the appearance of smoothness.
Surely that will be increased. The accelerometer needs to be updated quicker not only to make apps like this more useful, but for gaming. I know Palm said this isn't a high end gaming device, but ultimately the end user will decide that.
sweet greggo is offline   Reply With Quote
Reply

 

Thread Tools
Display Modes



 


Content Relevant URLs by vBSEO 3.6.0