even-realities / EvenDemoApp

BSD 2-Clause "Simplified" License
76 stars 10 forks source link

Even AI Demo

The general process of the Even AI function is as follows: After the app and glasses are connected via dual Bluetooth, long press the left-side TouchBar on the glasses to enter the Even AI activation state. At this point, the app will receive the [0xF5, 0x17] command from the glasses. The app then needs to send a command [0x0E, 0x01] to the glasses to activate the right-side microphone for recording. Once the microphone is successfully activated, the app will receive a real-time audio stream in LC3 format. Keep pressing until speaking is finished, the maximum supported recording duration is 30 seconds. After the recording is finished, the app needs to convert the audio stream into text, which is then sent to the large model for a response. After the app successfully obtains the response from the large model, it can send the result to the glasses according to the Bluetooth protocol. By default, the result is transmitted automatically, page by page. During transmission, a single tap on the TouchBar will switch to manual mode, with the left-side TouchBar used for page-up and the right-side TouchBar for page-down. A double-tap on the TouchBar will directly exit the Even AI function.

G1’s Dual Bluetooth communication is unique, each arm corresponds to a separate BLE connection. During communication, unless the protocol specifies sending data to only one side (e.g., microphone activation to the right), the app should:

Protocol

Start Even AI

Command Information

Open Glasses Mic

Command Information

Receive Glasses Mic data

Command Information

Send AI Result

Command Information