Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Update supervision with better file handling#315

Merged
LukasWikander merged 31 commits into
devfrom
fix_updateSupervisionWithCoolStuff
Jan 12, 2021
Merged

Update supervision with better file handling#315
LukasWikander merged 31 commits into
devfrom
fix_updateSupervisionWithCoolStuff

Conversation

@LukasWikander

Copy link
Copy Markdown
Collaborator

Would like a discussion here. As part of the test I had the "object" report MONR at a random interval between 1 ms and 7 ms because I was curious if we could get away with breaking a geofence if we reported position often enough. It seems like we do - should we do anything about it?

Everything works as expected if we just report MONR with regular 10 ms intervals.

Also, the code needs a review.

@LukasWikander LukasWikander requested a review from sepast December 15, 2020 20:09
@konglobemeralt

Copy link
Copy Markdown
Member

@LukasWikander Do we know why it can not handle receiving MONR faster then every 10 ms? Checking every 10 ms sounds fast enough, but would it not be ideal to at least know how to adress this if necessecary?

Comment thread modules/Supervision/inc/geofence.hpp

@alfaro01 alfaro01 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a big review so I skimmed the code but it looks good.

About the update-frequency issue I wonder the same as @konglobemeralt, do we know what's the cause?

I think that geofences should be classed as a safety feature and if something can break it by just sending the position a bit too fast, it's a major issue.

Comment thread core/integration-tests/DONTRUNYET_905-geofenceTransgression.py
Comment thread modules/Supervision/inc/geofence.hpp
@LukasWikander

Copy link
Copy Markdown
Collaborator Author

The problem is that due to the shared memory we check MONR only once every X ms. So if MONR arrives faster than that we may miss one or two. The solution would involve somehow synchronising Supervision with the arrival of MONR so that it MUST check each and every one. How to do this is another matter...

@alfaro01, @konglobemeralt please leave either an approving review or request changes. I will not merge either way until this discussion has been settled.

@LukasWikander

Copy link
Copy Markdown
Collaborator Author

Conclusion: the vehicle must be outside of the geofence for at least 0.01 s for it to be considered as a violation.

@LukasWikander

Copy link
Copy Markdown
Collaborator Author

I have updated the script to reflect this. Re-review necessary.

@konglobemeralt konglobemeralt left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had forgotten about this PR. But all in all I think my points have been addressed.

@LukasWikander LukasWikander merged commit 74a0433 into dev Jan 12, 2021
@LukasWikander LukasWikander deleted the fix_updateSupervisionWithCoolStuff branch January 12, 2021 08:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants