bouvett
Posts: 5
Joined: Wed Feb 24, 2016 11:52 pm

Adding Custom device Inputs

Wed Mar 09, 2016 2:23 am

Hi All,

I have gone through much of the documentation and the forum but I cannot find how to add custom device inputs. I know that the GPSGATE server has standard device inputs like: Analog1, Analog2, Text1 etc.. but my device is sending other variables how can I set the server to accept these as well and then map them using the Device Mapper?

I tried going through Devices-> Types, created another device type with the aim of editing the device mapper template, but I could only remove from the standard device inputs and not add to them.

Thanks for your help guys.

User avatar
johan
GpsGate
Posts: 15403
Joined: Wed Aug 04, 2004 10:40 pm
Location: Sweden
Contact: Website

RE: Adding Custom device Inputs

Wed Mar 09, 2016 5:45 pm

Try to explain with a real world use case what you mean.

Regards,
Johan

GpsGate Support

bouvett
Posts: 5
Joined: Wed Feb 24, 2016 11:52 pm

RE: Adding Custom device Inputs

Wed Mar 09, 2016 7:03 pm

So you might have an application where the standard device inputs (Analog1 etc...) are used up and the tracker needs to send supplementary data like:

door1 = 1, door2 = 0

I want to setup the server to search/parse the location update command that it receives from the tracker for these custom device inputs as well, and then display them in the status tab.

User avatar
johan
GpsGate
Posts: 15403
Joined: Wed Aug 04, 2004 10:40 pm
Location: Sweden
Contact: Website

RE: Adding Custom device Inputs

Wed Mar 09, 2016 7:05 pm

Which type of trackers are you using?

Regards,
Johan

GpsGate Support

bouvett
Posts: 5
Joined: Wed Feb 24, 2016 11:52 pm

RE: Adding Custom device Inputs

Wed Mar 09, 2016 7:16 pm

Generic Device Tracker

User avatar
johan
GpsGate
Posts: 15403
Joined: Wed Aug 04, 2004 10:40 pm
Location: Sweden
Contact: Website

RE: Adding Custom device Inputs

Wed Mar 09, 2016 8:01 pm

You are using GpsGate TrackerOne? Use the inputs Switch1 to Switch16 for digital inputs.

Regards,
Johan

GpsGate Support

bouvett
Posts: 5
Joined: Wed Feb 24, 2016 11:52 pm

RE: Adding Custom device Inputs

Wed Mar 09, 2016 8:32 pm

No,im using generic device tracker. Im sure it is possible cause o have seen it on an implementation of an acquaintance. But i cannot figure out how.

way4net_krumnow
Posts: 38
Joined: Thu Mar 07, 2013 1:31 pm
Location: Germany

RE: Adding Custom device Inputs

Thu Mar 10, 2016 11:40 am

Adding additional input variables to an existing device is - to my best knowledge- not possible in GpsGate.

So a better way might be to use unused variables of higher types. So you might have a String type variable free but have used up all boolean? Why not use a String - that would store "1"/"0" instead of true/false? Easy to interprete. I think it possible to use device mapper scripting (http://gpsgate.com/blogComment/device_mapper_scripting) to map a string input to a boolean or analogue variable (have not tested that).

If you have really used up everything and are willing to dive into .Net dll programming (C#) you should have a look at native device integration: http://franson.com/forum/topic.asp?TOPIC_ID=9805


There it is described (with a sample project to download) how to add your own device definition and your own protocol. It should be possible (but you have to test that) to only define the device and give it the same namespace and protocol name as tracker one / generic device and then it will hopefully use the TrackerOne protocol so you could use the same commands and don't have to implement all that.

Return to “GpsGate for Developers”