def main(): log = LogData(logging.INFO) rr = RepRap() rr.connect(port="/dev/ttyACM0", baudrate=115200) scan = Scanner(log, rr, "em3d.out", (13, 10, 5), (0.5, 0.1)) scan.getCoordTuple() #x = scan.createStepPointsX() #y = scan.createStepPointsY() #z = scan.createStepPointsZ() #print x #print y #print z #scan.oneRow() #scan.moveOneStepXforward("1.5", '-') list = [0.0, 1.0, 2.0, 30.0, 4.0, 5.0, 100.0, 7.0, 8.0, 9.0, 10.0, 16.0] scan.mX(list, "na", "of") rr.disconnect() pass
def ShowAndRender(self): """ Calls Show() and Render() methods in ParaView """ Show() Render() dim = GetDimensionsList() wave1 = MyWavelet(dim.GetDimensions()) wave1.SetPointDataToCellData("Amplitude") #wave2 = MyWavelet(dim.GetDimensions()) #wave2.SetPointDataToCellData("Phase") pna = NetworkAnalyzer() rf = RfAtmega128() transmistter = RfAtmega128() reprap = RepRap() # check if RepRap printer exists if reprap.connect("/dev/ttyACM0", 115200) is True: print "Wavelet dimensions: ", dim.GetDimensions() reprap.setMeasureDimensions(dim.GetDimensions()) print "Number of points to measure: ", reprap.getNumberOfMeasurePoints() else: print "No RepRap printer found." # select measure device # 1 = PNA Agilent N5230C # 2 = rfAtmega128 board (Arduino with Zigbee) # programmed as Spectrum Analyzer measurementDevice = "2"