I am developing an app that requires high speed motion data (approximately 80hz). As of iOS 10 my app is reporting that motion data is coming in only at 67 Hz. In iOS 7 through 9 the same exact code was report a stable 80 to 81 Hz.
Has anything changed in CMMotionManager that would be causing this slow down?
This appears to be a bug in iOS 10. If the requested Hz setting set on CMMotionManager accelerometerUpdateInterval is between 60Hz and 89 Hz, motion data will come in at 67 Hz. And if it set to 90Hz or above, the motion data will come in at 100Hz. Anything below 60 Hz behaves as it did before iOS 10.
Edit: I did some more checking across a broad selection of updateIntervalSettings on both iOS 9 and iOS 10. And what I found is that any setting below 50 Hz works as expected but if you set speeds above that you will get unexpected update intervals for the motion sensors. The most egregious error I found was on iOS 9 when the update interval is set to 80 Hz the sensors were reporting in at 47 Hz.
Related
Currently I am making Augmented Face application
In this application ı have a slight problem
My camera FPS rate is between 20-25 how can i make it 30 fps stable?
İ am using S9+
I disabled everything even scene is empty but when arcore session starts it drops to 15 - 25 fps.
I am using Unity 2019
We are writing a pair of Core Bluetooth applications. The MacOS application is implementing a CBCentralManager and the iOS application is implementing a CBPeripheralManager. The iOS peripheral's UIBackgroundModes key is set to bluetooth-peripheral in its Info.plist file.
The apps are paired and are successfully sending messages back and forth over Bluetooth every 30 seconds. This works whether the iOS app is in the foreground or background.
The Mac application is receiving the RSSI value of the iPhone. With the iPhone sitting next to the Mac the RSSI value fluctuates generally in the range of -45 to -65 dBs (with occasional drops to -75 dBs). But after an extended length of time without the iPhone moving the RSSI drops to a range of -55 to -75 dBs (with occasional drops to -85 dBs or more).
The graph below illustrates the behavior. The X axis is time in seconds and the Y axis is dBs. In this example the RSSI stays in the range -45 to -55 dBs for 300 seconds. But then for seemingly no reason the RSSI drops to the range -55 to -75 dBs and stays in the range indefinitely.
During this period of lower RSSI value the apps continue to successfully send messages back and forth so it does not appear that the iOS app has been suspended.
At about 600 seconds the iPhone is picked up (which is appears to be correlated with a small uptick of RSSI value) and then the iPhone is moved 20 feet away (which causes the RSSI to drop as we expected). Then at 900 seconds the iPhone is moved back to its starting location which corresponds to the last rise in RSSI value.
We are obviously expecting the RSSI value to drop when the iPhone is moved away and to increase when the iPhone is moved close again.
But we have no explanation for why there was the initial drop of RSSI value at around 300 seconds. Our problem is that we cannot differentiate between the RSSI dropping for that unexplained reason and the RSSI dropping because the iPhone is moved away from the Mac.
Questions:
1) Is there an explanation for the RSSI dropping on its own without any change in the environment? Could iOS be reducing the Transmit Power?
2) Is there any way to prevent the RSSI from dropping or force it back up programmatically?
3) Is there a way to programmatically recognize that the system has reduced the signal strength which would allow us to calibrate subsequent values?
Any explanations, fixes, and/or suggestions would be greatly appreciated.
RSSI vs Time (in seconds)
I would like to limit the microphone's input frequency for an iOS Application I'm developing which is going to run on all versions of iPhone available in market as of 22 March, 2016.
The microphone will only record if a certain frequency threshold is reached and won't be recording below that threshold.
Any idea on how to achieve this programmatically?
I want to simulate how the old CRT screens work on my iPhone.
I need any ideas.
EDITED:
I'm interesting in 29.97Hz
You can't simulate the actual flicker of a CRT on an LCD display. However, if you're looking to make a scene or portion of your game look like it's on a TV, you can do any of a few tricks.
TV shows are typically 24 Hz. DVD's go up to 29.97 Hz. A little known fact is that Disney, like many animation studios, only animates at 12 Hz and shows each frame twice to achieve the 24 Hz. This means that to get the stutter associate with animated films, 12-15 Hz is your goal.
As already stated, LCD, LED, or Plasma displays are solid pictures, not strobed as CRTs are. You need to add strobing. I've found adding a single white frame every 3-4 frames add the desired effect. Typical game frame rates are 60 Hz, so a single frame lasts for 1/60 sec (or 16.7 ms). If every 4th frame is white, you get a flash simulating a refresh rate of about 15 Hz.
you cannot simulator the properties of CRT screens that make them flicker when recorded using a camcorder on a non-refresh recording frequency, LCD displays don't update the screen partially like CRTs do.
I read that frame rate is 30 or 60 in Corona Sdk. However in my piece of code, the numbers are written 33 times with enterframe listener. Can you explain the reason to me, please?
local start=os.time()
local function countDown(event)
if((os.time()-start)==3) then
Runtime: removeEventListener("enterFrame", countDown)
end
print(os.time()-start)
end
Runtime:addEventListener("enterFrame", countDown)
These two values 30 or 60 are the max limit that you want in your app but it depends on device hardware if it will be able to reach that limit.
From Corona site:
Frame rate control
By default, the frame rate is 30 fps. We now allow you to optionally
set the frame rate to 60 fps by adding the fps key to config.lua
If you want to have higher fps rate you should optimize your code. Maybe you are drawing too many images.
Check this post:
http://forums.coronalabs.com/topic/32962-low-fps-on-android-hd-devices/
and this blog post (8. Conserve Texture Memory):
http://www.coronalabs.com/blog/2013/03/12/performance-optimizations/
For more info check this:
http://developer.coronalabs.com/content/configuring-projects
Here is a library to show on screen FPS and texture memory:
http://developer.coronalabs.com/code/output-fps-and-texture-memory-usage-your-app