Added fence drive mode to main program