Page 1 of 1

IDs of neighbouring Kilobots

Posted: Mon Jan 28, 2019 12:08 pm
by jholl
Hi all,

I'm new to ARGoS so apologies for the simple question.

I was wondering if it is possible to determine the list of neighbouring kilobot IDs that are communicating with one kilobot at any given time?

I understand that I can get the amount of neighbours by doing something like:

Code: Select all

CCI_KilobotCommunicationSensor::TPackets in = m_pcSensorIn->GetPackets(); LOGERR << in.size();
, but just not what neighbours they are.

Re: IDs of neighbouring Kilobots

Posted: Mon Jan 28, 2019 3:30 pm
by pincy
ARGoS strives to provide realistic simulation. In real life, you cannot have the id unless you send it, so in ARGoS it is the same. There are workarounds to provide the robots with information they would not be allowed to have - if you explain what you're trying to achieve, I might be able to provide you with better guidance.

Re: IDs of neighbouring Kilobots

Posted: Tue Jan 29, 2019 12:53 pm
by jholl
Hi, thanks for getting back to me.

Apologies if I was unclear in my question, yes that's what I am looking to do. How would I go about sending the IDs in a message? So, it is possible to customise each message sent as long as it is within the memory capacity?

Re: IDs of neighbouring Kilobots

Posted: Sat Feb 09, 2019 7:16 pm
by pincy
Yes, you can send in the messages whatever information you want. In real life you don't have many bits available, so you have to make do with the limits of the kilobot. Say you have 32 robots in your experiment, then you can use 5 bits to encode the id, and the rest of the available bits to encode information.