An open-source 6-axis Force/Torque (F/T) sensor based on Hall effect sensors and magnetic field displacement detection. Features 16 Hall sensors in 4 clusters, real-time visualization, and two calibration approaches (geometric and matrix-based).
openFT-sensor/
├── hardware/
│ ├── gerber/ # PCB fabrication files
│ ├── mechanical/ # 3D models (STEP files)
│ └── *.xlsx # Bill of Materials
├── software/
│ ├── ft_driver.py # Geometric force/torque driver
│ ├── ft_min_driver.py # Minimal raw sensor driver
│ ├── ft_vis.py # Visualization dashboard
│ └── calibration/
│ ├── calc_calibration_matrix.py # Calibration tool
│ ├── ft_calibration.json # Example calibration
│ └── CALIBRATION_GUIDE.md # Detailed calibration guide
└── requirements.txt
- PCB Fabrication: Use Gerber files in
hardware/gerber/or the pre-packaged zip file - Assembly: Upload BOM to JLCPCB for automated assembly, or solder manually
- Mechanical: 3D print magnet holder from STEP file in
hardware/mechanical/ - Connection: Connect via USB/serial to your computer
git clone <your-repo-url>
cd openFT-sensor
pip install -r requirements.txtRequires: Python 3.7+, pyserial, zmq, numpy, pandas, dash, plotly, tabulate
- How: Uses sensor geometry and coordinate transformations
- Pros: No calibration needed, quick start, good for testing
- Cons: Less accurate, assumes ideal geometry
- Use for: Testing, relative measurements
- How: Learned 6x16 matrix via least-squares regression from calibration data
- Pros: Much higher accuracy, compensates for real-world effects, accounts for cross-coupling
- Cons: Requires calibration equipment (load cell or reference sensor)
- Use for: Production systems, absolute measurements
Start driver:
cd software
python ft_driver.py- Default port:
/dev/ttyACM0at 115200 baud (edit line 163 to change) - Keep sensor unloaded for first 3 seconds to zero-bias
- Common ports:
/dev/ttyUSB0,/dev/ttyACM0(Linux),COM3(Windows)
Optional visualization:
python ft_vis.py # Open browser to http://localhost:8050For detailed calibration instructions, see CALIBRATION_GUIDE.md
Step 1: Collect calibration data
- Need reference F/T sensor or calibrated weights
- CSV format:
sensor_1,...,sensor_16,force_local_x,force_local_y,force_local_z,torque_local_x,torque_local_y,torque_local_z - Collect 100-200 samples across expected force/torque range
Step 2: Calculate calibration matrix
cd software/calibration
python calc_calibration_matrix.py --csv your_data.csv --output calibration.jsonSee ft_calibration.json for example output.
Step 3: Run minimal driver
cd software
python ft_min_driver.py --port /dev/ttyACM0 --zmq-port 5555 --verboseStep 4: Apply calibration live
cd software/calibration
python calc_calibration_matrix.py --live --calibration calibration.jsonSubscribes to raw data (port 5555), applies calibration, publishes calibrated F/T (port 5556).
Data flow:
ft_min_driver.py → calc_calibration_matrix.py → your_application
(port 5555) (port 5556)
Sensor Principle: Hall sensors measure magnetic field changes as the magnet assembly displaces under load. 16 sensors in 4 clusters (4 sensors each) detect X/Y/Z displacements, which are combined to compute 6-axis forces and torques.
Geometric approach: Uses sensor positions (Middle at 0°, Top at 0°/25mm, Bottom-Right at 240°/25mm, Bottom-Left at 120°/25mm) to calculate F/T from first principles.
Calibration approach: Maps raw sensor values directly to F/T using learned matrix that accounts for non-linearities, cross-coupling, and manufacturing variations.
Signal processing: Raw ADC → Moving average (window=3) → Zero-bias/calibration → Displacement calc → Coordinate transform → F/T output
Edit parameters in driver files:
ft_driver.pyline 11:moving_average_window,calibration_windowft_driver.pylines 17-19: Sensor geometry (cluster_angles,magnet_dist)ft_vis.pyline 91: Dashboard refresh rate (interval=100ms)ft_min_driver.py: Use--helpfor CLI options
Serial connection failed: Check cable, verify port name, add user to dialout group on Linux (sudo usermod -a -G dialout $USER)
Invalid sensor values: Should be 9000-21000. Check power supply, verify sensors soldered correctly, check magnet positioning
No visualization data: Ensure driver running first, check ZMQ ports match, verify no firewall blocking localhost
Zero-bias issues: Keep sensor unloaded during startup, wait for "Calibrated Averages" message
The calibration approach fuses data from all 16 sensors optimally:
- Learns optimal sensor fusion: Each F/T axis uses weighted combination of all 16 sensors
- Compensates non-linearities: Captures real sensor behavior vs. ideal assumptions
- Handles cross-coupling: Accounts for how forces in one direction affect sensors measuring other directions
- Corrects manufacturing variations: Each sensor is slightly different; calibration learns these differences
This is why calibration gives much higher accuracy than geometric calculations.
Contributions welcome! Report bugs, suggest improvements, submit PRs, or share your builds.
Open-source. See license file or contact maintainer for details.
Based on magnetic Hall effect sensing principles. Inspired by the open-source robotics community.