Commit 5897fbc6 authored by kliment's avatar kliment

Merge pull request #316 from hroncok/master

gcoder.py reads the file content instead of the file name when testing
parents 094dffa5 629a53ac
...@@ -210,7 +210,7 @@ def main(): ...@@ -210,7 +210,7 @@ def main():
print "usage: %s filename.gcode" % sys.argv[0] print "usage: %s filename.gcode" % sys.argv[0]
return return
gcode = GCode(sys.argv[1]) gcode = GCode(list(open(sys.argv[1])))
gcode.measure() gcode.measure()
...@@ -221,4 +221,4 @@ def main(): ...@@ -221,4 +221,4 @@ def main():
print "Filament used: %0.02fmm" % gcode.filament_length() print "Filament used: %0.02fmm" % gcode.filament_length()
if __name__ == '__main__': if __name__ == '__main__':
main() main()
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment