Importa data from gps NMEA format in Influxdb

Hi all,

I’m here to ask for your help, I’ve been going around forums for days trying to get what I want but coming up with no results.
Every second i receive data via UDP from two gps in NMEA format; with python pynmea2 library I can decode the gps strings, below is an example:

data = “$GPGGA,121501.00,4443.35240977,S,16914.59591748,E,2,07,1.4,355.389,M,5.081,M,6.0,0122*6D”

msg = pynmea2.parse(data)

msg
<GGA(timestamp=datetime.time(12, 15, 1, tzinfo=datetime.timezone.utc), lat=‘4443.35240977’, lat_dir=‘S’, lon=‘16914.59591748’, lon_dir=‘E’, gps_qual=2, num_sats=‘07’, horizontal_dil=‘1.4’, altitude=355.389, altitude_units=‘M’, geo_sep=‘5.081’, geo_sep_units=‘M’, age_gps_data=‘6.0’, ref_station_id=‘0122’)>

Now I would like to import all these data into influxdb, can someone kindly tell me how to do?

Thanks in advance for your support.

Have never worked with NMEA before but looks straight forward except that I dindt understood how to decode the timestamp, however…

If I understood correctly you are recieving the data using python, then you need to sent the data from python to InfluxDB.
there are tutorials on how to do that: Getting Started with Python and InfluxDB | InfluxData
and also in your influxdb there is a guide:

If that is not the case, you can always use telegraph to connect directly to your GPSusing the socket plugin, but you still need to figure out how to parse the timestamp using telegraph plugins and that may not be as user friendly:

telegraf/README.md at release-1.26 · influxdata/telegraf · GitHub

Hi Fercasjr,

first of all, thanks for your reply; correct, with python I receive data via UDP, process it and at this point I would like to put it into influxdb.
I had already seen the tutorials you linked and also others, but it is not clear to me how to do it practically …

Best.

Is there no one who can help me out ? …
… A code example to be able to import my data into ifuxdb.

Thanks to all.

literaly this is a step-by-step guide with code snippeds, where did you got stuck?:

btw never used python so probably I can’t give you more help. but it can’t be that hard, there’s nothing I haven’t been able to do reading the documentation (yet).