I have a custom application on ODK Table. A call to
odkCommonIf.getProperty("deviceid") on older Android returns Phone’s IMEI number, but on Android 10 it returns a string of hex characters.
I could not find detailed description of device id in the ODK documentation. When does it return IMEI number? When does it NOT return IMEI number (because of android’s security policy)?
I don’t think there is an equivalent to deviceid, see:
I am currently trying out ODK2 to test its capabilities compared to ODK and other similar data collection tools.
While going trough the documentation of ODK2 I noticed that metadata collection, which is done in ODK by adding special question types in the XLSForm-file, is not mentioned.
Regardless, I tried to add those question types to an ODK2 application (in case it was simply neglected in the documentation), but the .xlsx file gets rejected by the XLSX Converter due to unknown que…
We generally track users in the field rather than devices to achieve a similar goal.
This is however an item that other folks have mentioned before, so if you want to add it to the features here on the Forum or raise an issue on github that will be helpful!
It looks like this is an Android 10 restriction rather than an ODK-X issue:
Starting in Android 10, apps must have the
READ_PRIVILEGED_PHONE_STATE privileged permission in order to access the device’s non-resettable identifiers, which include both IMEI and serial number.