skeinforge_tools.speed ($Date: 2008/21/04 $)
index
/home/enrique/Desktop/backup/babbleold/script/reprap/pyRepRap/skeinforge_tools/speed.py

Speed is a script to set the feedrate, and flowrate.
 
The default 'Activate Speed' checkbox is on.  When it is on, the functions described below will work, when it is off, the
functions will not be called.  The speed script sets the feedrate, and flowrate.  To run speed, in a shell type:
> python speed.py
 
The feedrate for the shape will be set to the 'Feedrate" preference.  The speed of the orbit compared to the operating extruder
speed will be set to the "Orbital Feedrate over Operating Feedrate" preference.  If you want the orbit to be very short, set the
"Orbital Feedrate over Operating Feedrate" preference to a low value like 0.1.
 
In the "Flowrate Choice" radio button group, if "Do Not Add Flowrate" is selected then speed will not add a flowrate to the gcode
output.  If "Metric" is selected, the flowrate in cubic millimeters per second will be added to the output.  If "PWM Setting" is
selected, the value in the "Flowrate PWM Setting" field will be added to the output.
 
The following examples speed the files Hollow Square.gcode & Hollow Square.gts.  The examples are run in a terminal in the
folder which contains Hollow Square.gcode, Hollow Square.gts and speed.py.  The speed function will speed if "Activate
Speed" is true, which can be set in the dialog or by changing the preferences file 'speed.csv' with a text editor or a spreadsheet
program set to separate tabs.  The functions writeOutput and getSpeedChainGcode check to see if the text has been speeded,
if not they call getMultiplyChainGcode in multiply.py to get multiplied gcode; once they have the multiplied text, then they
speed.
 
 
> python speed.py
This brings up the dialog, after clicking 'Speed', the following is printed:
File Hollow Square.gts is being chain speeded.
The speeded file is saved as Hollow Square_speed.gcode
 
 
>python
Python 2.5.1 (r251:54863, Sep 22 2007, 01:43:31)
[GCC 4.2.1 (SUSE Linux)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import speed
>>> speed.main()
This brings up the speed dialog.
 
 
>>> speed.writeOutput()
Hollow Square.gts
File Hollow Square.gts is being chain speeded.
The speeded file is saved as Hollow Square_speed.gcode
 
 
>>> speed.getSpeedGcode("
( GCode generated by May 8, 2008 slice.py )
( Extruder Initialization )
..
many lines of gcode
..
")
 
 
>>> speed.getSpeedChainGcode("
( GCode generated by May 8, 2008 slice.py )
( Extruder Initialization )
..
many lines of gcode
..
")

 
Modules
       
__init__
skeinforge_tools.analyze
cStringIO
skeinforge_tools.skeinforge_utilities.euclidean
skeinforge_tools.skeinforge_utilities.gcodec
skeinforge_tools.import_translator
skeinforge_tools.skeinforge_utilities.intercircle
skeinforge_tools.material
math
skeinforge_tools.multiply
skeinforge_tools.polyfile
skeinforge_tools.skeinforge_utilities.preferences
sys
time

 
Classes
       
SpeedPreferences
SpeedSkein

 
class SpeedPreferences
    A class to handle the speed preferences.
 
  Methods defined here:
__init__(self)
Set the default preferences, execute title & preferences filename.
execute(self)
Speed button has been clicked.

 
class SpeedSkein
    A class to speed a skein of extrusions.
 
  Methods defined here:
__init__(self)
addFlowrate(self)
Add flowrate line.
addLine(self, line)
Add a line of text and a newline to the output.
getGcodeFromFeedrateMovement(self, feedrateMinute, point)
Get a gcode movement.
getRounded(self, number)
Get number rounded to the number of carried decimal places as a string.
getSpeededLine(self, splitLine)
Get elevated gcode line with operating feedrate.
parseGcode(self, gcodeText, speedPreferences)
Parse gcode text and store the speed gcode.
parseInitialization(self)
Parse gcode initialization and store the parameters.
parseLine(self, line)
Parse a gcode line and add it to the speed skein.

 
Functions
       
getSpeedChainGcode(filename, gcodeText, speedPreferences=None)
Speed a gcode linear move text.  Chain speed the gcode if it is not already speeded.
getSpeedGcode(gcodeText, speedPreferences=None)
Speed a gcode linear move text.
main()
Display the speed dialog.
writeOutput(filename='')
Speed a gcode linear move file.  Chain speed the gcode if it is not already speeded.
If no filename is specified, speed the first unmodified gcode file in this folder.

 
Data
        __author__ = 'Enrique Perez (perez_enrique@yahoo.com)'
__date__ = '$Date: 2008/21/04 $'
__license__ = 'GPL 3.0'
absolute_import = _Feature((2, 5, 0, 'alpha', 1), (2, 7, 0, 'alpha', 0), 16384)

 
Author
        Enrique Perez (perez_enrique@yahoo.com)