I can get the corona remote to connect to my computer and the sample programs work well. The problem is using the remote with my app. The accelerometer works when I build to an IOS device and actually test it on my physical Iphone. So, I need help with my code, I need help getting the remote variables to work with my app. Below is the code I use to run the accelerometer.
[lua]local motionx = 0
local motiony = 0
local function onAccelerate( event )
motionx = 30 * event.yGravity
motiony = 1 * event.xGravity
end
Runtime:addEventListener (“accelerometer”, onAccelerate)
local function moveball (event)
circle.x = circle.x - motionx
circle.y = circle.y - motiony
end
Runtime:addEventListener(“enterFrame”, moveball)
local function onTilt( event )
physics.setGravity( 10 * event.xGravity)
end
Runtime:addEventListener( “accelerometer”, onTilt )
[import]uid: 82872 topic_id: 28388 reply_id: 328388[/import]