Edge Impulse logo
Blog Post

Drilling Home Safe Drilling Practices with Edge ML

TinyML, Machine LearningAre you using the right drill bit for that material? SafeDrill will let you know.

Nick Bild

June 16, 2022

    For hobbyists that are used to working on the software end of the hacking spectrum that find themselves working to bring their machine learning-powered creations to life, there eventually comes a time when they need to pick up some tools and — gulp — build a physical device. If this is you, and your tool handling skills resemble those of Tim “The Tool Man” Taylor, and you do not declare success in any project without counting your fingers before and after the project to make sure nothing has changed, then this sort of work can be quite daunting.  All joking aside, power tools can be dangerous when they are used improperly; each year 400,000 people in the US visit an emergency room due to power tool-related injuries.

    Engineering students at the University of Ljubljana, who have felt their own knowledge of proper power tool use lacking at times in developing their own projects, had the idea to use machine learning to create smart tools that provide a warning when they are being misused. They used Edge Impulse and a low-cost development board to build a device named SafeDrill that can be retrofitted onto any power drill to provide a warning when a drill bit is being used on the wrong type of material. This warning can prevent both injury to the drill operator as well as damage to the equipment itself.

    The 3D-printed SafeDrill case

    The team chose an Arduino Nano 33 BLE Sense because it checked all of the boxes for what they needed to achieve their goals. With an nRF52840 microcontroller running at 64MHz and 256KB of RAM, it has sufficient resources to run a tinyML-optimized algorithm.  The board also comes standard with a nine-axis inertial measurement unit (IMU) and a Bluetooth Low Energy radio. With Edge Impulse fully supporting this Arduino board, development of a machine learning data analysis pipeline that runs locally on the hardware is a snap. For the prototype, a 3D-printed case was created, which can be mounted to virtually any handheld power drill with a few zip ties.

    Before getting started with building the model, the team needed to collect some data to train it. This was accomplished by capturing IMU measurements while drilling with different drill bits on different materials. The focus was on drill bits for wood, metal, and concrete, with each drilling into all three of the corresponding materials, which yields a set of nine different classes. After 100 seconds of IMU data was captured for each class, it was uploaded to the Edge Impulse Studio machine learning development platform.

    Building and testing the prototype

    The impulse began with a spectral analysis to extract the most informative features from the input data. These features were then fed into a neural network classifier. The neural network was trained on the previously uploaded data such that it would be able to translate IMU data input into a prediction of the class that it belongs to. After validating that the model performed well, it was deployed to the Arduino where it can run in real time, and with minimal latency.

    The Arduino connects to a companion smartphone app via Bluetooth Low Energy. Once the connection has been made, inferences from the Edge Impulse model will be sent to the app while using the drill. Should a drill bit and material be mismatched, it will warn the user so that they can fix the issue before it can cause any serious problems. The app can also show a summary of the day’s tool usage, including the number of holes drilled, and total time spent drilling.

    With so many incredible creations like this being built all the time it is easy to forget just how amazing it is that useful inventions such as SafeDrill can go from idea to prototype in less than a day thanks to great tools like Edge Impulse and Arduino. Before you pull out your toolbox again, head over to the project page to read up on how SafeDrill was constructed.


    Want to see Edge Impulse in action? Schedule a demo today. 

    Subscribe

    Are you interested in bringing machine learning intelligence to your devices? We're happy to help.

    Subscribe to our newsletter