from config import base from config import motion # initialize the RTAPI command client rt.init_RTAPI() # loads the ini file passed by linuxcnc c.load_ini(os.environ['INI_FILE_NAME']) motion.setup_motion(kinematics=c.find('KINS', 'KINEMATICS')) # reading functions hal.addf('motion-command-handler', 'servo-thread') # define gantry joints base.init_gantry(axisIndex=1, joints=2, latching=True) # Axis-of-motion Specific Configs (not the GUI) # X [J0] Axis base.setup_stepper(section='AXIS_0', axisIndex=0, stepgenIndex=0, stepgenType='sim') # Y [J1] Axis base.setup_stepper(section='AXIS_1', axisIndex=1, stepgenIndex=1, gantry=True, gantryJoint=0, stepgenType='sim') # YY[J2] Axis
from config import base from config import storage from config import motion import cramps as hardware # initialize the RTAPI command client rt.init_RTAPI() # loads the ini file passed by linuxcnc c.load_ini(os.environ['INI_FILE_NAME']) motion.setup_motion() hardware.init_hardware() storage.init_storage('storage.ini') # Gantry component for Z Axis base.init_gantry(axisIndex=2) # reading functions hardware.hardware_read() base.gantry_read(gantryAxis=2, thread='servo-thread') hal.addf('motion-command-handler', 'servo-thread') numFans = c.find('FDM', 'NUM_FANS') numExtruders = c.find('FDM', 'NUM_EXTRUDERS') numLights = c.find('FDM', 'NUM_LIGHTS') # Axis-of-motion Specific Configs (not the GUI) ve.velocity_extrusion(extruders=numExtruders, thread='servo-thread') # X [0] Axis base.setup_stepper(section='AXIS_0', axisIndex=0, stepgenIndex=0) # Y [1] Axis
from config import base from config import motion # initialize the RTAPI command client rt.init_RTAPI() # loads the ini file passed by linuxcnc c.load_ini(os.environ["INI_FILE_NAME"]) motion.setup_motion(kinematics=c.find("KINS", "KINEMATICS")) # reading functions hal.addf("motion-command-handler", "servo-thread") # define gantry joints base.init_gantry(axisIndex=1, joints=2, latching=True) # Axis-of-motion Specific Configs (not the GUI) # X [J0] Axis base.setup_stepper(section="AXIS_0", axisIndex=0, stepgenIndex=0, stepgenType="sim") # Y [J1] Axis base.setup_stepper(section="AXIS_1", axisIndex=1, stepgenIndex=1, gantry=True, gantryJoint=0, stepgenType="sim") # YY[J2] Axis base.setup_stepper(section="AXIS_1", axisIndex=1, stepgenIndex=2, gantry=True, gantryJoint=1, stepgenType="sim") # Z [J3] Axis base.setup_stepper(section="AXIS_2", axisIndex=2, stepgenIndex=3, stepgenType="sim") # A [J4] Axis base.setup_stepper(section="AXIS_3", axisIndex=3, stepgenIndex=4, stepgenType="sim") # B [J5] Axis base.setup_stepper(section="AXIS_4", axisIndex=4, stepgenIndex=5, stepgenType="sim")