Page 38 - Designing Autonomous Mobile Robots : Inside the Mindo f an Intellegent Machine
P. 38

A Brief History of Software Concepts

               allow you to integrate these systems very quickly, but if the object is poorly written
               there is nothing you can do to correct the problem.
               Figure 2.3 is a list of a very few of the properties of an actual robot object as repre-
               sented in its base-station control program. An array of these objects can be instanced
               when the program is installed (or upgraded), to support any number of robots. In
               this example, these properties are public to the other elements of the control pro-
               gram, but are not exposed to the outside.

               If you haven’t programmed in an object-oriented language before, it will take some
               time to begin to feel comfortable with how best to apply the concept. In Visual
               Basic, the programmer is given a great deal of latitude in the use of objects, and can
               make use of global variables to simplify communications with objects.

                      ‘Robot System Defined Properties:
                      Public Referenced As Boolean
                      Public Patrolling As Integer        ‘Off, Random, Sequential

                      Public PatrolMode As Integer
                      Public Recall As Boolean
                      Public CurrentJob As String
                      Public DestinationNode As String    ‘Destination of current job.
                      Public OriginNode As String         ‘Original starting node
                      Public CurrentNode As String        ‘Last destination node past
                      Public LastInsSent As Integer       ‘Last instruction in current job.
                      Public Comm As String
                      Public FilePath As String           ‘Dispatching Filepath
                      Public EventPath As String          ‘Event Logging File Path
                      Public SensorPath As String         ‘Sensor Logging File Path
                      Public TagPath As String            ‘Tag/Inventory File Path
                      Public RecordPath As String         ‘Recording file path
                             Figure 2.3. Some of the properties of a security robot
                                           (Courtesy of Cybermotion, Inc.)
               Network languages

               Microsoft’s most recent programming environments, VB Net and C’ are intended to
               enhance object-oriented programming for networked applications. Under this re-
               gime, programs (or pieces of them) no longer necessarily execute in the computer in
               which they are installed, but rather programs may send objects to clients or other
               servers where they can be executed more efficiently.
               Since the program may no longer all run in a single place, the convenience (and
               risk) of global variables no longer exists. There is likely a place for this concept in
               robot monitoring and control programs that link to networks, but its discussion is
               beyond the scope of this book.



                                                        21
   33   34   35   36   37   38   39   40   41   42   43