Exemple #1
0
from machinekit import rtapi as rt
from machinekit import hal
from machinekit import config as c

from config import velocity_extrusion as ve
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')
Exemple #2
0
# HAL file for BeagleBone + TCT paralell port cape with 5 steppers and 3D printer board
import os

from machinekit import rtapi as rt
from machinekit import hal
from machinekit import config as c

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
Exemple #3
0
# HAL file for BeagleBone + TCT paralell port cape with 5 steppers and 3D printer board
import os

from machinekit import rtapi as rt
from machinekit import hal
from machinekit import config as c

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',
# HAL file for BeagleBone + TCT paralell port cape with 5 steppers and 3D printer board
import os

from machinekit import rtapi as rt
from machinekit import hal
from machinekit import config as c

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')

# Axis-of-motion Specific Configs (not the GUI)
# X [0] Axis
base.setup_stepper(section='AXIS_0', axisIndex=0, stepgenIndex=0, stepgenType='sim')
# Y [1] Axis
base.setup_stepper(section='AXIS_1', axisIndex=1, stepgenIndex=1, stepgenType='sim')
# Z [2] Axis
base.setup_stepper(section='AXIS_2', axisIndex=2, stepgenIndex=2, stepgenType='sim')
# Z [2] Axis
base.setup_stepper(section='AXIS_3', axisIndex=3, stepgenIndex=3, stepgenType='sim')
# Z [2] Axis
base.setup_stepper(section='AXIS_4', axisIndex=4, stepgenIndex=4, stepgenType='sim')