-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Updated the synchronisation tool #776
Conversation
IvyBindMsg(on_Airframe_ID, NULL, "^(\\S*) (\\S*)"); | ||
IvyBindMsg(on_Airframe_ID, NULL, "^(\\S*) (\\S*) (\\S*)"); | ||
IvyBindMsg(on_Airframe_ID, NULL, "^(\\S*) (\\S*) (\\S*) (\\S*)"); | ||
IvyBindMsg(on_Airframe_ID, NULL, "^(\\S*) (\\S*) (\\S*) (\\S*) (\\S*)"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why so many bindings to get the airframe ID ? If you only want the ID, you can bind to messages that starts with a numerical value (something like [0-9]+ ) and then anything ( .* ). But it is going to be a lot of messages in the end.
An other option is to bind to the PONG message.
Please try to follow the C style guideline, especially for if statement (I know it's annoying when it's not your coding habits...) |
Shouldn't the VIDEO_SYNC message also include the AC ID, so you can actually use it when you have multiple vehicles? |
and what should the sync id be used for? |
You mean adding the aircraft ID after the name of the message ? Putting it in from of it is not enough. Or you may be talking about a global variable that I don't know of. |
The sync ID is not used right now, but as far as you can press the sync button as much as you want I thought I might as well put an ID to the different sync. |
Ok, overlooked that you send the VIDEO_SYNC message as if it was actually coming from the aircraft... |
Actually, I don't see a need to add the VIDEO_SYNC message to telemetry, I think it would make more sense to add it to the ground class. @gautierhattenberger what do you think? |
You're right, VIDEO_SYNC message should be in ground class. But ground ground class doesn't produce C header, only datalink and telemetry. Yet, I suggest to add the message to the datalink class (and inlcude "dl_protocol.h" instead of "messages.h") since we are a bit short on ID for the telemetry class. |
OK, but I get an issue when trying to include dl_protocol.h (No such file or directory). I'm using :
I guess it's because I'm in the ground segment and not in the airborne part. |
I figured out how to include that file (I added it to the Makefile), but I still need "DefaultChannel" and "DefaultDevice". Those ones are in airborne code directly, and I can't figure out how to get them. |
Oups, I'm really sorry, I just realized that you don't need to use the binary format here, only the Ivy string format. So you don't need to messages C headers and the message definition can go to the ground class. |
ok, so I gess that I should send this message on the ivy bus :
And define the message in the ground class like so :
But if I do like that, I don't see it written into the log file, do I need to fetch it an other way afterwards ? |
hum, I didn't really looked at how it works. If you need to have it in the log file, you need to have it in telemetry class. So it seems your first shot was correct after all. |
So should we merge it as is, with the VIDEO_SYNC message in telemetry? |
no real other choice at the moment I'm afraid... |
I updated the tool for displaying a video in sync with the log file. Now you can create a "clap" (the screen blinks for 1s) in order to easily get a time flag in the video and in the log file (added a message for that).
I updated the tool for displaying a video in sync with the log file. Now you can create a "clap" (the screen blinks for 1s) in order to easily get a time flag in the video and in the log file (added a message for that).
I updated the documentation here : https://wiki.paparazziuav.org/wiki/Video_replay#How_to_use_it