Introduction
The project involves using BF120 strain gauges, an HX711 amplifier, and a custom in-amp setup to measure the deformation of the 3D-printed structure as it responds to the dynamic forces exerted by the moving mass. This setup allows for tracking of the mass's position over time. The team is expected to leverage an understanding of microcontrollers, analog-to-digital conversion, and signal processing to achieve accurate real-time measurements. Additionally, this project emphasizes the importance of mitigating loading errors and understanding the limitations and advantages of strain gauge technology. This project contained one additional contributor; however, both team members collaborated on every component of the design rather than splitting up work, and the project can be replicated by me individually.
Sensor Dynamics
This sensor uses a BF120 strain gauge, which detects deformation of a material through changes in electrical resistance in its metal foil grid as forces are applied. Stretching increases resistance and compression decreases it. Key sources of error include temperature changes affecting the foil, adhesive issues impacting contact with the substrate, and improper gauge placement altering readings, while advantages are versatility for various materials, low power consumption, and durability. Signal processing through amplification and filtering is required for accurate readings, as the resistance changes are small and sensitive to external influences, necessitating precise installation and robust circuitry.
Complete Signal Processing
Wheatstone Bridge
The Wheatstone bridge circuit was chosen for its high sensitivity to small resistance changes in the strain gauge, with all resistors initially set to 120Ω to keep Vout at 0V. Any change in resistance unbalances the circuit and shifts Vout, while differential measurements effectively cancel out external noise, resulting in cleaner data. Its straightforward design is easy to amplify and offers improved linearity over a half-bridge.
Amplification Stages
There are two separate amplification stages, one for each respective strain gauge. This section will go over both. In an engineering context, we would just use the best amplifier for both strain gauges, but for this project, we decided to use two separate amplification techniques to further our understanding
HX711
The HX711 is a 24-bit analog-to-digital converter (ADC) that is specifically designed to be used in systems with load cells and strain gauges. The input signal (differential output across the Wheatstone bridge) first goes through an input multiplexer with a programmable gain amplifier (PGA) that is used to select the gain channel A or B. Channel A can be used to set the gain of the signal to 128 or 64, while channel B has a fixed gain of 32. This is the amplification component of this circuit. It provides the necessary high gain that is needed since the differential output of the Wheatstone bridge is small. The particular gain value is set in the program on the Arduino. The inner workings of the chip can be seen in the figure below.
In-amp
In addition to the HX711, the team’s design consisted of a custom in-amp setup for the second strain gauge on the apparatus. It was made using the INA121. The overall gain of the output is governed by the equation, Vout = G * (Vin+ - Vin-), where G = 1 + (50kΩ/Rg). Thus, the gain is set by the gain resistor Rg. The resistor used in our team’s implementation is 470Ω, thus resulting in an overall gain of 107. This high gain is necessary to amplify the small signal coming off the differential output of the Wheatstone bridge.
Digital Logic Implementation and Experimental Results
Digital Logic Implementation
The digital logic implementation centers on using the Arduino Uno R4 microcontroller, chosen for its 14-bit ADC capability, robust I/O ports, simplicity of C++-based coding, and extensive library support, especially for interfacing with the HX711 chip. Calibration is dynamically handled in software by capturing min, max, and midpoint values over a brief sampling period every swing, enabling a real-time linear transfer function that converts analog readings to precise angle measurements. The loop routine reads analog data, updates calibration values, and calculates the normalized angle, ensuring consistent trajectory estimation despite sensor or environmental variations.
Experimental Results
The waveform of the mass swinging between +/- 40 degrees can be seen to the right. Note: the design can measure 90+ degrees of range, however, getting an image at that range is difficult due to setup and the immediate loss of energy of the mass when swinging. The output at this range is sinewave-like. The team accounts this to the fact that the apparatus lifts from the edge of the workbench at this range. Due to the momentum of the mass and the larger range, the mass exerts more force on the apparatus, forcing it to come off of the table, resulting in a consistent disturbance in the signal at the peak when the apparatus is being lifted. Despite the distortion, the trajectory of the apparatus can still clearly be seen as it moves.