// // Connect a small DC motor to pins P1.0 and P1.1 // Every second, this program will reverse the motor direction. // void setup( void ) { P1DIR = 0b11; P1OUT = 1; // P1.0 is at +3.3 volts, P1.1 is at 0 volts } void loop( void ) { P1OUT ^= 0b11; // Switch the state of the two lowest pins delay( 1000 ); }