Exemplo n.º 1
0
# Begin modules
import sys

import numpy as np
from scipy import interpolate
import matplotlib.pyplot as plt

sys.path.append("../CycloneHost")
import CycloneHost as cy
# End modules

cy.connect(BAUDRATE, DEVICE, Emulate)

cy.sendCommand("G90\n") # Set absolute positioning

cy.homeZXY() # Home all the axis

# (x,y)
#grid_origin = (0,0)	# Initial point of the grid [mm]
#grid_len = (135,84)	# Distance to probe [mm]
#grid_N = (12,6)	# Number of points
grid_origin = (0,0)	# Initial point of the grid [mm]
grid_len = (80,60)	# Distance to probe [mm]
grid_N = (5,5)	# Number of points (AT LEAST 4 IN EACH DIRECTION, OTHERWISE INTERPOLATION WILL FAIL)

Zlift = 0.5 # mm

F_slowMove = 100

# Warning: Do not lower too much or you will potentially cause damage!
initial_Z_lowering_distance = -10