I'm in the brainstorming phase to develop a GPS car tracking system requested by a customer. I myself know the directions to build some GPS system to mobile phones and etc. But sincerely I don't know how to start in that project. That is the scenario:
1) The cars will get a device with a SIM CARD that will emit GPS signals.
2) My customer will in any place (home, work, etc) with a web connection will see in the map where the car is located.
For me, I have not problems at get the GPS data, convert to usable info and show the position in some map system (like Google Maps or MS Bing Maps, by example). My problem is, how I do to retrieve that "GPS Signal" from device in the car? I will need some kind of "Receiver Device" connected to a web server machine in order to my application to consume that data?
Most GPRS-enabled vehicle trackers can be configured to send the data periodically to a remote server. The protocol and the details of the connection will vary a lot between different manufacturers. However in most cases, you should be able to configure the tracking device with the IP address and TCP port of your server, and then you should set up an application at that endpoint that listens for TCP connections from the tracking devices.
The first thing you should check is the documentation of the tracking device. It should reveal all these details. The serious brands will even provide working examples and demonstrations.
You will have to do the following:
1) If device cannot access internet
a) Get co-ordinates from GPS device
b) Send these co-ordinates via SMS
c) Receive and decode SMS message at the SMS gateway you have to configure
to receive info from device.
d) Update the info on the application database or any other store you are using
e) Update the position on map with latest info
2) If device can access internet
a) Get co-ordinates from GPS device
b) Connect to application server (may be some service) and upload information
c) Update the info on the application database or any other store you are using
d) Update the position on map with latest info
Natively, there's no way for a stock, off the shelf GPS device to "tell" you it's position. It requires some sort of back channel to communicate that information to you.
Your options are principally:
The device broadcasts it's GPS location to you. The most effective way to do this would be if the device can access a wireless network, to install software on the device that has it periodically broadcast its location.
You use a service provider that can provide the current GPS coordinates through some sort of API.
I believe your question boils down to, "How do I send data from a mobile device to a server?" It doesn't matter that the data is GPS data or that the device is in a vehicle. You just need to understand what communication capabilities your device has so you can figure out how to deliver your payload. The device can receive GPS satellite data, but that is one-way communication. You also said the device has a SIM card, so that means you've at least got voice network capability. Will the device/account have a data plan? If so, then that gives you GPRS/3G/some-packet-data and you would be home free. If not, then SMS is probably the next-best option, using a service like OpenMarket, for example. A last resort: your company can potentially license/develop a data-over-voice modem. For this route, it matters which country you are in. In the US, Airbiquity holds a lot of patents for this, and you'd probably have to license from them.
Our company uses the GenX Mobile devices in our truck fleet. They have a data connection that sends the raw CSV data to a UDP socket. I wrote a little listener app that gathers the data and puts it into a MySQL database.
If you have a droid, play with some of the apps on there, including Google's Lattitude, Where R U, and Mobile Defense. That'll give you ideas on what some of your options are, for apps that periodically report the location back up to the mothership. Have a look at WebSharing, for an excellent example of a webserver running within a droid, which lets you do things. That app is for file sharing, but it's not a stretch to imagine the interface (beautiful, btw), showing the car location, speed, heading, and with big "kill ignition" and "lock doors" buttons.
A point to consider is the communications channel used to pass the tracker position back to the data centre. In Europe the GSM network is well developed and can be used (SMS or GPRS) to pass the position data. However there are large roaming charges to be considered if the application is intended to follow a vehicle across international boundaries. In other countries (USA, Canada, Africa, Asia) the terrestrial infrastructure is not so well developed or uses a different transmission system (CDMA rather than GSM) requiring a different modem device.
An alternative, actually pretty price comparable with GSM, is to use satellite comms as the back channel. These are available either using Iridium or Inmarsat services and work globally, in remote regions without mobile phone coverage and without any roaming charges as the unit crosses borders.
Related
I'm about to purchase a Datalogic Matrix 300N fixed barcode scanner. I already downloaded and played with DL.CODE, this is the software to configure and emulate Datalogic Matrix scanners.
The idea is to collect and process the scanned barcodes on a Windows host with a Windows .NET C# application or service that has to be written by me.
As far as I can see now, the Matrix scanner could act as TCP Server and I can connect from my C# application (with TcpClient) to that Matrix TCP Server. However, there's no documentation or whatsoever available. Also I'm in doubt whether this is the right way to process barcodes in an production enviroment.
What would be the right way to set this up? Is "Matrix TCP Server" the way to go, or should I look out for other ways of communication? (ID-Net? Ethernet/IP? Modbus? Profinet IO? HMS Fieldbus?)
It seems that there are manuals of matrix_300n_reference_manual and matrix_n_family_host_mode_programming in the Manuals & Technical Literature column of Downloads for Matrix 300N.
Likewise, there appears to be the DL.CODE Configuration Tool etc. in the Software & Utilities column.
If you can not understand with them, why do not you contact Datalogic Technical Support?
or Contact Us?
You send a UDP broadcast to see which devices are present on a network and process the response. Once you have the device address you open a TCP/IP connection, hang async reads on it, let the scanner know via a send that you are listening, and process the async traffic received. While this is dependent on your receiving system., it is working in a client's production system at about 100 scans per second coming from multiple scanners.
I would like to get a Bluetooth tracking device such as TrackR, Tile, Chipolo, ... and write my own app to detect my devices on a Windows 10 Mobile device. Are they encrypted in some way so that only their app can use them?
Can anyone point me in the right direction for doing that? Or tell me that it's impossible.
Detection is independent of encryption.
Let us call the main device with which other devices should be detected the "Central", and these other devices "Peripherals".
Every Peripheral that wishes to be detected has to send advertisements. There are several advertising modes; without going to much into detail, these different modes are for allowing the peripheral to be discovered, or to be connected with, or both.
All these advertisements are unencrypted, so any device can "see" and understand these advertisments. A Central just has to go into scanning mode; in this mode, the Central listenes for any advertisements it can detect. After finishing the scan, all found devices are presented in a list. There is no encryption here; encryption only comes into play after two devices have connected and at least one devices demands encrypted communication. But this is not necessary for finding and identifying devices.
Note that the only information you can get without connecting is the advertisement data (and possible some additional scan response data). Typically, a short device name or identifier is part of the advertisement data to allow for identification of the device type. If the device implements the Device Information Service, each information there can also be read without encryption (but you have to connect and discover this service first). Most devices will want the Central to know their name, type and purpose, so typically that information will not be encrypted.
I am creating a "tracking system" for my android phone. Basically, the phone would transmit it latitude/longitude to a C# program that will receive the coordinates and display it on a map. I managed to get the phone's latitude/longitude coordinates but I need a way to transmit that data to my C# application running in my PC. I know my way around C# and Java but never really got into network programming. Is there a way to do this ?
I'd look into C# Webservices, very powerful. The communication protocol is SOAP (Simple Object Access Protocol) which is a popular and well supported standard.
Good starting reference: Your first C# Web Service
I can't speak to the C# side of it, but if you write a C# server to receive post requests, the Apache HttpClient makes it relatively simple to send requests. There are a bunch of other questions on SO that will help with setting up the client side on your phone if you poke around a bit.
You have different way to do it.
The first is to send data over the cloud to interact through distant server. So the both devices have to be connected to Internet
The second id to send the data over a local network so the data have to be on the same network and have to share their IPs
The third is to use adb forward which allows to build a socket connection between the 2 devices over a USB cable. The requirements are that the phone have to be on debug mode I think and that the driver are installed on the PC so the phone is recognized by ADB.
I can add one more by using a Bluetooth connection. Find information here
The correct way to do it would be to build WCF service which allows many different protocols to receive data. This would could be a very powerful solution that can be extended in future.
The fastest and easiest IMO would be to create ASP.NET MVC application, define a POCO Model for your longitude/latitude and create an action that would take your Model as parameter. Then use HttpClient and HttpPost on android to send the data. The trick here is to name the variables in your post request same as ones you define in your C# Model.
this is my first question here, after searching and reading through many places I have not choice but to ask.
I have a C# application that receives data from a GPS device and stored in a database, I need now is to send a string that contains commands which the device should be interpreted.
This device connects to the Internet over GPRS, I haven't idea how to send this packet over TCP over GPRS because the IP is dynamic.
I hope any suggestions or ideas on how to solve this.
Best regards.
You should do it the other way around - the device should poll the server for instructions. Just make sure the server is accessible.
As you have specified that you have developed a C# application to read the GPS data through GPRS that means you are running C# application on a public/static IP.
Nwo as soon as you get a request from the GPRS client, you get the DHCP IP address of the remote endpoint too.
Once you have that endpoint and socket open, you can transmit any data to the GPS device back.
Assuming that your GPS device is having some microcontroller to drive the GSM/GPRS modem.
I'm going to make an assumption here that the 'Device' is some kind of mobile phone connected to a standard GSM network?
If it is, then the short version of the story is "Forget it" even if the IP wasn't dynamic, you simply wouldn't be talking to the IP of your device, you'd actually be talking to the IP address of your providers GGSN, and for a standard consumer connection this is going to be where the buck stops.
Now that said, IF you have the budget, and all your devices (Assuming multiple ones) are with the same carrier, then you can approach the carrier and request a dedicated APN (Access point name) essentially what this is , is the mobile network equivalent of a DNS record, or at least similar enough to use that analogy anyway.
When you set up your data connection on your device you may recall having to enter something like 'pp.vodafone.com' or 'INGhub411.o2-uk.inbound' we'll this is your actual APN, and if you have a custom one they your devices can be set up so that the IP the presents itself at the GGSN actually has a static route back to the individual device in the suppliers GSM network.
As a general rule of thumb however on consumer grade connections this is not enabled and hence there is no ingress available to the individual device.
As zmbq says, the ONLY option you have is for the device to keep polling the server on a regular basis, and yes unfortunately that is going to be very unforgiving on the battery.
of course there is one other way of approaching this, and that's to have the device open a socket directly to your server then keep that socket open. Once the socket is open, 2 way communication can be performed across the link, unfortunately your going to also have to write all the code to manage this connection including, but not limited to monitoring the connection to make sure it's still open and re-establishing it if it's not, something which is incredibly important on a mobile device.
I have PC and VOIP phone. When someone calls to my account and I answer it using VOIP phone, I want the phone number to be stored on my PC.
What is the easiest way to receive caller number? Is finding a VOIP Java/C# SDK and developing my application (just to get a caller number) the only way or are there some clever shortcuts?
Note: I am familiar that softphones are displaying the callerID but there is no (reasonble, non hack'ish) way I can read it from softphone.
Depending on your softphone you might be able to configure it to save a calls log. Alternatively you could obtain CDRs (call detail records) from your VOIP server.
Another route to go would be to monitor incoming VOIP TCP connections and extract caller data from sniffed packets.
Or you could write a small program that will run in background and check periodically which is the active window. If the active window is your softphone, then it will take a screenshot and dump it to a folder.
What Vlad said. Providing the hardphone model details will get you more details :-)
If the PC is sure to be on all the time you want to operate the phone, you can install a simple SIP proxy on the PC that does nothing but logging.
If a softphone is an option, many of them can be scripted, I love twinkle for example.
Using wireshark (or more to the point tshark, the command-line version) you can build a capture spec that will only capture incoming SIP packets on UDP port 5060, and then only if the SIP msg is INVITE. Then you just have to look at the "From" line to see who called you (if it's filled in; it should at least have a number).