Using hardware components in Android (Java)
Hey, Sorry to bother you with such a silly question, but I can't find the answer myself.
I'd like to use hardware components in my applications (or: sensors), but it seems that I don't have the necessary files, as writing import android.hardware.Sensors;
causes an err开发者_StackOverflow社区or ("The ... cannot be resolved"). It is weird because I can import all other classes without any problem; I've downloaded the SDK. So what is wrong?
Thank you in advance.
are you sure it isn't import android.hardware.Sensor; instead of import android.hardware.Sensors;
grtz
Sensors information can be used with help of SensorManager
.
You mean import android.hardware.Sensor;
. See http://developer.android.com/reference/android/hardware/Sensor.html.
精彩评论