#!/usr/bin/env python2.1 import os import string import cPickle pickle = cPickle import select import time gps = open('gps_data', 'r') log = open('/home/kyler/projects/triplogger/trip.log', 'w') logp = pickle.Pickler(log) while (1): line = gps.readline() if not line: break if line[0] != '$': continue components = string.split(line[:-1], ',') logp.dump(components) # print 'GPS' #: %s' % (components)