Accelerometer Question

joebear218joebear218 Member Posts: 33
edited November -1 in Working with GS (Mac)
I am working with the accelerometer and I have a question, I understand what x and y control but what about Z?

Comments

  • jonmulcahyjonmulcahy Member, Sous Chef Posts: 10,408
    Looking at the screen, Z would detect movement when moving the phone towards your face and away.
  • SlowboySlowboy Member, PRO Posts: 329
    Really?! So if you had a top down game you could make the character jump by lifting up??
  • AuricAuric Member Posts: 35
    I made a helper app for viewing the accelerometer data. I've uploaded the project for people to download. It will *only* work on real devices.

    http://gamesalad.com/game/play/29870
  • joebear218joebear218 Member Posts: 33
    Auric do you have an example of a project that sets the accelerometer based on user orientation after a button is pushed, ie calibration of device?
  • AuricAuric Member Posts: 35
    No I haven't done anything like that yet. This app does show the X/Y/Z data.
  • VmlwebVmlweb Member Posts: 427
    I have submitted an app to the App Store called "GameSalad Devices" which lets you view Accelerometer and Touch Co-ordinates for your games.
    The Apps status is "In Review" so it should be available for free download in a few days

    More info here http://vmlweb.co.uk/page.php?15
  • joebear218joebear218 Member Posts: 33
    Vmlweb do you have a sample project that will show how to calibrate x and y for accelerometer based on the orientation of the device?
  • VmlwebVmlweb Member Posts: 427
    Are you trying to retrieve the X/Y/Z co-ordinates from your iPhone to use in your games?
  • stanimationstanimation Member Posts: 406
    I'm using the accelerometer a little differently than Auric's method. It works but not sure its the best way. How do you put up a screen shot? I'll show you what I'm doing.
  • AuricAuric Member Posts: 35
    Yeah mine was just as a test, since it just reports the raw values. I'm curious to see what others have done
Sign In or Register to comment.