From b15dc75ad5c6295962b60e3c498fa3e8568e81e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=27=C3=A9lectron=20rare?= <108685187+electron-rare@users.noreply.github.com> Date: Mon, 18 May 2026 15:28:42 +0200 Subject: [PATCH] feat(avlivewire): shared wire package skeleton --- shared/AVLiveWire/Package.swift | 14 ++++++++++++++ .../AVLiveWire/Sources/AVLiveWire/AVLiveWire.swift | 5 +++++ .../Tests/AVLiveWireTests/SmokeTests.swift | 8 ++++++++ 3 files changed, 27 insertions(+) create mode 100644 shared/AVLiveWire/Package.swift create mode 100644 shared/AVLiveWire/Sources/AVLiveWire/AVLiveWire.swift create mode 100644 shared/AVLiveWire/Tests/AVLiveWireTests/SmokeTests.swift diff --git a/shared/AVLiveWire/Package.swift b/shared/AVLiveWire/Package.swift new file mode 100644 index 0000000..762034b --- /dev/null +++ b/shared/AVLiveWire/Package.swift @@ -0,0 +1,14 @@ +// swift-tools-version:5.9 +import PackageDescription + +let package = Package( + name: "AVLiveWire", + platforms: [.macOS(.v13), .iOS(.v17)], + products: [ + .library(name: "AVLiveWire", targets: ["AVLiveWire"]), + ], + targets: [ + .target(name: "AVLiveWire"), + .testTarget(name: "AVLiveWireTests", dependencies: ["AVLiveWire"]), + ] +) diff --git a/shared/AVLiveWire/Sources/AVLiveWire/AVLiveWire.swift b/shared/AVLiveWire/Sources/AVLiveWire/AVLiveWire.swift new file mode 100644 index 0000000..82dc8d2 --- /dev/null +++ b/shared/AVLiveWire/Sources/AVLiveWire/AVLiveWire.swift @@ -0,0 +1,5 @@ +/// AVLiveWire — binary frame format shared by ARBodyTracker (iOS) +/// and AVLiveBody (macOS) over the USB transport. +public enum AVLiveWire { + public static let protocolVersion: UInt8 = 1 +} diff --git a/shared/AVLiveWire/Tests/AVLiveWireTests/SmokeTests.swift b/shared/AVLiveWire/Tests/AVLiveWireTests/SmokeTests.swift new file mode 100644 index 0000000..c946196 --- /dev/null +++ b/shared/AVLiveWire/Tests/AVLiveWireTests/SmokeTests.swift @@ -0,0 +1,8 @@ +import XCTest +@testable import AVLiveWire + +final class SmokeTests: XCTestCase { + func testProtocolVersion() { + XCTAssertEqual(AVLiveWire.protocolVersion, 1) + } +}