PSEUDO CODE FOR ROBOT SOFTWARE ============================== General Operating Logic for Sumo Behavior Processor RESET declare variables declare constants declare and load Get_Behavior data array MAIN: Initialize variables Make sure motors are stopped Set up I/O ports for use Initialize IR range sensor Set operating mode Read mode switches Read line sensors Run IR Sensor test program if so selected Scan all sensors Get range reading from IR Send data to I/O Port Light LED if target detected Wait 5 seconds before moving Blink activity LED Scan area for opponent if found go towards him otherwise just start moving DO: Scan sensors Decide on behavior Send selected variable out Port C Execute behavior sequence based on mode if new sensor inputs then abandon current sequence Blink activity indicator LOOP Assorted Subroutines END