-
-
Notifications
You must be signed in to change notification settings - Fork 20
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
Filter non-motion data #5
Comments
I think this would be very hard to do in real time. Your 3DH does have a FIFO buffer, but only a few samples worth. I doubt even the Cortex can store 30 seconds of data at 1+ kHz. (I tried storing 500 lines of csv data in an array and things started getting really weird.) On the other hand I think it would be easy to write a script that would sort through a huge data file, identify the shot events, take an excerpt of the huge data file starting a few seconds before the shot to a few seconds after the shot, then save that excerpt as a csv file with a filename such as dateTime_shot_xx.csv |
Great project, thanks for sharing. I will try port it to the teensy3.5 chip which is super fast at writing data to SD card, I also regularly use arrays to store GPS and other sensor data so i think it would be possible to buffer the data and then dump it to the SD card after a shot. I logging data against an actual time of day is important, as well as easy and live downloads to mobile devices , I can port this code to an ESP32 chip to which you can connect your phone over wifi or bluetooth. |
@jasza2 That's great! I'd love to see the results! |
@erichiggins FYI I had a sparkfun Razor IMU on hand: https://www.sparkfun.com/products/14001 so I wrote a data logger similar to yours, with the addition of a small OLED screen that displays the accelerometer chart and max. G. force experienced immediately after the shot. Apart from compactness, There is no compelling advantage of the sparkfun Razor over your design , but the Sparkfun Razor does have bulit in battery support for small LIPO batteries, plus its all in one neat package (excluding the OLED dispay which needs to be soldered on). I will test my unit on my boy's air-rifle, and when i next go to the range, on my big boys rifle. In the meantime, can you tell me what the max G force is that you expect to log, and also how many readings over what time period must I log. |
@jasza2 Cool! I loaned out the unit that I built and the people who are using it have it set to the 16G setting. Going from memory, the issue is that the higher G settings trade off resolution. So, it depends on what data on which axes you hope you track. For example, if you just want to track the trigger and recoil, you only need one axis and it could be fairly coarse. However, if you want to track the slight movements left/right up/down in the firearm while the trigger is pulled, then you need it to be both fast and precise, but not as high of a G rating. Hope this helps! |
Hello! I wanted to make it easier for folks building these units to chat with and support each other, so I setup a Discord! This link expires in 1 day to keep out spammers, but feel free to contact me directly if you'd like an invite. |
As of today, the unit records data as long as it's powered on. For the purposes of firearm acceleration, the resulting dataset also includes time between shots when nothing is happening. This non-motion data isn't particularly useful, and wasteful in other ways:
Ideally, the sensor could keep, say, 10-30 seconds of data in a FIFO buffer, That data won't be written to disk until it contains motion.
Keep in mind:
The text was updated successfully, but these errors were encountered: