0

Iam coding a little gps tracker wo sends me the gps coordinates when it receives a sms.

It works with 2 emulators and I get the message with the gps coordinates.

Then I tried it on my HTC Desire and send myself an sms.

But nothing happend! Normally when the onReceive is called it shows a message with toast and sends an sms with gps coordinates but nothing is happening ;-/

Here the manifest:

<application android:icon="@drawable/icon" android:label="@string/app_name">
    <activity android:name=".GPSActivity"
              android:label="@string/app_name">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
    <receiver android:name=".SmsReceiver" android:enabled="true"> 
        <intent-filter> 
            <action android:name=
                "android.provider.Telephony.SMS_RECEIVED" /> 
        </intent-filter> 
    </receiver>
</application>
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
 <uses-permission android:name="android.permission.ACCESS_MOCK_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.SEND_SMS"/>
<uses-permission android:name="android.permission.RECEIVE_SMS"/>

any ideas?

Ps.: The code is in my last thread HERE

THANKS!

Community
  • 1
  • 1
Nico
  • 1,041
  • 1
  • 23
  • 39
  • is your GPS consistantly remaining active? I didn't look over the original code.. Are you attemping to deregister your listeners onPuase and then register your listeners onResume()? or just active all the time? Also normally you only need FineLocation and Mocklocaiton is only for testing. I'm assuming you want real life results at this point. – DJPlayer Oct 11 '11 at 12:15
  • Iam also not able to see ANY Toast Messages... really strange – Nico Oct 11 '11 at 12:18
  • Its just active all the time... – Nico Oct 11 '11 at 12:31
  • I am doing something similar HERE!!! http://stackoverflow.com/questions/14452808/sending-and-receiving-mms-in-android – Etienne Lawlor Jan 22 '13 at 08:33
  • Nico, Have you figured this out? – Eric Kim Apr 04 '15 at 12:03

0 Answers0