Doubt regarding optionals on a Set

1 view
Skip to first unread message

lribeiro

unread,
Jul 1, 2008, 12:59:20 PM7/1/08
to a2c-discuss
Hello,

First my congratulations for the software!
In secound my doubts :)

I have a relative long especification with a set containing near 300
elements.
For what i could see to check optional menbers of a pdu you use a
variable of type int ("optionals", at A2C_Set.h ) to check if a
"child" is optional or not, setting the integer bits to mark it.That
is a problem for me because with 32 bits i'm limited to the number of
optional i can have...

I can tell you that i have near 300 optionals :)
And the result that i have when printing (A2C_Print_...) is that it
only shows me a piece of the message decoded.

Is there any workaround fo this ?

Best Regards

Jim Schaad

unread,
Jul 7, 2008, 4:56:06 PM7/7/08
to a2c-d...@googlegroups.com
The current drop does have a way to deal with this, although for 300 items
it might be a bit cumbersome to get setup.

If you use the Pointer command (section 4.5 of the readme), you can have
optional elements without using the optional mask. Depending on what you
are doing (i.e. large elements as optional) this is probably preferable
since it will occupy less space when those elements are absent from the
extant object.

If you feel it is really necessary for us to look at expanding the size of
the optional mask beyond the size of an integer we can look at this, however
it will be slightly clumsy for everyone to use as you would need to have a
macro to clear and set the mask bit rather than a simple bit flag.

Jim

Reply all
Reply to author
Forward
0 new messages