Try using the Bluetooth Low Energy (BLE) API of THETA X. THETA's BLE APIs are unique profiles defined on Bluetooth's Generic Attribute Profile (GATT). THETA is a BLE peripheral, and a device calls THETA's API is BLE central. The THETA advertisement is scanned by the central and a connection request is issued. If the connection request is accepted, the connection can be made and the communication can be started by GATT. Many free applications for BLE scanning, connection, and GATT communication are available, so that using THETA's BLE API in the app first will speed up your understanding.
Turn on THETA, and turn Bluetooth on to the shooting screen to advertise. The advertisement packet contains the following information:
The connection can be started by issuing a connection request from the central, and GATT communication can be started. In GATT, the server is THETA, and the client is the device that calls the API of THETA.
THETA X currently supports only Camera Control Command v2 service. This service contains the following four character lists.
Property is read
only.
Returns camera information in JSON format.
Response example:
{
"_bluetoothMacAddress": "58:38:79:46:F7:61",
"firmwareVersion": "2.30.0",
"manufacturer": "Ricoh Company, Ltd.",
"model": "RICOH THETA X",
"serialNumber": "15001045",
"_wlanMacAddress": "-",
"uptime": 46
}
Property is read
only.
Returns the THETA state in JSON format.
Response example:
{
"_batteryInsert": true,
"batteryLevel": 0.97,
"_batteryState": "disconnect",
"_cameraError": [],
"_captureStatus": "idle",
"_capturedPictures": 0,
"_function": "normal",
"_latestFileUrl": "",
"_recordableTime": 3844,
"_recordedTime": 0,
"_batteryTemp": 29,
"_boardTemp": 28,
}
Property is read
only.
Returns the THETA state in JSON format.
Response example:
{
"_externalGpsInfo": {
"gpsInfo": {
"_altitude": 10.0000000000000,
"_dateTimeZone": "2024:01:11 06:03:20+00:00",
"_datum": "WGS84",
"lat": 35.0000000,
"lng": 135.0000000
}
},
"_internalGpsInfo": {
"gpsInfo": {
"_altitude": 0,
"_dateTimeZone": "",
"_datum": "",
"lat": 65535,
"lng": 65535
}
}
}
Property is "notify" only.
If there is any change in the status, notification is made in JSON format.
Example of notification:
{ "batteryLevel": 0.91 }