README.md (5021B)
1 # Open Rémora 2 3 A free dive computer for the Apple Watch Ultra: depth, dive time, no-decompression limit, decompression stops, 4 safety stop, ascent rate and alarms, with a logbook on the watch. 5 6 **Open Rémora is a secondary dive computer and is not certified.** Always dive with a primary dive computer and 7 follow it when the two disagree. No computation guarantees the absence of decompression sickness. 8 9 The app is available in English and French. 10 11 ## What it does 12 13 - Starts the dive by itself on submersion, or from "Ready to dive" and the Action button; ends it after one minute 14 at the surface. 15 - Bühlmann ZHL-16C with gradient factors (three conservatism levels or custom factors), air or nitrox up to EAN40, 16 fresh, salt or EN 13319 water. Surface pressure is measured by the watch, so altitude needs no setting. 17 - Dive screen in three pages turned with the crown (the touch screen is locked underwater): main page, details, 18 compass with a bearing. Alarms flash the whole screen and vibrate; warnings blink the value concerned. 19 - Logbook on the watch with the profile of each dive, tissues carried over to repetitive dives, no-fly and 20 altitude waiting times. 21 - Each dive is saved in Health as a diving workout and sent to the iPhone app, which hands it to 22 Sub Rascasse (the logbook app) through a shared folder, or exports it as UDDF. 23 - On the iPhone: watch status, read-only settings, last dive, "no-fly time" Live Activity and notifications. 24 25 The depth sensor entitlement granted by default stops at about 6 m; the 40 m entitlement is requested from Apple 26 (see `docs/VALIDATION.md`). 27 28 ## Layout 29 30 - RemoraKit, a separate repository checked out next to this one (`../remora-kit`), shared with other apps: 31 `RemoraDeco` (decompression engine, logbook model, UDDF export, Subsurface import, and the dive logic: start 32 on submersion, depth held when the reading is missing, alarms, end at the surface) and `RemoraUI` (formatting, 33 wording, alarm styling, settings screens, dive read-outs, terms). 34 - `OpenRemoraWatch`: the watch app (sensor, haptics, workout and dive session, Action button, screens, logbook). 35 - `OpenRemora`: the iPhone companion app. `OpenRemoraWidgets`: its Live Activity. 36 - `Shared`: sources compiled into several targets (sync contract with the iPhone and Sub Rascasse, Live Activity). 37 - `docs/DESIGN.md` (design notes), `docs/SHARING.md` (contract with Sub Rascasse), `docs/VALIDATION.md` 38 (validation of the engine against a Shearwater Petrel 3). 39 - `tools`: icon generator and scripts used for the Shearwater comparison. 40 41 English is the source language. The French translation is in the String Catalogs 42 (`OpenRemora/Localizable.xcstrings`, `OpenRemoraWatch/Localizable.xcstrings`, 43 `OpenRemoraWidgets/Localizable.xcstrings`, `OpenRemoraWatch/InfoPlist.xcstrings`); the texts that come from 44 RemoraUI are in that package's own catalog. 45 46 Some names stay in French on purpose because they are stored data or a contract with other apps: the files 47 `carnet.json` and `reglages.json` on the watch, `plongees.json` and `reglages-montre.json` on the iPhone, and the 48 shared folder `OpenRemora/Plongees/` of the app group `group.org.schurger.dive`. 49 50 ## Build and test 51 52 Requirements: Xcode 16 or later (Swift 6), [XcodeGen](https://github.com/yonaskolb/XcodeGen), and the RemoraKit 53 repository checked out as a sibling directory named `remora-kit`: 54 55 some-directory/ 56 open-remora/ (this repository) 57 remora-kit/ (RemoraKit) 58 59 On a Mac: 60 61 cd ../remora-kit && swift test # engine, dive logic and formatting tests 62 cd ../open-remora && xcodegen # generates OpenRemora.xcodeproj from project.yml 63 open OpenRemora.xcodeproj 64 65 `project.yml` is the source of truth; the `.xcodeproj` is not versioned. 66 67 The Makefile assumes the author's setup: the sources are edited on a Linux host and synced with `rsync` to a Mac 68 reachable over SSH as `chunga`, which runs Swift and Xcode. Every target syncs both this repository and RemoraKit 69 (`KIT`, `../remora-kit` by default) so that they are siblings on the Mac too. Set `CHUNGA` (the SSH host), `REMOTE` 70 (the directory on the Mac) and, if needed, `KIT` and `REMOTE_KIT` to adapt it: 71 72 make test-deco # swift test in RemoraKit 73 make build-watch # watch app, watchOS simulator, unsigned 74 make build-phone # iPhone app with its widget and the watch app, iOS simulator, unsigned 75 make build-watch CHUNGA=my-mac REMOTE=src/open-remora 76 77 `make archive` and `make upload` produce and send a signed build to TestFlight; they need the author's signing 78 setup. 79 80 Launch arguments used for screenshots and dry runs: `-demo` (demo logbook, simulated compass), `-simulate` 81 (accelerated demo dive; with `-deep`, `-slow`), `-ready`, `-showDive`, `-showProfile`, `-page2`, `-page3`, 82 `-testAlarm`, `-showSettings`, `-showAdvancedSettings`, `-acceptTerms`, and `-liveActivity` on the iPhone. 83 84 ## License 85 86 GPL-2.0-only. See [LICENSE](LICENSE).