I have several vehicles equiped each with individual GPS tracker sending NMEA stream to a server. 开发者_运维问答
Prior to storage at the server side, I want to be able to uniquely identify each vehicle.
Is that possible using NMEA protocol?
You'll need to see to what extent your GPS trackers support the NMEA specification.
You should be able to retrieve the data you need from the sentence$GPSTN
.
This will be received as $--STN,xx
where xx
is an ID number.
you can able to uniquely identify each vehicle by choosing port for each device.
example :
vehicle001 IP : xx.xx.xx.xx
Port 50001
vehicle002 IP : xx.xx.xx.xx
Port 50002
vehicle003 IP : xx.xx.xx.xx
Port 50003
精彩评论