public void Can_Turn_Roomba() { int turnTime = 5000; using (var roomba = new RoombaCreate(BT_NAME, CommunicationMethod.Bluetooth)) { roomba.Start(); roomba.Control(); roomba.TurnRight(); System.Threading.Thread.Sleep(turnTime); roomba.Stop(); roomba.TurnLeft(); System.Threading.Thread.Sleep(turnTime); roomba.Stop(); roomba.PowerDown(); } }
public void Can_Move_Roomba_BlueTooth() { int forwardTime = 1500; int reverseTime = 2000; int stopTime = 5000; using (var roomba = new RoombaCreate(BT_NAME, CommunicationMethod.Bluetooth)) { roomba.Start(); roomba.Control(); roomba.Forward(); System.Threading.Thread.Sleep(forwardTime); roomba.Stop(); System.Threading.Thread.Sleep(stopTime); roomba.Reverse(); System.Threading.Thread.Sleep(reverseTime); roomba.Stop(); roomba.PowerDown(); } }
public void Can_Move_Roomba_Serial() { int forwardTime = 1500; int reverseTime = 2000; int stopTime = 5000; using (var roomba = new RoombaCreate("COM3")) { roomba.Start(); roomba.Control(); roomba.Forward(); System.Threading.Thread.Sleep(forwardTime); roomba.Stop(); System.Threading.Thread.Sleep(stopTime); roomba.Reverse(); System.Threading.Thread.Sleep(reverseTime); roomba.Stop(); roomba.PowerDown(); } }
public void Can_UnDock_Roomba() { int reverseTime = 5000; using (var roomba = new RoombaCreate(BT_NAME, CommunicationMethod.Bluetooth)) { roomba.Start(); roomba.Control(); roomba.Reverse(); System.Threading.Thread.Sleep(reverseTime); roomba.Stop(); roomba.PowerDown(); } }