I am currently using RTI DDS on a system where we will have one main topic for multiple items, such as a car topic
with multiple vin
numbers. Since this is the design I am trying to then make a "keyed" topic
which is basically a topic that has a member acting as a key (kind of like the primary key in the database) which in this example would be the vin
of each car. To implement the keyed topics
I am using an IDL file which is as follows,
const string CAR_TOPIC = "CAR";
enum ALARMSTATUS {
ON,
OFF
};
struct keys {
long vin; //@key
string make;
ALARMSTATUS alarm;
};
When I run the IDL file through the rtigen
tool for making C,Java, etc kind of files from the IDL, the only thing I can do is run the program and see
Writing keys, count 0
Writing keys, count 1 ...
and
keys subscriber sleeping for 4 sec...
Received:
vin: 38
make:
alarm : ON
keys subscriber sleeping for 4 sec...
Received:
vin: 38
make:
alarm : ON ...
Thus making it hard to see how the keyed topics work and if they are really working at all. Does anyone have any input what to do with the files generated from the IDL files to make the program more functional? Also I never see the topic CAR
so I am not sure I am using the right syntax to set the topic for the DDS.