utahrobotics / usr-ws-2023

Codebase (and other dependencies) for running our candidate for the 2023 competition
3 stars 1 forks source link

Pozyx Localization #6

Open manglemix opened 2 years ago

manglemix commented 2 years ago

What must be done We need a node that can publish messages, which are estimates of our current position and orientation as reported by Pozyx. The exact names and format of these messages has yet to be decided, as it has to be in a specific format to work with Navigation2

Existing 3rd party solutions I have done some research, and I myself could not find a well used ROS 2 Node that does this.

Existing internal solutions We have a ROS 1 Node that did this, but I do not recall relying on it during any stage of testing. The code for Pozyx should be very similar to what we did in ROS 1, but the code must be tweaked for python 3.8

Quirks or Specifics This is an easier way to start working with peripherals, as pypozyx handles some of that already. However, testing your code is virtually impossible without an actual Pozyx setup, and I cannot allow you guys to take these components home. So you have to have your code ready before the in-person meetings to test it. I've also attached the first pozyx tutorial in the reading list

AGilsoul commented 1 year ago

Can we create a new branch for this?

AGilsoul commented 1 year ago

And also, the code in usr_ws_2021 that uses this, is it anchor_calibration.py?

manglemix commented 1 year ago

Most of the code in there is test code that I do not believe has successfully produced good readings, but they are able to connect to the Pozyx anchor. I strongly suggest reading the Pozyx developer documentation as well if you want to tackle this. There is already a pozyx branch for this, but it is old, so merge main into pozyx to update it

AGilsoul commented 1 year ago

okay, also for figuring out location, will pozyx be using the anchors or apriltags? I think I have some code that should work using anchors.

AGilsoul commented 1 year ago

that pull request was an accident ignore that.

manglemix commented 1 year ago

localization during driving will be with pozyx anchors, but the last team lead thought that we should try using apriltags for dumping

AGilsoul commented 1 year ago

Okay, should we try and see if we can get it working with anchors first and then move to apriltags?

manglemix commented 1 year ago

yes

AGilsoul commented 1 year ago

https://github.com/pozyxLabs/Pozyx-Python-library/blob/master/pypozyx/definitions/constants.py current pozyx error codes