Things done this week:
- Tweaked angle calculation code more to account for the weirdness at the 90 degree angle mark. Tried a bunch of different calculation methods again, ultimately moved to a smaller Kalman filter that I could tune properly instead of a black-boxed Arduino library filter. Tuned the filter to make the outputs less noisy while still getting to the extreme angles.
- Debugged calibration commands between server and Pi. Should be finalized now.
- Finished hat assembly, for real this time (made some straps with buttons to hold the components in place).
- Started video testing with Kinovea to get a more quantitative sense of how to fine-tune the filter. Got a 10 min and 30 min sample (was going for an hour but I forgot to turn automatic sleep off on my computer…). Did the testing with 2 different people so far.
- Worked on the final presentation slides.
Progress?
Still in testing/benchmarking/tweaking mode since debugging stuff with the angle calculation took a little longer. The results from the first 2 testing sessions should be out today but I thought I’d type up this status report first.
Deliverables for next week:
- Set up “demo” and “real use-case” modes
- Finish testing over longer (1 hr) periods of time, and further tweak filters as needed.
- Finish final documents…
Learning?
I got a lot more familiar with the Arduino IDE and Python programming to get all the coding done for this part of the project. Luckily there were a lot of relevant Arduino libraries (particularly for bluetooth control and sensor drivers) so I was able to modify much of the example code to make it work for this application, along with adding the extra things I needed. I also learned about different angle estimation methods, including complementary, Kalman filters, and just doing trig on the acceleration vectors. This involved reading a lot of forum posts about the filters, and papers comparing the methods/explaining their disadvantages and advantages. Another thing I learned was how to use HTTP post and get requests, since I had never done that before and we needed a way to send data to and from the server. I learned this from my teammates, googling, and guess-and-checking with print statements to debug. One tool that I learned about for this project was Kinovea, which isn’t actually great for automatically tracking angles but that’s fine since I’m just going to manually measure them using the software anyway. The docs for Kinovea and the user interface are fine so I didn’t have to do much external research to figure out how to use the tool.
No images since I haven’t processed/analyzed my data yet :,,)
Here is a snippet of a testing session to demonstrate the setup: https://drive.google.com/file/d/1BQTXiCdb4EkZl6gPwkAzyboGbDKy8ZFB/view?usp=sharing