예제 #1
0
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
예제 #2
0
        transmistter.connect("/dev/ttyUSB1", 9600)
        transmistter.cwTransmissionInit()
    except:
        print "Error running the transmitter."
    reprap.moveOneCube(wave1, rf)
    try:
        transmistter.cwTransmissionStop()
    except:
        print "Error transmitter not connected."
    print "Connected to rfAtmega128."

else:
    print "something is wrong."

if pna.disconnect() is True:
    print("Disconnecting from PNA.")
    reprap.disconnect()

elif rf.disconnect() is True:
    print("Disconnecting from rfAtmega128 board.")
    rf.disconnect()
else:
    print("Can't disconnect from rfAtmega128 board.")

# wave1.ShowAndRender()
# print wave1.dimensions
# wave1.WriteToPVDFile(0, "testPVD/myFirstPVD")
# data = GroupDatasets(Inputs=[Amplitude, Phase])
Show()
Render()