pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://github.com/dimensionalOS/openFT-sensor

ossorigen="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/primer-8522af645b000615.css" /> GitHub - dimensionalOS/openFT-sensor · GitHub
Skip to content

dimensionalOS/openFT-sensor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

OpenFT Sensor

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).

Repository Structure

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

Hardware Setup

  1. PCB Fabrication: Use Gerber files in hardware/gerber/ or the pre-packaged zip file
  2. Assembly: Upload BOM to JLCPCB for automated assembly, or solder manually
  3. Mechanical: 3D print magnet holder from STEP file in hardware/mechanical/
  4. Connection: Connect via USB/serial to your computer

Software Installation

git clone <your-repo-url>
cd openFT-sensor
pip install -r requirements.txt

Requires: Python 3.7+, pyserial, zmq, numpy, pandas, dash, plotly, tabulate

Two Approaches to Force/Torque Measurement

Approach 1: Geometric Calculation (Quick Start)

  • 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

Approach 2: Calibrated Matrix (High Accuracy)

  • 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

Usage: Approach 1 (Geometric)

Start driver:

cd software
python ft_driver.py
  • Default port: /dev/ttyACM0 at 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:8050

Usage: Approach 2 (Calibrated)

For 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.json

See ft_calibration.json for example output.

Step 3: Run minimal driver

cd software
python ft_min_driver.py --port /dev/ttyACM0 --zmq-port 5555 --verbose

Step 4: Apply calibration live

cd software/calibration
python calc_calibration_matrix.py --live --calibration calibration.json

Subscribes 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)

How It Works

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

Customization

Edit parameters in driver files:

  • ft_driver.py line 11: moving_average_window, calibration_window
  • ft_driver.py lines 17-19: Sensor geometry (cluster_angles, magnet_dist)
  • ft_vis.py line 91: Dashboard refresh rate (interval=100 ms)
  • ft_min_driver.py: Use --help for CLI options

Troubleshooting

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

How the Calibration Matrix Works

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.

Contributing

Contributions welcome! Report bugs, suggest improvements, submit PRs, or share your builds.

License

Open-source. See license file or contact maintainer for details.

Acknowledgments

Based on magnetic Hall effect sensing principles. Inspired by the open-source robotics community.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy