You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I found that when I did this, the specific mission item wasn't being updated. It wasn't even sending the mission item at all. In any case, I had to call a function like .add(command_drone[2]) and then upload to update the mission item properly. However, this approach was adding an extra mission item to the end of the mission.
To address this issue, I started looking into the library's code and realized that there isn't a direct function to update a mission item. As a temporary solution, I added the following function:
'''
When you want to change the mission command only, use this function before upload.
'''
self.wait_ready()
self._vehicle._wpts_dirty = True
This function sets the self._vehicle._wpts_dirty variable to True, even if you don't add any commands, allowing you to execute the .upload() function without using the .add() function. I'm not sure if this is a correct solution. Can you confirm if this is a valid approach, or suggest an alternative solution?
The text was updated successfully, but these errors were encountered:
furkan-hub
changed the title
Chancing a specific mission
Unable to Update a Specific Mission Item in DroneKit: Seeking Guidance on a Workaround
Feb 5, 2024
I noticed in the code snippet you provided that the rate parameter is set to 100 in the connect() function. However, in Mission Planner, the typical range for this setting is between 0 and 50 Hz. When I use 50 Hz, I only achieve about 12 Hz in practice. Is it valid to set rate higher than 50 (e.g., 100) to potentially increase the frequency, or are there limitations?
Hello friends, the other day while working with DroneKit, I noticed that I couldn't update a specific mission item. For example:
I found that when I did this, the specific mission item wasn't being updated. It wasn't even sending the mission item at all. In any case, I had to call a function like .add(command_drone[2]) and then upload to update the mission item properly. However, this approach was adding an extra mission item to the end of the mission.
To address this issue, I started looking into the library's code and realized that there isn't a direct function to update a mission item. As a temporary solution, I added the following function:
This function sets the self._vehicle._wpts_dirty variable to True, even if you don't add any commands, allowing you to execute the .upload() function without using the .add() function. I'm not sure if this is a correct solution. Can you confirm if this is a valid approach, or suggest an alternative solution?
The text was updated successfully, but these errors were encountered: