Changeset 1ba85cf for src/python/bin
- Timestamp:
- Aug 10, 2017, 8:21:46 PM (9 years ago)
- Branches:
- 0.5, app-cordova, debian/bullseye, debian/jessie, master
- Children:
- 85f32d8
- Parents:
- 6fec060
- git-author:
- Joachim Langenbach <joachim.langenbach@…> (08/10/17 19:37:40)
- git-committer:
- Joachim Langenbach <joachim.langenbach@…> (08/10/17 20:21:46)
- File:
-
- 1 edited
-
src/python/bin/gnuboat (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/python/bin/gnuboat
r6fec060 r1ba85cf 39 39 40 40 # default values for command line arguments 41 rrdfile = "/var/lib/gnuboat/ log-webservice.rrd"41 rrdfile = "/var/lib/gnuboat/gnuboat.rrd" 42 42 shutdownfile = "/var/spool/gnuboat/shutdown.request" 43 43 logdir = "/var/log/gnuboat" … … 118 118 def log(gpsFix, gpsTime, gpsStatus, latitude, latitudeDirection, longitude, 119 119 longitudeDirection, courseOverGround, speedOverGround, waterDepth, waterDepthValid): 120 global logdir 120 121 global nmeafile 122 global nmeaFileDate 121 123 122 124 # Only log, if we have a gps fix … … 126 128 nmeaFileDateShould = datetime.datetime.utcnow().strftime("%Y-%m-%d") 127 129 mode = 'A' 128 if nmeafile == None or nmeaFileDate != nmeaFileDateShould:129 if nmea File:130 if nmeafile == None or nmeaFileDate is None or nmeaFileDate != nmeaFileDateShould: 131 if nmeafile: 130 132 nmeafile.close() 131 133 try: … … 151 153 global displayperiod 152 154 global logdir 153 global nmea LogFile155 global nmeafile 154 156 155 157 try:
Note:
See TracChangeset
for help on using the changeset viewer.
