Uploaded October 2026 | Updated November 2026, 2 hours ago
I used my iPhone’s magnetometer to give it a pair of eyes. Core Motion reads magnetic-field changes; the app smooths the readings, subtracts a saved background, and maps the result to pupil movement.
Keep the phone still. It reacts to field changes, not the magnet’s exact location.
Free SwiftUI source code: github.com/betomoedano/magnet-eyes
I used my iPhone’s magnetometer to give it a pair of eyes. Core Motion reads magnetic-field changes; the app smooths the readings, subtracts a saved background, and maps the result to pupil movement.
Keep the phone still. It reacts to field changes, not the magnet’s exact location.
Free SwiftUI source code: github.com/betomoedano/magnet-eyes










