test_io.py
Go to the documentation of this file.
00001 #!/usr/bin/env python
00002 import time
00003 from ur_driver.io_interface import *
00004 
00005 if __name__ == "__main__":
00006     print "testing io-interface"
00007     get_states()
00008     print "listener has been activated"
00009     set_states()
00010     print "service-server has been started"
00011     while(True):
00012         set_tool_voltage(12)
00013         set_digital_out(0, True)
00014         set_analog_out(0, 0.75)
00015         #print "Flags are currently not supported"
00016         ##set_flag(0, True)
00017         ##print(Flag_States[0])
00018         print(Analog_Out_States[0])
00019         print(Digital_Out_States[0])
00020         time.sleep(1)
00021         set_tool_voltage(24)
00022         set_digital_out(0, False)
00023         set_analog_out(0, 0.25)
00024         #print "Flags are currently not supported"
00025         ##set_flag(0, False)
00026         ##print(Flag_States[0])
00027         print(Analog_Out_States[0])
00028         print(Digital_Out_States[0])
00029         time.sleep(1)
00030 
00031 


ur_driver
Author(s): Stuart Glaser, Shaun Edwards , Felix Messmer
autogenerated on Fri Aug 28 2015 13:31:30