java - Android HTC Hero not reporting back correct FeatureInfo -


i'm having strange problem htc hero 2.1
model=hero200
manufacturer=htc
apilevel=7

it not reporting has hardware microphone. here code check features.

public void oncreate(bundle savedinstancestate) {     super.oncreate(savedinstancestate);     setcontentview(r.layout.main);     context context = this;     packagemanager pm = context.getpackagemanager();     featureinfo[] foo = pm.getsystemavailablefeatures();     (featureinfo bar : foo) {         if (bar.name != null) {             system.out.println(bar.tostring());             if (bar.name.equalsignorecase("android.hardware.microphone"))                 system.out.println("booyah!");         }     } } 

it report these features:
android.hardware.camera
android.hardware.wifi
android.hardware.location.network
android.hardware.bluetooth
android.hardware.sensor.light
android.hardware.location
android.hardware.location.gps
android.hardware.camera.autofocus
android.hardware.touchscreen.multitouch
android.hardware.touchscreen
android.hardware.sensor.accelerometer
android.hardware.sensor.compass

some api level 8 compass , gps, , others level 7. there way can search features? else can use besides getsystemavailablefeatures()? maybe lower level system call? why phone not reporting has hardware microphone? please :) thanks!

i guess if phone set android api level 7... can't set requirement designed api level 8 (like microphone).

this proper way request features of phone android.

so... sucks... oh well. still weird phone report features api level 8, shouldn't rely upon that.


Comments

Popular posts from this blog

c# - How to set Z index when using WPF DrawingContext? -

razor - Is this a bug in WebMatrix PageData? -

visual c++ - Using relative values in array sorting ( asm ) -