I have a requirement like the motion of the device in vehicle while driving should be detected when the application is in background. When the motion is detected the app should start automatically and move to foreground from background in iOS 7. I read that it is possible using CMMotionActivity Manager but have no exact clue to implement this functionality.
Related
I am developing an iOS app kind of similar to functionality of Apple's air tag tracker app.
My app doing dead reckoning using CMPedometer and Accelerometer. Dead reckoning should start after receive a accurate gps location (I have enabled Location updates background mode)
There are some calculations execute at the same time to measure walking distance, calibration algorithms to dead reckoning and communicate with the target object via bluetooth once the user(app) is in communicating distance with the object.
In this case, target object act as Bluetooth central and App act as the bluetooth peripheral. So, I have enabled Acts as a Bluetooth LE accessory background mode as well.
Currently I have implemented the dead reckoning and calibrations. App working in the foreground. But the main requirement is to work in background also.
I have read few articles and documentation about iOS background modes and it seems very restricted to execute algorithm.
My intention is to start dead reckoning and algorithm based on a trigger from gps or bluetooth device.
At thing moment, I still haven't implement any codes for background processing, more of a feasibility study at the moment. As per my understanding Background fetch and Background processing both scheduled by the iOS, so these two ways will not help. Possible ways could be act upon a bluetooth trigger, act upon a location update or background push. Highly appreciated your thoughts on these approaches.
https://developer.apple.com/forums/thread/685525
https://developer.apple.com/videos/play/wwdc2020/10063/
https://developer.apple.com/documentation/xcode/configuring-background-execution-modes
I am building a location based app. But, when my app is in the background, location updates continue and it drains the battery. So I chose to use Core Motion to detect if user is in Automotive mode, and only use Core Location if that is the case, and not update locations otherwise. But the Core Motion chip sleeps in background mode and I don't get data.
How can I keep the Core Motion chip awake while my app is in the background?
How to detect the device is falling down or moving upwards in Objective-C or Swift? The Core Motion only detect the movement when we tilt the device I need to detect the free fall of the device. Is there any relevant sensors calculating the falling speed of the iPhone?
Apple iPhone 6 has integrated barometer sensor so this might be the sensor that you are looking for. To access barometer data you will need to use CMAltimeter and CMAltitudeData classes
i want to make Step Counter in Blackberry OS 7. I want my app count every user motion. But i don't know how to detect vibration / motion using Accelerometer like SensorEvent in Android. Anybody can help me ?
I have develop an application from the ipod touch 4 but unfortunately it doesnt occupy a proximity sensor, But i want to start and stop a certain event by triggering the brightness of the camera, Is this possible to implement? if so, does it consumes more CPU? and also Can i use both cameras?