Feature #137

maximum number of object

Added by Marco Tognon over 1 year ago. Updated 6 months ago.



I reached the maximum number of objects when I run all the components to fly three quads on the same machine (20 genom components).


genomixd-v-v.txt (161 KB) genomixd-v-v.txt Pol MORDEL, 2018-10-03 18:02

Associated revisions

Revision 0509aa85 (diff)
Added by Matthieu Herrb 12 months ago

Get rid of the H2_DEV_MAX constant, limiting the number of h2 devices

h2 init -d <n> sets the maximum number of devices. Default is 120.

Revision dbfe3b06 [h2devMax] (diff)
Added by Matthieu Herrb 6 months ago

Replace gcomLetterAlloc()/gcomLetterDiscard by simple malloc/free wrappers

This removes the arbitrary limit on the number of letters.
It also makes gcomLetterList() always return 0.
XXX If needed a linked list of letters can be added back later.



Updated by Marco Tognon over 1 year ago

I also reached the MAX_LETTER in genomixd.
Loading a component in matlab I get: S_gcomLib_TOO_MANY_LETTERS


Updated by Pol MORDEL 12 months ago

Do you have any walk around for this feature ? I get the same error using 3 quadrotors simulated on the same machine (limit is 15 components)

Meanwhile I did try first with 4 quadrotors (21 components) and get directly the following message :
12:08:16.560856:genomixd: sock1dae130: reply status 404: {"ex":"::genom::mwerr","detail":{"what":"S_h2devLib_FULL"}

the difference here is that the FULL error shows immediately at first step of the setup while the TOO_MANY_LETTERS only shows at the 16th client.load

Though for the first case (TOO_MANY_LETTERS), I solved this issues by using multiple genomixd process on different port (one for each simulated machine); we cannot launch more than 20 components on the same machine (cannot create server mailbox: S_h2devLib_FULL).


Updated by Matthieu Herrb 12 months ago

In the h2devMax branch, you will find a pocolibs version where the maximum number of devices can be specified using '-d <num>' on the 'h2 init' command line.
I'm not 100% that this is enough to let your application scale to more components, but I haven't tried yet to create a regression test for this.
If you can test it on your setup, that would be nice.


Updated by Matthieu Herrb 12 months ago

  • Status changed from New to Feedback

Updated by Anthony Mallet 7 months ago

Hi Pol,

Any feedback about this? Could you test something?


Updated by Pol MORDEL 6 months ago

Hi Anthony,

I tried with the f2devMax branch as suggested (tried to launch up to 6 UAVs).

So adding the '-d' option on the 'h2 init' command line allow to solve the problem:

"mrsim_mk5: cannot create server mailbox: S_h2devLib_FULL"

To make sure I launched it using "h2 init -d 200" (I basically needed to increment this number by 6 for every component that I added)

Then, as I was saying in the post above, you still need to have several instance of genomixd launched on multiple port in order to run everything on the same machine to get rid of the (TOO_MANY_LETTERS) error.

So far it works for me.
By the way, we will start to work with pocolibs as well since we manage to compile the library of the vicon SDK for both armv7 and armv8 architecure from the source code that vicon provided us. We can now run the mocap onboard our UAV.


Updated by Anthony Mallet 6 months ago

Thanks for the detailed feedback.

Can you be more precise about when/how you get the TOO_MANY_LETTERS
message? Are you for instance sending many oneway or non-blocking

An excerpt of the `genomixd -v -v` log around the time when the issue
appears could also help.


Updated by Pol MORDEL 6 months ago

I get this error after a certain number of request since I try to setup more than 3 quadrotor in simulation on the same genomix client (should be about 15 different component that are setup by the time of the error).

You can find the details of the command 'genomixd -v -v' in the attached file, I set a breakpoint at the moment the script send the error but I do not find it relevant so far.

Anyway since we use one genomixd process/UAV in real experiment, I can do the same in simulation. That way I have a pretty similar script interface for both.


Updated by Anthony Mallet 6 months ago

On Wednesday 3 Oct 2018, at 18:09, Pol MORDEL wrote:

File genomixd-v-v.txt added

Thanks for the file (and your time), this is very useful!

So you get the error S_gcomLib_TOO_MANY_LETTERS when loading a
component, after loading many other components.

My analysis, still to be confirmed, indicates that the gcomLib
comm. library cannot allocate enough space in the genomix client
mailbox to guarantee that the maximum number of parallel requests can
be processed.

This may indicate (again to be confirmed) that my strategy to allocate
the client mailbox in genomix is not optimal. Currently, the
maxiumum required mailbox size for all clients is used. Maybe the
right strategy would be to instead sum the required mailbox size for
all clients.

I'll think more carefully about this to verify my analysis and come up
with a fix in a week or so.


Updated by Anthony Mallet 6 months ago

It was actually not related to genom3-pocolibs, but rather to another
hard limit inside pocolibs (dbfe3b06).

Matthieu just pushed a fix in the h2devMax branch.

Also available in: Atom PDF