I am creating an android application which gets the phones location, Latitude and Longitude, and time and sends it to a central database at regular intervals. The problem is I am using SMS to send this data and I am having trouble figuring out where to send it. The first thing which came to my mind is a computer which stores all this data and reads it then carries out an action based on the data, in this case it maps it.
So is it possible to send a SMS to a computer? Or should I try out a different method to send the data?
Any suggestions would be helpful. Thanks! :)
EDIT
I understand it is possible to connect my phone to the computer and then transfer the SMSs but I actually just have 1 phone right now and I cant have it always hooked up to the computer.
Euhm SMS? I dont think that is possible.
Try to use JSON.
https://www.google.nl/search?sugexp=chrome,mod=18&sourceid=chrome&ie=UTF-8&q=Send+data+to+server+android+json
You can connect you phone to your computer as SMS modem and get its SMS from your phone. Almost phone can do this. But the most common way is that integrated with a web service.
While it is possible to send sms to a computer if that computer has a GSM module (or mobile phone connected as modem) you should rather consider a different method.
I'd go with sending emails or - if you are willing to - create an AppEngine Project to receive the data.
Related
Is it possible to send SMS / MMS over wifi if the phone's carrier service is not working?
I have an app setup and it is sending and receiving text messages over the phone's data plan, but I want to send text messages over wifi instead. Right now it just fails over wifi.
Does anyone have experience with this?
To do that you would need to setup an sms/mms gateway from scratch https://en.wikipedia.org/wiki/SMS_gateway and I really doubt that's what you want to do.
It involves contracts with carriers and much more then just technical issues. As mentioned in a comment twillio is a pretty great way to get at it. There's a bunch of other options if you lookup sms web apis
https://www.twilio.com/ gives you a simple api to send sms/mms and more.
For the Android specific lib checkout https://www.twilio.com/docs/api/client/android
As the topic name suggests, what I am looking for is to add my android app the option to send data to a different phone running the same application so the receiving phone will process it accordingly.
The obvious option for me was to use app engine and use push notification with the phone number acting as the identifier.
Does a simpler solution exist?
Thanks ahead :)
The best and most robust solution is to have something like your messaging clients, in which Device A sends data to the server, which pushes it to Device B. Device B sends a reply to the server, which pushes it to Device A.
This process has the advantage of retrying the sending without requiring your users to stay connected, as may be required if Device B is offline when A sends a message.
A less foolproof solution is to have a server work as a middle man, and get each device's IP Address, and then open up a direct socket between them. In this solution, you'll lose any data that doesn't make it through.
If the devices are on the same network or in Bluetooth range, you could try Bluetooth or WiFi direct.
Is it possible to send SMS from Android emulator to a mobile phone via a GSM modem connected to a USB port of computer ? If it is possible how can I do that
Thanks in advance!
You could do that but android won't detect it as a native antena, in other word, all functions from android to send sms or initiate a call won't work.
If the device is visible is /dev/.. You could be able to open it and send command trough serial. Unless someone wrote a driver so android can load it for gsm communication inside the emulator, my guess is that it's pretty useless.
Anyway, the emulator does have a way to test sms sending as far as I can remember, and if you really want to send sms trough your gsm dongle, It's probably a better idea to start writing a script using python for example. There is also a library that enable sms sending from linux, it might also work on other platforms.
Sending sms from python from computer:
http://designbuildtestrepeat.wordpress.com/2008/06/26/sms-over-3g-and-bluetooth-from-python/
Checking incoming sms for emulator android:
http://davanum.wordpress.com/2007/12/15/android-listen-for-incoming-sms-messages/
Sending sms between emulators:
http://xjaphx.wordpress.com/2011/07/07/sending-messages-among-devices/
And then it really depends on what you need. You didn't exactly said why you wanted to do that. You didn't say if you wanted to test sms messaging or wanted to send actual sms from computer. It's not really clear why you need android and the gsm modem at the same time.
This is more about an explanation then it is about asking a question. What I am wondering is if its possible to write an Android application that can communicate with another Android phone, given the phone number of the phone I want to communicate with. By communicate, I mean I want to be able to send data to the phone and have my application on the other phone be able to recive it.
If its not possible to do this, then I guess my alternative is to have my application "sign" the phone into a server. Then I'm assuming the server can act a proxy to communicate with both phones.
Any clarification would be helpful!
Check out the BUMP api. It allows you to establish a connection between two (I think more are also possible) devices, and it gives you a channel over which to communicate. The devices need to be "bumped" first, but then it's all fair game.
Any reason why it has to be by phone number? That and i'm pretty sure you can only send data over WAN or local bluetooth/wifi.
Perhaps try something along the lines of a server that has phones sign into it and keeps track of the phones IP addresses allowing them to communicate almost directly to another (kind of like a dynamic DNS hah!).
Look into SMS. I haven't coded for mobile phones in years but I seem to recall that most phone operating systems let an app intercept SMS messages, react to their contents, and prevent the user from seeing them.
As long as you're not sending lots of data, SMS might do the trick.
i am writing an app that will use persons phone number (on a device) to identify the user on my network. what methods can i use to verify that the phone number retrieved from the device is real and not spoofed. i came up with two methods to do it but both of them require use of SMS:
sending SMS from a device to my server
sending SMS from my server to a device and intercepting it with my app
are there any other methods, i would like to omit using SMS if possible.
thanks
i think i found the best way to go about it. basically, i will have my app send a special text message to itself, the phone number of the device. i will of course notify the user that this will occur. my application will then intercept the SMS and will know that the number is all good. this should do it...
but these functionality is dependent to sim provider vendor... so, it's not the efficient way.. too identify... the particular mobile.. use of IMEI no. is applicable to all android devices.. if it seems significant u can use it...
ok new answer lol
your problem is then exactly the same as encrypted transfers or website register issues.
you could read up on how encryption programs transfert public and private keys to each other, I can't remember the details but if your app and your server both have a key you can use it to encrypt something like phone number+ConstantString and the phone number and then decrypt it and see if the numbers match.
jason