Go to the source code of this file.
Data Structures | |
struct | SensorMatrix |
Functions | |
SensorMatrix * | sensor_matrix_create (void) |
Create a sensor matrix. | |
void | sensor_matrix_destroy (SensorMatrix *m) |
Destroy a sensor matrix. | |
void | sensor_matrix_add_robot (SensorMatrix *m, unsigned int id) |
Add a robot to a sensor matrix. | |
void | sensor_matrix_remove_robot (SensorMatrix *m, unsigned int id) |
Remove a robot from a sensor matrix. | |
void | sensor_matrix_set_reading (SensorMatrix *m, int observer, int robot, int reading) |
Set a reading in a sensor matrix. | |
int | sensor_matrix_get_reading (SensorMatrix *m, int observer, int robot) |
Get a reading in a sensor matrix. | |
void | sensor_matrix_set_in_ring (SensorMatrix *m, int robot, int in) |
Set whether the robot is in the token ring. | |
int | sensor_matrix_get_in_ring (SensorMatrix *m, int robot) |
Get whether the robot is in the sensor ring. | |
int | sensor_matrix_get_size (SensorMatrix *m) |
Get the size of the sensor matrix. | |
int | sensor_matrix_get_joined (SensorMatrix *m) |
Get the number of robots which have joined the token ring. |
Contains functions and declarations for using sensor matrices.