Touch Calibration
The NanoVNA-H touchscreen requires calibration to ensure accurate tap detection. This is especially important after replacing the screen or if touch inputs seem offset.
When to Calibrate
Section titled “When to Calibrate”Touchscreen calibration is needed when:
- Touch responses are offset from tap location
- Menus are difficult to select
- After replacing the display
- After a firmware reset
Start Touch Calibration
Section titled “Start Touch Calibration”Via Menu
Section titled “Via Menu”- Tap the screen to open the menu
- Navigate to
CONFIG - Tap
TOUCH CAL - Follow the on-screen prompts
Via Shell Command
Section titled “Via Shell Command”touchcalThis starts the calibration process immediately.
Calibration Process
Section titled “Calibration Process”- A crosshair appears at the top-left corner
- Tap precisely on the center of the crosshair
- A crosshair appears at the bottom-right corner
- Tap precisely on the center of this crosshair
- Calibration completes automatically
After Calibration
Section titled “After Calibration”After successful calibration:
- The device returns to normal operation
- Test by tapping different areas of the screen
- If still inaccurate, repeat calibration
- Save configuration with
saveconfigto preserve settings
Save Calibration
Section titled “Save Calibration”Touch calibration data is stored in the configuration. To preserve it across power cycles:
saveconfigOr via menu: CONFIG > SAVE
Test Touch Accuracy
Section titled “Test Touch Accuracy”After calibration, verify accuracy:
Via Menu
Section titled “Via Menu”Navigate through menus and verify:
- Menu items respond to direct taps
- Marker placement works correctly
- Keypad buttons are responsive
Via Shell Command
Section titled “Via Shell Command”touchtestThis enters a test mode showing raw touch coordinates. Touch different areas and verify the coordinates match the tap location.
To exit touch test: tap rapidly or use the shell to send a command.
Shell Commands
Section titled “Shell Commands”# Start touch calibrationtouchcal
# Test touch coordinatestouchtestCalibration Data
Section titled “Calibration Data”Touch calibration uses two reference points to calculate:
- X and Y offset
- X and Y scaling factors
The calibration compensates for:
- Panel alignment tolerances
- Mounting variations
- Touch controller offsets
Troubleshooting
Section titled “Troubleshooting”Calibration Won’t Start
Section titled “Calibration Won’t Start”- Ensure the device isn’t in sweep mode (pause first)
- Try using the shell command
touchcal - Restart the device and try again
Calibration Seems Wrong After Completion
Section titled “Calibration Seems Wrong After Completion”- Repeat calibration with more careful taps
- Use a stylus for precision
- Ensure you tap the exact center of crosshairs
Touch Still Inaccurate
Section titled “Touch Still Inaccurate”- Clean the screen surface
- Check for screen protector interference
- Verify display is properly seated
- Try multiple calibration attempts
After Replacing Screen
Section titled “After Replacing Screen”New screens may have different touch characteristics:
- Install new screen
- Power on device
- Immediately run touch calibration
- Save configuration
Default Calibration
Section titled “Default Calibration”If the touch becomes unusable and you cannot navigate menus:
- Connect via USB
- Open serial console
- Run
touchcalcommand - Complete calibration using on-screen crosshairs
- Run
saveconfigto save
Technical Details
Section titled “Technical Details”The touch calibration stores:
_touch_cal[0]: X offset_touch_cal[1]: Y offset_touch_cal[2]: X scale factor_touch_cal[3]: Y scale factor
These values transform raw touch ADC values to screen coordinates.