After Laying out the circuit diagram and the connections to the various outputs, we needed small sections of programming routine so that when the programmer came to assemble the final developed program, small sections of code could be copied and pasted in.
Firstly, we had to devise a code to check that the motor were wired up correctly and that it would turn backwards and forward.
Main:
low 1 `Drive the motor forward
high 2
pause 5000 `Pause for 5 seconds
high 1 `Drive the motor backwards
low 2
pause 5000 `Pause for 5 seconds
goto main `loop to start
Once this was working, the code was copied and applied to 2 motors to make sure that they both worked;
This routine was called "goforward" (obviously)
`To Drive Motor Forwards
High 5 `Left Motor Fowards
Low 4 `Left Motor Forwards
High 6 `Right Motor Forwards
low 7 `Right Motor Forwards
(Note the change in Pins, as this code was run on the fully assembled buggy, whereas the first code was run during the lab sessions during the first couple of weeks)
Once we had this code and sub-system working, we were able to play around witht the outputs of the chip to create smaller subsections of programming that would enable the buggy to turn left and right. Here are the devised codes;
turnright:
`To Turn Right
High 5 `Left Motor Fowards
Low 4 `Left Motor Forwards
`Code To Turn right Motor Backwards
Low 6
High 7
return
And the code to turn left;
turnleft:
` To Turn Left
High 6 `Right Motor Forwards
low 7 `Right Motor Forwards
`Code to run Left Motor Backwards
Low 5
High 4
These blocks of text where then substituted in to the Alecs program.
Showing posts with label Duncan Scriven. Show all posts
Showing posts with label Duncan Scriven. Show all posts
Friday, 30 April 2010
Some Initial Programming
A quick bit of programming to see if the buggy was working once constructed:
Sensor Input Program:
main:
READADC 0,B0
READADC 1,B1
READADC 2,B2
Debug
If b0>100 then b3=1
GOTO main:
Motor Test Program:
Main:
High 0 `Run Motor 1(?) Forwards(?)
Low 1
Pause 3000 `Pause for 3000
Low 0
High 2 `Run Motor 2(?) Forwards(?)
Low 3
Pause 3000 `Pause for 3000
Low 2
Goto Main:
Initial Buggy Program Idea:
Main:
Read 0,B0 `Left Sensor written to Bo
Read 1,B1 `Sensor 2 Written to B1
Read 2,B2 `Right. Sensor written to b2
Low 5 Low 4 Low 6 Low 7
Debug `To check working correctly
If B0=1 Then high 5 Low 4
Else If B2=1 Then high 6 low 7
Endif
Goto Main
Sensor Input Program:
main:
READADC 0,B0
READADC 1,B1
READADC 2,B2
Debug
If b0>100 then b3=1
GOTO main:
Motor Test Program:
Main:
High 0 `Run Motor 1(?) Forwards(?)
Low 1
Pause 3000 `Pause for 3000
Low 0
High 2 `Run Motor 2(?) Forwards(?)
Low 3
Pause 3000 `Pause for 3000
Low 2
Goto Main:
Initial Buggy Program Idea:
Main:
Read 0,B0 `Left Sensor written to Bo
Read 1,B1 `Sensor 2 Written to B1
Read 2,B2 `Right. Sensor written to b2
Low 5 Low 4 Low 6 Low 7
Debug `To check working correctly
If B0=1 Then high 5 Low 4
Else If B2=1 Then high 6 low 7
Endif
Goto Main
Labels:
Alec Kingsnorth,
Duncan Scriven,
Luke Hildred,
Programming
Testing day
Once all of the programming, building and debugging had been completed it was test day. The first thing on test day was to set the robot to the ambient light conditions experienced in the room which meant changing the program slightly to accommodate for this. Redo any last adjustments and then our line follower was off. Having came to Test day we still realised we needed to have a lot more debugging process ,the motors did not produce enough torque, one of the circuits driving the motor board was not working correctly as one of the motors would not go backwards (not a problem for line follower mode but for symbol mode it was).
Our tests went significantly better then the Marked test from the lecturer , our robot managed to sense the line but it did not have enough torque to turn. And on the symbol mode our robot managed to only recognise the Left and Right turn but the action that they performed was not 90 degrees left and right , instead they just continually span round.
Labels:
Alec Kingsnorth,
Duncan Scriven,
Ian thomas,
Mark Lobato
Tuesday, 27 April 2010
Group feedback and product development.
After the testing of the product resulted in it failing two tests, and only completing the main line following task with a little prod now and again, the group have decided that implementing the following steps would help produce a successful design:
1. Supply a greater voltage to the motors. This could be done by either using the 9V battery, the connection to the motor being controlled by a seperate motor board circuit, or running a further voltage source in parallel with the current supply; maintaining the voltage (4.5V) but increasing the current supply to the motors. This extra step would increase the torque of the motors.
2. Introduce a gearing system to the drive mechanisms. This would allow the buggy to travel at a slower speed, giving the LDR's plenty of time to sense changes in the road conditions and corrective conditions to be implemented appropriately.
3. Change the jockey wheel. The existing jockey wheel would often be mis-aligned when the buggy would try to change its direction of drive; the friction produced fighting against the motors. The installation of two jockey wheels, one in each rear corner, would elimainate this problem and allow the buggy to move more easily.
1. Supply a greater voltage to the motors. This could be done by either using the 9V battery, the connection to the motor being controlled by a seperate motor board circuit, or running a further voltage source in parallel with the current supply; maintaining the voltage (4.5V) but increasing the current supply to the motors. This extra step would increase the torque of the motors.
2. Introduce a gearing system to the drive mechanisms. This would allow the buggy to travel at a slower speed, giving the LDR's plenty of time to sense changes in the road conditions and corrective conditions to be implemented appropriately.
3. Change the jockey wheel. The existing jockey wheel would often be mis-aligned when the buggy would try to change its direction of drive; the friction produced fighting against the motors. The installation of two jockey wheels, one in each rear corner, would elimainate this problem and allow the buggy to move more easily.
Thursday, 15 April 2010
Electronics

The electronic circuit has been built as follows from the circuit diagram (Courtesy of Duncan Scriven), currently it resided on a bread board but will eventually be put on a circuit board to aid in weight reduction.The sensor and provisional LED array have also been made. This includes having 3 LDR's evenly spaced 0 0 0 and an ultra bright LED placed next to them to give light (as mentioned earlier more LEDs can be used. (The LED circuit for now has been made seperate to the motor circuit as to not drain the batteries but it can be attached to a pin.) After Testing the sensor array it became apparant that different ambient lighting affected the sesnor array so my sensor array will need to be completely enclosed so as the only light reaching the LDR will be coming from the LED's. It also became apparant that using just digital inputs was a bad idea having to manually change them when the lighting conditions continually change, so we have changed to reading the ADC output of each of the pins keeping the potentiometers at one level.
Friday, 9 April 2010
Proposed Pin Out diagram
This is the proposed pin-out of the actual PIC circuit board;
Output Pins 0-4 are used to control motor 1 or 2. ( 1 being the left hand motor, 2 being the right hand motor respectively looking at the buggy from the front). The Combinations shown are those to drive the motors forward ( i.e the combination of pin0 being high and pin 1 being low will drive the left hand motor forward, while reversing to Pin0 low and pin1 high will drive the left hand motor backwards.)
The sensor posistions are shown are indicated as if looking at the buggy from the front.
Pin 7 turns on a transistor that activates 5 LEDS mounted above the LDR sensors.
Its pretty flexible so if anyone needs anything moved to make their section a bit easier then give me a shout and ill see if it works and if so ill update the diagram.
Monday, 22 March 2010
Autonomous Vehicles
Autonomous Vehicles
This is just a quick look at the uses of smart systems applied to vehicles; the term autonomous here refers to the either the system being programmed to do a set task upon something happening, or being able to “think” what to do; either way it is defined as a smart system being able to perform a task without a “human in the loop” or without being told to.
Obviously vehicles can travel in three main mediums so we will look at theses first;
(to the above left is a picture of "Goliath" a WWII german remote controlled tank; not only was one of the first recored uses of remote control, but also of autonomity in robots. For a refernce, see end of post)
Land Vehicles
The term land here being used to describe any robot that moves over ground. These range from simple vaccum cleaners (see the video elsewhere on this blog) that can clean around a room to quadbikes that can navigate and steer themselves to a set location to deliver equipment as used by military forces and aid agencies and charities.
One of the greatest uses of autonomous robots is in jobs that are deemed to hazardous or risky for a human to perform and as such they have found a niche market as “ bomb disposal bots” or EOD robots.
For completely autonomous vehicles, several considerations are important;
1. Firstly the robot needs to know where it is heading to;
2. Secondly it needs to able to recognise obstacles and then either be able to avoid them or overcome them;
3. For a vehicle to be truly autonomous it needs to be able to figure out where it is in relation to where it needs to get to; In very simple autonomous robots this can be as simple as just set of directions to follow.
4. The vehicle needs to have an idea of how it moves (i.e how long it takes to turn so that it can correct its path)
Air Vehicles
Autonomous air vehicles(excluding satellites which aren’t covered here) are actually the most common type of autonomous robot around, with even toy remote controlled planes having a degree of autonomity in that if instructions cease to be send to it , it will either continue to fly itself or attempt to land in an area that it may know is safe.
Further more just to keep the aircraft in the sky a small amount of autonomity is needed for it to correct itself in mid flight and to keep itself stabilised. While this may not be considered true autnomity it certainly does not require, or even keep a human in the loop to perform these operations.
Due to the relative cheapness of UAVs compared to the manned piloted planes, they are increasingly popular with security ,police and military forces . Robotic helicopters equipped with cameras and infra-red vision are being used by the fire service to try and detect bodies in danger zones : and the same are used by the police to try and track down criminals in the open.
As stated in the considerations above, a UAV must be able to know where it is heading, where it is presently in relation to where it is headed and be able to recognise any obstacles in the way. Furthermore in top of this, it must be able to continually adjust and balance itself to stay in flight.
Sea Vehicles
While they exist and are in use, autonomous sea robots or boats are surprisingly rare,
however they are finding use as remote controlled submarines. Indeed most Robotic sea vehicles are underwater submarines and while the use of auton is small as they need to receive human interaction to be told what to look at , there are certain in-built protocols that kick in for the robot to monitor and control itself. ( For example, when running out of power the robot will automatically surface.) Famous examples of uses of autonomous sea robots include the robot that was used to find the ship “Titanic” and the “Bismark”(see picture below)
however they are finding use as remote controlled submarines. Indeed most Robotic sea vehicles are underwater submarines and while the use of auton is small as they need to receive human interaction to be told what to look at , there are certain in-built protocols that kick in for the robot to monitor and control itself. ( For example, when running out of power the robot will automatically surface.) Famous examples of uses of autonomous sea robots include the robot that was used to find the ship “Titanic” and the “Bismark”(see picture below)Due to the lack of knowledge about the underwater world, theses autonomous vehicles require both an internal system to stablise them selves, but the majority of their steering is down via remote control and then guided to where they are needed or/wanted.
Militrary Autonomous Vehicles
As can be seen from the preceding paragraphs, one of the biggest users of autonomous robots is the military and more than any other the US Military, hence a discussion purely on military uses of Autonomous robotics.
Have been in use for many years; in fact the first uses of autonomous vehicles was as aerial spy planes; the premier spy robot in the world, “Global hawk” has now been in the service with the US military since 1998.
Unmanned Ground Vehicles
For every military, body backs are the worst public image they could have; for that reason robotic systems are being used in any situation with a possiblite of danger. “Spy bots” are now used to scout out buildings or potentially dangerous locations; Self steering buggies are now being used as “Pack buggies” to carry equipment and reduce the soliders load. It was only a matter of time before weapons were added to such bots and now weapons placement are not common on military UGVs but for the US certainly all systems sent into an active warzone are equipped with weapon systems. However due to fears raised in popular Sci-fi films and the media ( The films “Stealth” and “Terminator” for example) weapons systems have not been completely autominised for fear of them turning on the controllers or “Accidents”. In fact a US Navy study conducted in 2002 suggests that a autonomous weapons system must always keep a human in the loop for override capability, and that in the future, robotic warriors while probable must be programmed with a “moral compass”.
For where the US Military is heading with UGV technology, watch the video http://www.youtube.com/watch?v=tbtCweucgUg or
Explosive Ordanance Disposal (EOD) Vehicles
Autonomous robotics have really kicked off in the field of bomb disposal: by removing the need the for a human operator to be next to the bomb, they enable dangerous devices to be dismantled or disposed of from a safe distance. As can be seen from the media, the type of warfare being fought in modern conflicts requires large amounts of bomb disposal. Although unconfirmed one model of EOD robot, the “Sword” is said to have disarmed over 20,000 IED devices over its combat career since deployment to Iraq and Afghanistan in 2000.
Unmaned Surface Vehicle (USV)
Despite the interest in autonomous vehicles in other aspects of military operations, the limits of above surface autonomous vehicles have not yet over taken the capabilities of traditional RIBs and manned speedboats . Only one Autonomous vehicles has been confirmed to have entered service with any Navy .
(The protector USV, in service with the Singaporean and Israeli navies, see footage at http://www.youtube.com/watch?v=URyAhMdkWA4.)
Due to its short range, it is simply not practical to have them used for any other duty than harbour patrol.
The Future;
Smart systems are the future, and as they advance more and more they will become more integrated to make tasks both easier and safer making the potential market for autonomous robotics huge.
As stated in speeches by the Minister of state for strategic defence acquisition (Rt.Hon Lord Drayson) “the UK in the lead, globally on autonomous systems. It is a lead which we must fully exploit." Furthermore predicting that the economy for UAV`s let alone autonomous robotics as a whole will rise from £5bn to £40bn within 10 years, smart system design and autonomous robotics is an area emerging that Britain needs to invest in to maintain its lead in the world.
References
BAE Systems “ UK in lead on autonomous systems”
Times Warns “Military Robots must learn warrior code and ethics”
US Navy report states “Fears of Robots uprising, suggesting the need for a moral compass”
Future Weapons; Global Hawk
Future Weapons Robots
Future Weapons Crusher
Micro Spy Bots
Goliath Remote Control Tank;
Image taken from http://media.photobucket.com/image/gOLIATH%20tank/abndeuce/767186713_f2e0e184fe.jpg
“Sword” Image taken from
Global Hawk Image taken from;
Image of Autonomous Robot over the Bismarck
Subscribe to:
Posts (Atom)


