Changeset 219
- Timestamp:
- 09/30/08 20:58:06 (3 years ago)
- Location:
- trunk/software
- Files:
-
- 4 modified
-
rb/gui/__init__.py (modified) (1 diff)
-
rb/motor/command.py (modified) (2 diffs)
-
rb/motor/motor_controller.py (modified) (2 diffs)
-
rbconfig.py (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/software/rb/gui/__init__.py
r218 r219 40 40 ''' 41 41 42 require('rb.motor.motor_controller.serial_motor_controller' , '/dev/ttyS0')42 require('rb.motor.motor_controller.serial_motor_controller') 43 43 require('rb.motor.command.motor_command_relay') 44 44 -
trunk/software/rb/motor/command.py
r200 r219 75 75 while flag.running: 76 76 try: 77 # Check for a new target speed. Don't block because we 78 # still need to update the motor speed. 77 79 event = queue.get(block=False) 78 80 except Empty: … … 80 82 if not sp and brake: 81 83 log_debug("motor_command_relay: activating the brake for %s" % addr) 82 dispatch("motor:motor_control", (addr, MC_BRAKE ))84 dispatch("motor:motor_control", (addr, MC_BRAKE, 0)) 83 85 brake = False 84 86 elif trans: -
trunk/software/rb/motor/motor_controller.py
r200 r219 38 38 39 39 MC_FORWARD = 0 40 MC_ REVERSE= 141 MC_ BRAKE= 240 MC_BRAKE = 1 41 MC_REVERSE = 2 42 42 43 43 … … 96 96 log_debug("Serial MC: Wrote " + ''.join(' %02x' % ord(c) for c in data)) 97 97 retval = port.read(size=1) 98 if not retval or retval != '0':98 if not retval or ord(retval): 99 99 log_error("Serial MC: Error writing to motor controller. " 100 100 "Response was %r%s" % ( -
trunk/software/rbconfig.py
r201 r219 45 45 46 46 # Serial port for the motor controller 47 motor_controller_port = '/dev/tty S0'47 motor_controller_port = '/dev/ttyUSB0' 48 48 49 49 # Minimum speed, aside from 0, that the motor controller can be

