Does anyone get
-[UIAccelerometer bytes]: unrecognized selector sent to instance 0x1a23f0I do init the accelerometer:
UIAccelerometer *accel = [UIAccelerome开发者_如何学JAVAter sharedAccelerometer];
accel.updateInterval = 1.0f/30.0f;
accel.delegate = self;
The reason I am asking is that on some devices the app works, and on others just crashes. And I am not sure what is the reason.
Thanks!
This sounds as if you send the accelerometer a bytes
message, which it doesn't implement. The code you show doesn't have a problem, maybe do search for bytes
and double-check that usage.
精彩评论