#!/usr/bin/python

import os, sys, regex
from time import time 
from string import *

# serial input device

TTY = "/dev/ttyS0"
input = open( TTY, "rb" )

########################################
# form a timestamp

prev_tv = (0,0,0,0)

def ts():
	ta = localtime()
	next_tv = ( t[0], t[1], t[2], t[8])
	if prev_tv != next_tv:
		prev_tv = next_tv
		outs( "#" + asctime( ta ))
		ta = localtime()
	return "%02d:%02d:%02d " % ( t[3], t[4], t[5] )


########################################
# startup initialization

def init():
	pass

########################################
# main loop

def main():

	while 1:
		line = input.readline()
		print ts(), line,

init()
main()


ffb7baa996ae0a6eff3fb44fb4c0f9ae12c504c1
#!/usr/bin/python

import os, sys, regex
from time import time 
from string import *

# serial input device

TTY = "/dev/ttyS0"
input = open( TTY, "rb" )

########################################
# form a timestamp

prev_tv = (0,0,0,0)

def ts():
	ta = localtime()
	next_tv = ( t[0], t[1], t[2], t[8])
	if prev_tv != next_tv:
		prev_tv = next_tv
		outs( "#" + asctime( ta ))
		ta = localtime()
	return "%02d:%02d:%02d " % ( t[3], t[4], t[5] )


########################################
# startup initialization

def init():
	pass

########################################
# main loop

def main():

	while 1:
		line = input.readline()
		print ts(), line,

init()
main()

