ASAP Nottingham Team Description

5 downloads 74293 Views 97KB Size Report
Robotic competitions are one of the best ways to ... The system computers are DELL Notebooks, with ... either a blue or a yellow colour on a cap on the top of.
ASAP Nottingham Team Description 1

P.A.S. Birkin1 and J.M. Garibaldi1 Automated Scheduling, Optimisation and Planning (ASAP) Research Group, School of Computer Science and Information Technology, University of Nottingham, Jubilee Campus, Wollaton Road, Nottingham, NG8 1BB. United Kingdom. {pab, jmg}@cs.nott.ac.uk Abstract

This paper describes the system architecture and approach for the FIRA Mirosot Middle League competition. We give experiences and problems encountered in setting up a robot laboratory.

1

Introduction

Robotic competitions are one of the best ways to publicise the cause of robot research and development. The FIRA World Cup 2005 provides a platform on which researches can demonstrate ideas, techniques and achievements. It also allows the participants to meet each other and exchange ideas, problems and solutions. Finally it adds that vital ingredient, competition, the results of which provide a measure of progress. This paper describes the system architecture and approach for the FIRA MiroSot Middle League competition. The rules for MiroSot can be found at http://www.fira.net.

1.1

Background

One of the research areas of the Automated Scheduling, Optimisation & Planning Group (ASAP) is collaboration and cooperation between active agents. Robot soccer is an ideal environment in which to explore many of the issues raised. The laboratory has been set up using a commercial package supplied by Merlin Systems Corp. Ltd. (http://www.merlinsystemscorp.com).

2

System Overview

2.1

Laboratory Setup

The standard 5-a-side playing area of 2.2m by 1.8m is used. It is lit by seven strip lights suspended 2.4m above the pitch which provide an approximately even 750 LUX at the surface. The laboratory has recently been equipped with blackout curtains so that there is no variability due to external light. Two cameras are attached to the lighting rig and positioned approximately centrally over the pitch.

2.2

Laboratory Apparatus

The apparatus used in the laboratory is as follows:• 12 Miabot robots • 2 Laptop Computers • 1 Camera MicroPix Firewire C640 low resolution, 30 frames per sec • 1 Camera MicroPix Firewire C1024 high resolution, 15 frames per second • 2 Bluetooth Communications Modules

2.3

Robots

The ASAP Nottingham Team comprises of Merlin Systems Corp. Ltd. ‘Maibot Pro BT’ robots as shown in Figure 1. The detailed specification describing the features of the robots is given in Table 1.

2.4

Cameras

Two different cameras are used in the laboratory. The first is a low resolution MicroPix Firewire C640 colour camera operating at 30 fps. The second is a

Figure 1: ASAP Nottingham Team Robot Table 1: Robot Specification Processors Main Atmel ATMega64 Slave Atmel ATMega8 Flash Memory 64K E2ROM 2k Bytes SRAM 4K Speed Up to 16 MIPS HBbridge 2 x 5A MOSFET H-Bridge Drive Train Dual DC Motors 6v Encoders 0.04mm Resolution Wheel Diameter 52mm Gearbox Ratio 8:1 Stall Torque 175 g/cm @2.85A Speed 3.5 m/s Batteries NIMH 6 x 1.2v AA NIMH Cells Operation Approx. 2Hr Development Simulator FIRA 3D ’C’ Compiler GCC with development kit Firmware Download PonyProg Expansion I/O Port 1 8 x 8 A/D inputs 10 bit or 8 Digital I/O I/O Port 2 In System Programming Socket Serial Hardlink Comms Multiplexed Functions I2C,SPI,5 x PWM, 6 x Interrupt Capable I/O Communications Wireless Bluetooth Range Up to 100m Speed Bidirectional @ 115kb/s Other LEDS 2 DIP Switches 4 Power Switch 1 Firmware Control PID Control system Communications ASCII drive protocol. Extensible Many extendible features Bluetooth firmware Chassis Construction All aluminium Case Dimensions 7.5cm3

high resolution MicroPix Firewire C1024 colour cameras operating at 15fps. The C640 camera delivers a 640 x 480 pixel image with a pixel covering an area of approximately 12.89mm2 at the pitch surface. The C1024 has a 1024 x 768 pixel image giving a pixel coverage of approximately 5.03mm2 . Both cameras provide a 24 bit RGB colour data output. The cameras are controlled through a Unibrain Fire-i API to the IEEE-1394 digital camera standard.

2.5

PC’s

The system computers are DELL Notebooks, with a Pentium4 processor running at 2.80GHz and 512Mb RAM. The Operating System is Windows 2002 XP Service Pack 2.

3

Robot Soccer Engine Setup

The Robot Soccer Engine (RSE) is supplied by Merlin Systems Corp. Ltd. and provides all the interfaces necessary to set up the robots prior to starting a game. These include player identification, pitch mapping and allocation of COM ports for the Bluetooth Comms package. The RSE starts and stops the game and displays the image received from the attached camera whilst the game is played.

3.1

Process Overview

The RSE receives frame pictures from the camera via the Fire-i API. Each frame is processed by the ProcessImage routine, and current robot and ball positions are calculated. The ProcessImage routine passes RobotPositions to the User Defined Strategy routine. The User Defined Strategy is where MoveTo commands are calculated for each of the robots, according to the strategy loaded at the start

Table 2: Player Identification and Role

Figure 2: Robot Soccer Engine Overview

Player P1 P2 P3 P4 P5

Computer Camera FireWire

User

Process

Image Pixels Image

Robot Position

Defined Strategy

Robot MoveTo Command

Dispatcher

Large Green Cyan Magenta Magenta Cyan

Small Green Cyan Magenta Cyan Magenta

Role Goalkeeper Defender Left Right Attacker

Robots

Table 3: Colour Definition at Intensity of 120 Bluetooth

of the game. When completed, the User Defined Strategy calls the Dispatcher routine. The Dispatcher routine packages the commands into messages for each robot. The messages are then sent via the Bluetooth Comms package to the corresponding robots. The MoveTo messages are processed and actioned on the robots, so that the time spent in RSE processing is a minimum. This is shown in Figure 2.

3.2

Player Identification

In MiroSot matches the two teams are identified by either a blue or a yellow colour on a cap on the top of the robot. The ball is a golf ball coloured orange. An individual player is not required to be identified. If the players are identified, the identifying colour must not be blue, yellow or orange. The RSE uses a set of caps which are labelled P1 - P5. These are colour coded so that the RSE can identify each robot. A three colour Hue Saturation Intensity (HSI) system is used with two different sized patch squares for each player. The large patch is 33mm2 and the small patch 23mm2 . The team patch is the same size as the large patch. The RSE requires the team colours blue and yellow; and the player colours magenta, green and cyan, and the ball orange to be defined before the game starts. The actual hues are entered as ranges against the required colours. To complete the identification the minimum and maximum blob size in screen pixels for each patch must be entered into the RSE. This is used to ensure that a colour patch has been correctly identified. However the greater the range in the blob size, the slower the identification process. The reason for having a three patch identification system over a two patch system is that when the robots get close or collide they are still identifiable. In our experiments the loss or

Colour Blue Yellow Magenta Green Cyan

Hue 144 40 200 96 120

Sat 120 240 240 120 120

swapping of identity rarely occurred and was quickly corrected if it did. During a game the RSE provides information about each player on the camera image screen. This is a confidence measure of the identity of a player. The range is 0-99 where 99 is the most confident prediction of identity. Whilst a game is being played the values reported are about 80. The Player Identification is given in Table 2.

3.3

Colour Definition

A series of experiments was carried out to determine the optimum colours for the RSE to operate with. A set of colour charts of small patch (23mm x 23mm) squares was produced. The colours were generated for Hue within Saturation within Intensity. Only two intensity values of 120 and 136 where used. The Saturations used were 60 - 360 in steps of 60. The Hues were 8 - 360 in steps of 8. The colour charts were then put under the cameras and the Hue values read off using the camera image screen. Various camera aperture settings were tested, and the most robust result is given in Table 3.

3.4

Pitch Mapping

The RSE requires the pitch to be defined on the camera image screen. The user clicks on the corners of the pitch image from which the corner pixel values are obtained. This frames the pitch in terms of the camera image. The position of the robots within the pitch

can then be calculated by the RSE. Within the User Defined Strategy, the pitch is held in a pitch array of dimension 80 x 100, giving a coverage of 22.5mm x 22mm per pitch element.

4

The Strategies

Various strategies have been investigated and developed. They are written in C++ and were tested on the FIRA simulator to eliminate errors such as direction of play. The results of trials have been analysed and are reported in [1].

4.1

Case Based Strategy

The case based strategy uses the position of the ball, the position of the robots and the position of a target to generate a set of vectors. The vectors will be used to direct the robot through the ball towards the target. This is repeated on a frame by frame basis. The robots are arranged in a 1-2-1 formation with one Defender, two midfielders (Left and Right), and one Attacker. The Defender always plays in his own half of the pitch, and the Attacker only plays in the oppositions half of the pitch. Left plays on the left side of the pitch, and Right on the right side. Both these players can play in either half. Attacking is considered to be chasing the ball towards the opponents goal, and defending is when chasing the ball the other way. If the players are moving towards their own goal, they try to run round the ball, so as to get between the ball and the goal, without hitting the ball towards their own goal. If that is not possible, then the players attempt to drive the ball into the corners, and then start attacking. Tackling is a behaviour whereby a player moves towards the ball which is effectively controlled by an opponent, attempts to intercept the ball and start attacking. Players shoot when they are inside the opponents penalty area and within one ball diameter of the ball. The player spins to effect the shot. Free kicks and penalties use a move to the ball and a spin to hit it. The Goalkeeper attempts to move and stay in line with the ball and hit it away from the goal when ever possible. The Goalkeeper stays within the penalty area. 4.1.1

Potential Field Attraction and Repulsion Strategy

The potential field strategy is based on ideas by [2] and [3]. The strategy is based on Coulomb’s law of

electrical potential F =

Q1 .Q2 d2

where Q1 is the signed charge on the first object where Q2 is the signed charge on the second object, and where d is the distance between them The pitch is divided into three areas, attack, defend and goal. The ball is given a high positive charge and the players a negative charge. By this mechanism there is a force of attraction between robots and the ball, and a repulsion between robots. The repulsive force provides for an avoidance strategy between robots. The pitch can be initially charged to provide a positive gradient to encourage attacking, and can be altered throughout the game according to ball position and other factors. A full potential field for all players is not calculated due to the high overhead in terms of computer cycle time. Instead the field around each individual robot and the ball are calculated to a local extent, using a parameter defined distance. To keep the calculations simple, the potential of the robot for whom the field is being calculated is ignored. The robots move according to the sum of potential fields surrounding them, and so follow the line of least resistance. When defending, the players can run round the ball to get between the ball and the goal. This is achieved by having a negative field between the defender and the ball. There is no restriction on the Defender being able to move into the opponents half, as is the case in the Ball Chasing Strategy. The only specialised player is the Goalkeeper, who is contained by a fixed negative boundary within the penalty area. The Goalkeeper always attempts to hit the ball to the edges of the pitch. Spin shooting, goal, penalty and free kicks are all implemented. A detailed presentation on potential fields methods is given in [2].

5 5.1

Problems Discovered During Experimentation Lighting

Initially the laboratory was equipped with venetian blinds. We found that the RSE could not locate the robots and they went out of control, characterised by a high-speed spin. After installing strip lighting and blackout curtains the problem has not re-occurred.

5.2

Camera Frame Speeds

After setting up the cameras for focus and aperture in the RSE, a series of games were played. Analysing the results showed that there was a problem with the high resolution camera running at 15 fps. The team it was controlling was not responding quickly enough and was unable to win any games. This requires further investigation to determine the cause.

5.3

Physical Damage

Over the series of games the robots sustained a high level of damage due to collisions. Tyres were thrown off or got jammed between the wheel and the chassis. The main axles became loose and wheels fell off. This lead to improvements being made in the design and manufacture process, such as stub axles being introduced. There was no damage sustained by the robot electronics.

5.4

Robot Control Parameters

Each robot has a basic Proportional Integral Differential (PID) control algorithm. The PID is given the distance between the robot and the ball as an error value, and moves the robot to reduce the distance to zero by altering how the motors are driven. The RSE only provides one set of PID parameters for all the robots. However we require the Goalkeeper to have a very fast response time when under attack, due to the small distances between it and the ball. This is usually achieved by having a very high Integral action parameter and a different Proportion value. Consequently the Goalkeeper robot has to have these values loaded separately.

6 6.1

Future Developments Physical Performance

Further experiments on deviation from a straight line, acceleration characteristics, balancing effects, centre of gravity alteration and the PID parameters, motor characteristics and performance matching will be carried out. These experiments are intended to provide data should we decide to implement any pathfollowing algorithms. Also identification and reduction of systematic errors within each robot should be possible.

6.2

Control Improvements

To further understand the robots and the RSE a series of projects are to be set up to investigate the following: • Determine the amount of computer cycle time spent within each module of the RSE and look for ways to improve performance. • Implement a traction control on the robots to prevent wheel spin from occurring. • Establish if a planner and opponent avoidance are necessary. • Develop and integrate a self tuning PID algorithm for the robots. • Evolve different controllers using for example, Genetic Algorithm and Fuzzy Logic techniques

References [1] J.L. Baxter, J.M. Garibaldi, E.K. Burke and M. Norman, Statistical Analysis in MiroSot, to appear in Proceedings of 2005 FIRA World Congress, Singapore, 2005 [2] J-C. Latombe, Robot Motion Planning, Kluwer Academic Publishers, 1991. [3] Y. Koren and J. Borenstein, Potential Field Methods and their Inherent Limitations for Mobile Robot Navigation, Proc. IEEE conf. Robotics and Automation, April 1991,pp1398-1404.