Inspiration

People with Congenital Insensitivity to Pain (CIP) live without one of our most fundamental protective mechanisms. While their sense of touch works normally, pain signals never reach their brain, leaving them vulnerable to burns, cuts, broken bones, and tissue damage from everyday activities. CIP is deeply under-researched simply because it's rare, but no patient should fall through the cracks because of that. We were inspired to create a solution that could give these patients a new way to sense danger before damage occurs.

What it does

ReSense is a training and guidance tool that creates an entirely new sensory channel for CIP patients. By combining a Meta Quest headset with an Afference haptic ring and sensor glove, ReSense converts danger signals: heat, pressure, and unsafe contact duration; into customizable haptic feedback patterns that users can learn to understand. Instead of relying on pain they cannot feel, CIP patients learn to regulate their limits through this new form of feedback that their bodies can actually perceive.

How we built it

At its core, the project integrates a diy FlexGlove equipped with flex sensors and a thermistor for temperature monitoring, paired with a servo motor-based haptic feedback system. The FlexGlove features five individual flex sensors (one for each finger) connected to an ESP32 microcontroller, which wirelessly transmits sensor data via Bluetooth Low Energy (BLE). Our Unity application receives this data in real-time and translates finger movements into three distinct states: Relaxed (when fingers are extended), Contracted (during normal flexion), and Overstressed (when fingers are bent too far). These states are displayed in the VR environment with intuitive color coding—green for relaxed, orange for contracted, and red for overstressed—providing CIP patients with visual warnings about potentially harmful hand positions that they cannot feel.

Beyond finger tracking, the glove also includes a thermistor-based temperature sensor that monitors ambient temperature. We implemented a sophisticated temperature conversion algorithm using the Beta equation to accurately convert raw ADC readings into Celsius, complete with calibration offsets for precise measurements. This temperature data drives a unique passthrough visual effect system: when temperatures drop below 15°C, the VR passthrough edges pulse with a frosty blue glow, and when temperatures exceed 50°C, they pulse with a fire-red warning. For CIP patients who cannot sense burns or frostbite, these visual warnings are critical safety features that prevent serious injuries.

To provide tactile feedback, we implemented a servo motor that oscillates to simulate vibration patterns. This haptic feedback system alerts CIP patients to dangerous conditions—such as overstressed finger positions or extreme temperatures—through physical vibration that they can perceive, even though they cannot feel pain. The servo motor oscillates at different frequencies and intensities based on the severity of the detected condition, creating a multi-modal warning system that combines visual cues in VR with physical vibration feedback.

Challenges we ran into

One of the most significant challenges we encountered was attempting to establish concurrent Bluetooth Low Energy (BLE) connections between the ESP32-powered FlexGlove and the Afference haptic feedback ring. Initially, we planned to have both devices communicate simultaneously with the Meta Quest headset—the ESP32 transmitting flex sensor and temperature data, while the Afference ring would provide haptic feedback based on those readings. However, we ran into persistent BLE connection issues where the two devices would interfere with each other, causing dropped connections, data loss, and unreliable communication. Despite extensive debugging of the Android BLE stack, GATT service management, and connection lifecycle handling, we were unable to achieve stable concurrent operation between the ESP32 and Afference ring. Facing time constraints and recognizing that reliable haptic feedback was critical for CIP patient safety, we pivoted to a creative solution: we replaced the Afference ring with a servo motor that oscillates to simulate vibration patterns. This servo motor solution eliminated the BLE complexity entirely, operating independently from the ESP32's BLE connection, and proved to be both more reliable and more cost-effective. While this wasn't the original technical approach we envisioned, it ultimately led to a simpler, more robust system that better served our users' needs.

Another major technical challenge was creating a reliable haptic feedback system using this servo motor. Since we had to pivot away from the Afference ring, we needed to carefully calibrate the servo motor's oscillation frequency, amplitude, and duration to create meaningful tactile feedback patterns that CIP patients could reliably perceive. We developed a mapping system that translates sensor data (finger stress levels and temperature extremes) into distinct vibration patterns, ensuring that different types of warnings feel distinct and recognizable.

Accomplishments that we're proud of

We built a working VR safety system for CIP patients using a custom FlexGlove with ESP32 BLE, real-time finger state monitoring (Relaxed/Contracted/Overstressed) with color-coded UI, and a thermistor-based temperature sensor with visual passthrough warnings. When concurrent BLE failed, we pivoted to a servo motor haptic solution that is reliable and cost-effective. The system provides multi-modal feedback (visual and haptic) to help CIP patients avoid injury in VR. We also achieved cross-platform support (Unity Editor via serial and Quest via BLE), enabling efficient development and deployment.

What we learned

We learned that hardware integration often requires pivoting when devices fail or don’t work together. The BLE concurrent connection issues taught us to prioritize reliability and user needs over the original plan. Designing for CIP patients highlighted the importance of accessibility and alternative feedback when natural sensory systems are absent. We gained experience with sensor calibration, temperature conversion algorithms, and mapping sensor data to meaningful user feedback.

What's next for ReSense

To enhance the MR experience, we foresee adapting a robust object detection and a VLM. On the hardware end, our glove design will be more compact and also adapt to more parts of the body. Adapting Afference's non-intrusive and small form factor for haptics is also what we envision.

Built With

  • afference
  • esp32
  • meta-quest
  • unity
Share this project:

Updates