nobody wrote on Wednesday, June 07, 2006:
There is an interesting but not very specific article in the June 2006 edition of Servo where the author spends a lot of time on Subsumption Architecture and winds up suggesting it be implemented with FreeRTOS. Yes! A plug for FreeRTOS.
I have a BDMicro MAVRIC controller (ATmega128 with 64k of external RAM) and FreeRTOS is running.
What I would like is some suggestions on how to structure the FreeRTOS MiniSumo application:
Highest Priority: back away when front edge detectors sense the edge of the ring.
Next Priority: move forward when rear edge detectors sense the edge of the ring.
Presumably these two are mutually exclusive.
Next… Attack if opponent is directly in front of bot
Next… Turn left to counter opponent on left side
Next… Turn right to counter opponent on right side
Next… Turn around to counter opponent to the rear
These 4 are mutually exclusive, as well.
Next… Search by turning and trying to find opponent
Now, all that is fairly straight forward (I suppose) but I was thinking that the sensor inputs would be read in an interrupt routine, perhaps setting flags or semaphores. Obviously, these are ‘volatile’ as they can be set and cleared at any time, for any reason.
So, I am looking for suggestions on high level structure. And, comments on the applicability of FreeRTOS to this project.