set parameter using launch file
I have three different but related questions
1st: Is it possible to set the value of a variable using the launch file? I read about it online but I couldn't understand how to use it.
2nd: I couldn't find anything on how to use the launch file to set the value of a variable in a message. for instance if I have:
mymessagevector.msg:
mymessage myvector[2]
mymessage.msg:
int32 value
string ID
Is there a way to set the myvector[0].ID="ID1" and myvector[1].ID="ID2" and always publish that without having to define it everytime I sent the message to a topic?
3rd: If I don't know how many variables I have and I want to publish each variable in a different topic like /commontopic/var1 ; /commontopic/var2 ; /commontopic/varN , is there a way to achieve this using the terminal? Thank you in advance