I am developing a multi-robot experiment in which the robots should communicate. I have simulated multiple robots using a shell script and executing the control code multiple times with each different robot. I need the robots to broadcast some data to all of the robots that are nearby. This data is mostly ints and booleans and preferably in some kind of class. The robots need to be able to send this data to all running robots in the vicinity.
What would be the best way to do this?