├── .gitignore
├── BlueST-SDK.md
├── CODE_OF_CONDUCT.md
├── CONTRIBUTING.md
├── License.html
├── README.md
├── README_HowToUseInternal.md
├── SECURITY.md
├── app
├── .gitignore
├── build.gradle.kts
├── proguard-rules.pro
└── src
│ └── main
│ ├── AndroidManifest.xml
│ ├── assets
│ └── open_source_licenses.html
│ ├── java
│ └── com
│ │ └── st
│ │ └── demo
│ │ ├── MainActivity.kt
│ │ ├── SampleApp.kt
│ │ ├── audio
│ │ ├── AudioScreen.kt
│ │ └── AudioScreenViewModel.kt
│ │ ├── device_detail
│ │ ├── BleDeviceDetail.kt
│ │ └── BleDeviceDetailViewModel.kt
│ │ ├── device_list
│ │ ├── BleDeviceList.kt
│ │ └── BleDeviceListViewModel.kt
│ │ ├── feature_detail
│ │ ├── FeatureDetail.kt
│ │ └── FeatureDetailViewModel.kt
│ │ └── ui
│ │ └── theme
│ │ ├── Color.kt
│ │ ├── Theme.kt
│ │ └── Type.kt
│ └── res
│ ├── drawable-v24
│ └── ic_launcher_foreground.xml
│ ├── drawable
│ └── ic_launcher_background.xml
│ ├── mipmap-anydpi-v26
│ ├── ic_launcher.xml
│ └── ic_launcher_round.xml
│ ├── mipmap-hdpi
│ ├── ic_launcher.webp
│ └── ic_launcher_round.webp
│ ├── mipmap-mdpi
│ ├── ic_launcher.webp
│ └── ic_launcher_round.webp
│ ├── mipmap-xhdpi
│ ├── ic_launcher.webp
│ └── ic_launcher_round.webp
│ ├── mipmap-xxhdpi
│ ├── ic_launcher.webp
│ └── ic_launcher_round.webp
│ ├── mipmap-xxxhdpi
│ ├── ic_launcher.webp
│ └── ic_launcher_round.webp
│ └── values
│ ├── strings.xml
│ └── themes.xml
├── build.gradle.kts
├── gradle.properties
├── gradle
├── libs.versions.toml
├── wrapper.zip
└── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── gradlew
├── gradlew.bat
├── opus
└── .cxx
│ └── Debug
│ └── 60i1sxs5
│ ├── arm64-v8a
│ ├── .cmake
│ │ └── api
│ │ │ └── v1
│ │ │ ├── query
│ │ │ └── client-agp
│ │ │ │ ├── cache-v2
│ │ │ │ ├── cmakeFiles-v1
│ │ │ │ └── codemodel-v2
│ │ │ └── reply
│ │ │ ├── cache-v2-470b76ed65c6bcacf11f.json
│ │ │ ├── cmakeFiles-v1-c473922abf63b24a5243.json
│ │ │ ├── codemodel-v2-b0da4d64702370b86109.json
│ │ │ ├── index-2022-04-07T12-36-37-0072.json
│ │ │ └── target-st_opus-Debug-7803562493eeca685c75.json
│ ├── .ninja_deps
│ ├── .ninja_log
│ ├── CMakeCache.txt
│ ├── CMakeFiles
│ │ ├── 3.18.1-g262b901
│ │ │ ├── CMakeCCompiler.cmake
│ │ │ ├── CMakeCXXCompiler.cmake
│ │ │ ├── CMakeDetermineCompilerABI_C.bin
│ │ │ ├── CMakeDetermineCompilerABI_CXX.bin
│ │ │ └── CMakeSystem.cmake
│ │ ├── TargetDirectories.txt
│ │ ├── cmake.check_cache
│ │ ├── rules.ninja
│ │ └── st_opus.dir
│ │ │ ├── codec
│ │ │ └── CodecOpus.cpp.o
│ │ │ ├── st_opus.cpp.o
│ │ │ └── utils
│ │ │ └── SamplesConverter.cpp.o
│ ├── android_gradle_build.json
│ ├── android_gradle_build_command_st_opus_arm64-v8a.txt
│ ├── android_gradle_build_stderr_st_opus_arm64-v8a.txt
│ ├── android_gradle_build_stdout_st_opus_arm64-v8a.txt
│ ├── build.ninja
│ ├── cmake_install.cmake
│ ├── compile_commands.json
│ ├── compile_commands.json.bin
│ ├── metadata_generation_command.txt
│ └── prefab_config.json
│ ├── armeabi-v7a
│ ├── .cmake
│ │ └── api
│ │ │ └── v1
│ │ │ ├── query
│ │ │ └── client-agp
│ │ │ │ ├── cache-v2
│ │ │ │ ├── cmakeFiles-v1
│ │ │ │ └── codemodel-v2
│ │ │ └── reply
│ │ │ ├── cache-v2-a43ac74063f31375eca7.json
│ │ │ ├── cmakeFiles-v1-65ce27dfcd8d6afc7ff9.json
│ │ │ ├── codemodel-v2-427cf1034632ed3a3c2c.json
│ │ │ ├── index-2022-04-07T13-04-27-0816.json
│ │ │ └── target-st_opus-Debug-e65b20daaace4f2811b2.json
│ ├── .ninja_deps
│ ├── .ninja_log
│ ├── CMakeCache.txt
│ ├── CMakeFiles
│ │ ├── 3.18.1-g262b901
│ │ │ ├── CMakeCCompiler.cmake
│ │ │ ├── CMakeCXXCompiler.cmake
│ │ │ ├── CMakeDetermineCompilerABI_C.bin
│ │ │ ├── CMakeDetermineCompilerABI_CXX.bin
│ │ │ └── CMakeSystem.cmake
│ │ ├── TargetDirectories.txt
│ │ ├── cmake.check_cache
│ │ ├── rules.ninja
│ │ └── st_opus.dir
│ │ │ ├── codec
│ │ │ └── CodecOpus.cpp.o
│ │ │ ├── st_opus.cpp.o
│ │ │ └── utils
│ │ │ └── SamplesConverter.cpp.o
│ ├── android_gradle_build.json
│ ├── android_gradle_build_command_st_opus_armeabi-v7a.txt
│ ├── android_gradle_build_stderr_st_opus_armeabi-v7a.txt
│ ├── android_gradle_build_stdout_st_opus_armeabi-v7a.txt
│ ├── build.ninja
│ ├── cmake_install.cmake
│ ├── compile_commands.json
│ ├── compile_commands.json.bin
│ ├── metadata_generation_command.txt
│ └── prefab_config.json
│ ├── x86
│ ├── .cmake
│ │ └── api
│ │ │ └── v1
│ │ │ ├── query
│ │ │ └── client-agp
│ │ │ │ ├── cache-v2
│ │ │ │ ├── cmakeFiles-v1
│ │ │ │ └── codemodel-v2
│ │ │ └── reply
│ │ │ ├── cache-v2-06ac4101ded16eeddaa8.json
│ │ │ ├── cmakeFiles-v1-250cae608ad21ad265e1.json
│ │ │ ├── codemodel-v2-3edd81916ebf2d9af4b0.json
│ │ │ ├── index-2022-04-07T13-04-28-0793.json
│ │ │ └── target-st_opus-Debug-9e85e9be6f79b707d944.json
│ ├── .ninja_deps
│ ├── .ninja_log
│ ├── CMakeCache.txt
│ ├── CMakeFiles
│ │ ├── 3.18.1-g262b901
│ │ │ ├── CMakeCCompiler.cmake
│ │ │ ├── CMakeCXXCompiler.cmake
│ │ │ ├── CMakeDetermineCompilerABI_C.bin
│ │ │ ├── CMakeDetermineCompilerABI_CXX.bin
│ │ │ └── CMakeSystem.cmake
│ │ ├── TargetDirectories.txt
│ │ ├── cmake.check_cache
│ │ ├── rules.ninja
│ │ └── st_opus.dir
│ │ │ ├── codec
│ │ │ └── CodecOpus.cpp.o
│ │ │ ├── st_opus.cpp.o
│ │ │ └── utils
│ │ │ └── SamplesConverter.cpp.o
│ ├── android_gradle_build.json
│ ├── android_gradle_build_command_st_opus_x86.txt
│ ├── android_gradle_build_stderr_st_opus_x86.txt
│ ├── android_gradle_build_stdout_st_opus_x86.txt
│ ├── build.ninja
│ ├── cmake_install.cmake
│ ├── compile_commands.json
│ ├── compile_commands.json.bin
│ ├── metadata_generation_command.txt
│ └── prefab_config.json
│ └── x86_64
│ ├── .cmake
│ └── api
│ │ └── v1
│ │ ├── query
│ │ └── client-agp
│ │ │ ├── cache-v2
│ │ │ ├── cmakeFiles-v1
│ │ │ └── codemodel-v2
│ │ └── reply
│ │ ├── cache-v2-f57c31c95d694710e420.json
│ │ ├── cmakeFiles-v1-1bc271e0334b4ec9f457.json
│ │ ├── codemodel-v2-00c5fcd4a236ec12b135.json
│ │ ├── index-2022-04-07T13-04-29-0714.json
│ │ └── target-st_opus-Debug-1a73028a134208863219.json
│ ├── .ninja_deps
│ ├── .ninja_log
│ ├── CMakeCache.txt
│ ├── CMakeFiles
│ ├── 3.18.1-g262b901
│ │ ├── CMakeCCompiler.cmake
│ │ ├── CMakeCXXCompiler.cmake
│ │ ├── CMakeDetermineCompilerABI_C.bin
│ │ ├── CMakeDetermineCompilerABI_CXX.bin
│ │ └── CMakeSystem.cmake
│ ├── TargetDirectories.txt
│ ├── cmake.check_cache
│ ├── rules.ninja
│ └── st_opus.dir
│ │ ├── codec
│ │ └── CodecOpus.cpp.o
│ │ ├── st_opus.cpp.o
│ │ └── utils
│ │ └── SamplesConverter.cpp.o
│ ├── android_gradle_build.json
│ ├── android_gradle_build_command_st_opus_x86_64.txt
│ ├── android_gradle_build_stderr_st_opus_x86_64.txt
│ ├── android_gradle_build_stdout_st_opus_x86_64.txt
│ ├── build.ninja
│ ├── cmake_install.cmake
│ ├── compile_commands.json
│ ├── compile_commands.json.bin
│ ├── metadata_generation_command.txt
│ └── prefab_config.json
├── settings.gradle.kts
├── st_blue_sdk
├── .gitignore
├── License.md
├── build.gradle.kts
├── consumer-rules.pro
├── proguard-rules.pro
├── publish.gradle
└── src
│ └── main
│ ├── AndroidManifest.xml
│ ├── java
│ └── com
│ │ └── st
│ │ └── blue_sdk
│ │ ├── BlueManager.kt
│ │ ├── BlueManagerImpl.kt
│ │ ├── LoggableUnit.kt
│ │ ├── NodeService.kt
│ │ ├── board_catalog
│ │ ├── BoardCatalogRepo.kt
│ │ ├── BoardCatalogRepoImpl.kt
│ │ ├── api
│ │ │ ├── BoardCatalogApi.kt
│ │ │ ├── di
│ │ │ │ ├── ApiModule.kt
│ │ │ │ └── Qualifier.kt
│ │ │ └── serializers
│ │ │ │ ├── BoardFotaTypeSerializer.kt
│ │ │ │ ├── BoardStatusTypeSerializer.kt
│ │ │ │ ├── BootLoaderTypeSerializer.kt
│ │ │ │ ├── DateSerializer.kt
│ │ │ │ └── FirmwareMaturityTypeSerializer.kt
│ │ ├── db
│ │ │ ├── BoardCatalogDB.kt
│ │ │ ├── BoardCatalogDao.kt
│ │ │ └── converters
│ │ │ │ ├── BleCharacteristicDataConverter.kt
│ │ │ │ ├── BleCharacteristicFormatDataConverter.kt
│ │ │ │ ├── Board_compatibilityDataConverter.kt
│ │ │ │ ├── CloudAppDataConverter.kt
│ │ │ │ ├── CompatibleSensorAdapterDataConverter.kt
│ │ │ │ ├── ComponentsDataConverter.kt
│ │ │ │ ├── DemoDecoratorDataConverter.kt
│ │ │ │ ├── ExtraExamplesFlowConverter.kt
│ │ │ │ ├── FotaDetailsConverter.kt
│ │ │ │ ├── OptionByteDataConverter.kt
│ │ │ │ ├── PowerModeDataConverter.kt
│ │ │ │ ├── SensorConfigurationConverter.kt
│ │ │ │ └── di
│ │ │ │ └── DbModule.kt
│ │ ├── di
│ │ │ ├── BoardCatalogModule.kt
│ │ │ └── Qualifier.kt
│ │ └── models
│ │ │ ├── BleCharStringValue.kt
│ │ │ ├── BleCharacteristic.kt
│ │ │ ├── BleCharacteristicFormat.kt
│ │ │ ├── BleCharacteristicProperty.kt
│ │ │ ├── BoardCatalog.kt
│ │ │ ├── BoardCatalogStatus.kt
│ │ │ ├── BoardDescription.kt
│ │ │ ├── BoardFirmware.kt
│ │ │ ├── BoardFotaType.kt
│ │ │ ├── BoardStatus.kt
│ │ │ ├── BootLoaderType.kt
│ │ │ ├── CloudApp.kt
│ │ │ ├── CutOff.kt
│ │ │ ├── DemoDecorator.kt
│ │ │ ├── DtmiContent.kt
│ │ │ ├── DtmiModel.kt
│ │ │ ├── ExtraExampleFlow.kt
│ │ │ ├── Field.kt
│ │ │ ├── FilterConfiguration.kt
│ │ │ ├── FirmwareMaturity.kt
│ │ │ ├── FotaDetails.kt
│ │ │ ├── OptionByte.kt
│ │ │ ├── OptionByteEnumType.kt
│ │ │ ├── PowerMode.kt
│ │ │ ├── Sensor.kt
│ │ │ ├── SensorConfiguration.kt
│ │ │ └── SensorType.kt
│ │ ├── bt
│ │ ├── BleBondingBroadcastReceiver.kt
│ │ ├── BleOperationQueue.kt
│ │ ├── advertise
│ │ │ ├── AdvertiseExtension.kt
│ │ │ ├── AdvertiseFilter.kt
│ │ │ ├── AdvertiseParser.kt
│ │ │ ├── BleAdvertiseInfo.kt
│ │ │ ├── BlueNRGAdvertiseFilter.kt
│ │ │ ├── BlueNRGAdvertiseInfo.kt
│ │ │ ├── BlueSTSDKAdvertiseFilter.kt
│ │ │ └── BlueStSdkAdvertiseInfo.kt
│ │ ├── gatt
│ │ │ ├── CallbackGattBridge.kt
│ │ │ ├── FlowGattBridge.kt
│ │ │ └── GattBridge.kt
│ │ ├── hal
│ │ │ ├── BleHal.kt
│ │ │ ├── CallbackBleHAL.kt
│ │ │ └── FlowBleHal.kt
│ │ └── server
│ │ │ ├── NodeEvents.kt
│ │ │ └── NodeServer.kt
│ │ ├── common
│ │ └── Resource.kt
│ │ ├── di
│ │ ├── BlueSdkModule.kt
│ │ └── Qualifiers.kt
│ │ ├── features
│ │ ├── CalibrationStatus.kt
│ │ ├── Feature.kt
│ │ ├── FeatureCommand.kt
│ │ ├── FeatureField.kt
│ │ ├── FeatureResponse.kt
│ │ ├── FeatureUpdate.kt
│ │ ├── GetCalibration.kt
│ │ ├── RawAudio.kt
│ │ ├── RawCommandResponse.kt
│ │ ├── StartCalibration.kt
│ │ ├── StopCalibration.kt
│ │ ├── acceleration
│ │ │ ├── Acceleration.kt
│ │ │ └── AccelerationInfo.kt
│ │ ├── acceleration_event
│ │ │ ├── AccelerationEvent.kt
│ │ │ ├── AccelerationEventInfo.kt
│ │ │ ├── request
│ │ │ │ └── EnableDetectionAccelerationEvent.kt
│ │ │ └── response
│ │ │ │ └── EnableAccelerationEventResponse.kt
│ │ ├── activity
│ │ │ ├── Activity.kt
│ │ │ └── ActivityInfo.kt
│ │ ├── audio
│ │ │ └── adpcm
│ │ │ │ ├── AudioADPCMFeature.kt
│ │ │ │ ├── AudioADPCMSync.kt
│ │ │ │ └── AudioADPCMSyncFeature.kt
│ │ ├── battery
│ │ │ ├── Battery.kt
│ │ │ ├── BatteryInfo.kt
│ │ │ ├── request
│ │ │ │ ├── GetBatteryCapacity.kt
│ │ │ │ └── GetBatteryMaxAbsorbedCurrent.kt
│ │ │ └── response
│ │ │ │ ├── BatteryAbsorbedCurrentResponse.kt
│ │ │ │ └── BatteryCapacityResponse.kt
│ │ ├── beam_forming
│ │ │ ├── BeamForming.kt
│ │ │ ├── BeamFormingInfo.kt
│ │ │ └── request
│ │ │ │ ├── ChangeBeamFormingDirection.kt
│ │ │ │ ├── EnableDisableBeamForming.kt
│ │ │ │ └── UseStrongBeamFormingAlgorithm.kt
│ │ ├── carry_position
│ │ │ ├── CarryPosition.kt
│ │ │ └── CarryPositionInfo.kt
│ │ ├── co_sensor
│ │ │ ├── COSensor.kt
│ │ │ └── COSensorInfo.kt
│ │ ├── compass
│ │ │ ├── Compass.kt
│ │ │ └── CompassInfo.kt
│ │ ├── direction_of_arrival
│ │ │ ├── DirectionOfArrival.kt
│ │ │ ├── DirectionOfArrivalInfo.kt
│ │ │ └── request
│ │ │ │ ├── SetSensitivityHigh.kt
│ │ │ │ └── SetSensitivityLow.kt
│ │ ├── event_counter
│ │ │ ├── EventCounter.kt
│ │ │ └── EventCounterInfo.kt
│ │ ├── exported
│ │ │ ├── ExportedAudioOpusConfFeature.kt
│ │ │ ├── ExportedAudioOpusMusicFeature.kt
│ │ │ ├── ExportedAudioOpusVoiceFeature.kt
│ │ │ └── ExportedFeature.kt
│ │ ├── extended
│ │ │ ├── ai_logging
│ │ │ │ ├── AiLogging.kt
│ │ │ │ ├── AiLoggingInfo.kt
│ │ │ │ └── request
│ │ │ │ │ ├── StartLogging.kt
│ │ │ │ │ ├── StopLogging.kt
│ │ │ │ │ └── UpdateAnnotation.kt
│ │ │ ├── audio
│ │ │ │ └── opus
│ │ │ │ │ ├── AudioOpusConf.kt
│ │ │ │ │ ├── AudioOpusConfFeature.kt
│ │ │ │ │ ├── AudioOpusConst.kt
│ │ │ │ │ └── AudioOpusFeature.kt
│ │ │ ├── audio_classification
│ │ │ │ ├── AudioClassification.kt
│ │ │ │ └── AudioClassificationInfo.kt
│ │ │ ├── binary_content
│ │ │ │ ├── BinaryContent.kt
│ │ │ │ ├── BinaryContentCommand.kt
│ │ │ │ └── RawData.kt
│ │ │ ├── color_ambient_light
│ │ │ │ ├── ColorAmbientLight.kt
│ │ │ │ └── ColorAmbientLightInfo.kt
│ │ │ ├── euler_angle
│ │ │ │ ├── EulerAngle.kt
│ │ │ │ └── EulerAngleInfo.kt
│ │ │ ├── ext_configuration
│ │ │ │ ├── BanksStatus.kt
│ │ │ │ ├── CustomCommand.kt
│ │ │ │ ├── ExtConfigCommandAnswers.kt
│ │ │ │ ├── ExtConfigParser.kt
│ │ │ │ ├── ExtConfiguration.kt
│ │ │ │ ├── ExtendedFeatureResponse.kt
│ │ │ │ ├── FeatureExtConfiguration.kt
│ │ │ │ ├── request
│ │ │ │ │ ├── ExtConfigCommands.kt
│ │ │ │ │ └── ExtendedFeatureCommand.kt
│ │ │ │ └── response
│ │ │ │ │ └── ExtCommandResponse.kt
│ │ │ ├── fitness_activity
│ │ │ │ ├── FitnessActivity.kt
│ │ │ │ ├── FitnessActivityInfo.kt
│ │ │ │ └── request
│ │ │ │ │ └── EnableActivityDetection.kt
│ │ │ ├── gesture_navigation
│ │ │ │ ├── GestureNavigation.kt
│ │ │ │ └── GestureNavigationInfo.kt
│ │ │ ├── gnss
│ │ │ │ ├── GNSS.kt
│ │ │ │ └── GNSSInfo.kt
│ │ │ ├── hs_datalog_config
│ │ │ │ ├── HSDataLogConfig.kt
│ │ │ │ ├── LogConfig.kt
│ │ │ │ ├── model
│ │ │ │ │ ├── Device.kt
│ │ │ │ │ ├── DeviceInfo.kt
│ │ │ │ │ ├── DeviceStatus.kt
│ │ │ │ │ ├── Response.kt
│ │ │ │ │ ├── SamplesPerTs.kt
│ │ │ │ │ ├── Sensor.kt
│ │ │ │ │ ├── SensorCoordinate.kt
│ │ │ │ │ ├── SensorDescriptor.kt
│ │ │ │ │ ├── SensorStatus.kt
│ │ │ │ │ ├── SensorStatusWId.kt
│ │ │ │ │ ├── SubSensorDescriptor.kt
│ │ │ │ │ ├── SubSensorStatus.kt
│ │ │ │ │ ├── Tag.kt
│ │ │ │ │ ├── TagConfig.kt
│ │ │ │ │ └── TagHW.kt
│ │ │ │ └── request
│ │ │ │ │ ├── HSDControlCmd.kt
│ │ │ │ │ └── HSDataLogCommand.kt
│ │ │ ├── ispu_control
│ │ │ │ ├── ISPUControlFeature.kt
│ │ │ │ ├── ISPUControlSendJSONCommand.kt
│ │ │ │ ├── ISPUControlSendUCFCommand.kt
│ │ │ │ └── ISPURawData.kt
│ │ │ ├── json_nfc
│ │ │ │ ├── JsonNFC.kt
│ │ │ │ ├── answer
│ │ │ │ │ ├── JsonNFCResponse.kt
│ │ │ │ │ └── JsonReadModesResult.kt
│ │ │ │ └── request
│ │ │ │ │ ├── JsonCommand.kt
│ │ │ │ │ ├── JsonNFCFeatureWriteCommand.kt
│ │ │ │ │ ├── JsonVCard.kt
│ │ │ │ │ └── JsonWIFI.kt
│ │ │ ├── medical_signal
│ │ │ │ ├── MedicalInfo.kt
│ │ │ │ ├── MedicalSignal16BitFeature.kt
│ │ │ │ ├── MedicalSignal24BitFeature.kt
│ │ │ │ └── MedicalSignalType.kt
│ │ │ ├── motion_algorithm
│ │ │ │ ├── MotionAlgorithm.kt
│ │ │ │ ├── MotionAlgorithmInfo.kt
│ │ │ │ └── request
│ │ │ │ │ └── EnableMotionAlgorithm.kt
│ │ │ ├── motor_time_param
│ │ │ │ ├── MotorTimeParameter.kt
│ │ │ │ └── MotorTimeParameterInfo.kt
│ │ │ ├── navigation_control
│ │ │ │ ├── NavigationControl.kt
│ │ │ │ └── NavigationControlInfo.kt
│ │ │ ├── neai_anomaly_detection
│ │ │ │ ├── NeaiAnomalyDetection.kt
│ │ │ │ ├── NeaiAnomalyDetectionInfo.kt
│ │ │ │ └── request
│ │ │ │ │ ├── WriteDetectionCommand.kt
│ │ │ │ │ ├── WriteLearningCommand.kt
│ │ │ │ │ ├── WriteResetKnowledgeCommand.kt
│ │ │ │ │ └── WriteStopCommand.kt
│ │ │ ├── neai_class_classification
│ │ │ │ ├── NeaiClassClassification.kt
│ │ │ │ ├── NeaiClassClassificationInfo.kt
│ │ │ │ └── request
│ │ │ │ │ ├── WriteStartClassificationCommand.kt
│ │ │ │ │ └── WriteStopClassificationCommand.kt
│ │ │ ├── neai_extrapolation
│ │ │ │ ├── NeaiExtrapolation.kt
│ │ │ │ ├── NeaiExtrapolationInfo.kt
│ │ │ │ ├── model
│ │ │ │ │ └── NeaiExtrapolationData.kt
│ │ │ │ └── request
│ │ │ │ │ ├── WriteStartExtrapolationCommand.kt
│ │ │ │ │ └── WriteStopExtrapolationCommand.kt
│ │ │ ├── piano
│ │ │ │ ├── Piano.kt
│ │ │ │ ├── PianoInfo.kt
│ │ │ │ └── request
│ │ │ │ │ └── CommandPianoSound.kt
│ │ │ ├── pnpl
│ │ │ │ ├── PnPL.kt
│ │ │ │ ├── PnPLConfig.kt
│ │ │ │ ├── model
│ │ │ │ │ ├── PnPLResponse.kt
│ │ │ │ │ └── PnPLSetCommandResponse.kt
│ │ │ │ └── request
│ │ │ │ │ └── PnPLCommand.kt
│ │ │ ├── predictive
│ │ │ │ ├── PredictiveAccelerationStatus.kt
│ │ │ │ ├── PredictiveAccelerationStatusInfo.kt
│ │ │ │ ├── PredictiveFrequencyStatus.kt
│ │ │ │ ├── PredictiveFrequencyStatusInfo.kt
│ │ │ │ ├── PredictiveSpeedStatus.kt
│ │ │ │ ├── PredictiveSpeedStatusInfo.kt
│ │ │ │ └── Status.kt
│ │ │ ├── qvar
│ │ │ │ ├── QVAR.kt
│ │ │ │ └── QVARInfo.kt
│ │ │ ├── raw_controlled
│ │ │ │ ├── RawControlled.kt
│ │ │ │ ├── RawControlledInfo.kt
│ │ │ │ └── model
│ │ │ │ │ ├── RawCustom.kt
│ │ │ │ │ ├── RawCustomEntry.kt
│ │ │ │ │ ├── RawPnPLEntry.kt
│ │ │ │ │ ├── RawPnPLEntryEnumLabel.kt
│ │ │ │ │ ├── RawPnPLEntryFormat.kt
│ │ │ │ │ └── RawStreamIdEntry.kt
│ │ │ ├── registers_feature
│ │ │ │ ├── RegistersFeature.kt
│ │ │ │ └── RegistersFeatureInfo.kt
│ │ │ ├── scene_description
│ │ │ │ ├── SceneDescription.kt
│ │ │ │ └── SceneDescriptionInfo.kt
│ │ │ └── tof_multi_object
│ │ │ │ ├── ToFMultiObject.kt
│ │ │ │ ├── ToFMultiObjectInfo.kt
│ │ │ │ └── request
│ │ │ │ └── CommandPresenceRecognition.kt
│ │ ├── external
│ │ │ ├── std
│ │ │ │ ├── BodySensorLocation.kt
│ │ │ │ ├── BodySensorLocationInfo.kt
│ │ │ │ ├── HeartRate.kt
│ │ │ │ └── HeartRateInfo.kt
│ │ │ └── stm32
│ │ │ │ ├── P2PConfiguration.kt
│ │ │ │ ├── led_and_reboot
│ │ │ │ ├── ControlLedAndReboot.kt
│ │ │ │ ├── ControlLedCommand.kt
│ │ │ │ └── RebootCommand.kt
│ │ │ │ ├── network_status
│ │ │ │ ├── NetworkStatus.kt
│ │ │ │ └── NetworkStatusInfo.kt
│ │ │ │ └── switch_status
│ │ │ │ ├── SwitchInfo.kt
│ │ │ │ └── SwitchStatus.kt
│ │ ├── fft
│ │ │ ├── FFTAmplitudeFeature.kt
│ │ │ └── FFTData.kt
│ │ ├── free_fall
│ │ │ ├── FreeFall.kt
│ │ │ └── FreeFallInfo.kt
│ │ ├── general_purpose
│ │ │ ├── GeneralPurpose.kt
│ │ │ └── GeneralPurposeInfo.kt
│ │ ├── gyroscope
│ │ │ ├── Gyroscope.kt
│ │ │ └── GyroscopeInfo.kt
│ │ ├── humidity
│ │ │ ├── Humidity.kt
│ │ │ └── HumidityInfo.kt
│ │ ├── logging
│ │ │ └── sd
│ │ │ │ ├── SDLoggingFeature.kt
│ │ │ │ ├── SDLoggingInfo.kt
│ │ │ │ └── commands
│ │ │ │ ├── StartLogging.kt
│ │ │ │ └── StopLogging.kt
│ │ ├── luminosity
│ │ │ ├── Luminosity.kt
│ │ │ └── LuminosityInfo.kt
│ │ ├── magnetometer
│ │ │ ├── Magnetometer.kt
│ │ │ └── MagnetometerInfo.kt
│ │ ├── mems_gesture
│ │ │ ├── MemsGesture.kt
│ │ │ └── MemsGestureInfo.kt
│ │ ├── mems_norm
│ │ │ ├── MemsNorm.kt
│ │ │ └── MemsNormInfo.kt
│ │ ├── mic_level
│ │ │ ├── MicLevel.kt
│ │ │ └── MicLevelInfo.kt
│ │ ├── motion_intensity
│ │ │ ├── MotionIntensity.kt
│ │ │ └── MotionIntensityInfo.kt
│ │ ├── ota
│ │ │ ├── ImageFeature.kt
│ │ │ ├── ImageInfo.kt
│ │ │ ├── nrg
│ │ │ │ ├── ExpectedImageTUSeqNumberFeature.kt
│ │ │ │ ├── NewImageFeature.kt
│ │ │ │ ├── NewImageTUContentFeature.kt
│ │ │ │ ├── request
│ │ │ │ │ ├── ImageTUUpload.kt
│ │ │ │ │ └── WriteNewImageParameter.kt
│ │ │ │ └── response
│ │ │ │ │ ├── ExpectedImageSeqNumber.kt
│ │ │ │ │ ├── ImageTUContentInfo.kt
│ │ │ │ │ └── NewImageInfo.kt
│ │ │ └── stm32wb
│ │ │ │ ├── OTAControl.kt
│ │ │ │ ├── OTAFileUpload.kt
│ │ │ │ ├── OTAReboot.kt
│ │ │ │ ├── OTAWillReboot.kt
│ │ │ │ ├── requests
│ │ │ │ ├── CancelUpload.kt
│ │ │ │ ├── FinishUpload.kt
│ │ │ │ ├── RebootToOTAMode.kt
│ │ │ │ ├── StartUpload.kt
│ │ │ │ ├── StopUpload.kt
│ │ │ │ └── UploadOTAData.kt
│ │ │ │ └── response
│ │ │ │ └── WillRebootInfo.kt
│ │ ├── pedometer
│ │ │ ├── Pedometer.kt
│ │ │ └── PedometerInfo.kt
│ │ ├── pressure
│ │ │ ├── Pressure.kt
│ │ │ └── PressureInfo.kt
│ │ ├── proximity
│ │ │ ├── Proximity.kt
│ │ │ └── ProximityInfo.kt
│ │ ├── proximity_gesture
│ │ │ ├── ProximityGesture.kt
│ │ │ └── ProximityGestureInfo.kt
│ │ ├── remote
│ │ │ ├── humidity
│ │ │ │ ├── RemoteHumidity.kt
│ │ │ │ └── RemoteHumidityInfo.kt
│ │ │ ├── pressure
│ │ │ │ ├── RemotePressure.kt
│ │ │ │ └── RemotePressureInfo.kt
│ │ │ ├── switch
│ │ │ │ ├── ChangeRemoteSwitchStatusCommand.kt
│ │ │ │ ├── RemoteFeatureSwitchInfo.kt
│ │ │ │ └── RemoteSwitch.kt
│ │ │ └── temperature
│ │ │ │ ├── RemoteTemperature.kt
│ │ │ │ └── RemoteTemperatureInfo.kt
│ │ ├── sensor_fusion
│ │ │ ├── MemsSensorFusion.kt
│ │ │ ├── MemsSensorFusionCompat.kt
│ │ │ ├── MemsSensorFusionInfo.kt
│ │ │ └── Quaternion.kt
│ │ ├── stepper_motor
│ │ │ ├── StepperMotor.kt
│ │ │ ├── StepperMotorCommand.kt
│ │ │ └── StepperMotorInfo.kt
│ │ ├── switchfeature
│ │ │ ├── SwitchFeature.kt
│ │ │ ├── SwitchFeatureInfo.kt
│ │ │ ├── request
│ │ │ │ ├── SwitchOff.kt
│ │ │ │ └── SwitchOn.kt
│ │ │ └── response
│ │ │ │ └── SwitchOnOffResponse.kt
│ │ └── temperature
│ │ │ ├── Temperature.kt
│ │ │ └── TemperatureInfo.kt
│ │ ├── logger
│ │ ├── CsvFileLogger.kt
│ │ ├── LogCatLogger.kt
│ │ ├── Loggable.kt
│ │ ├── Logger.kt
│ │ └── db_logger
│ │ │ ├── DbLogger.kt
│ │ │ └── db
│ │ │ ├── LoggerDB.kt
│ │ │ ├── LoggerDao.kt
│ │ │ ├── converters
│ │ │ └── DateConverter.kt
│ │ │ ├── di
│ │ │ └── DbModule.kt
│ │ │ └── model
│ │ │ ├── FeatureLog.kt
│ │ │ ├── FeatureLogWithUpdates.kt
│ │ │ └── FeatureUpdateLog.kt
│ │ ├── models
│ │ ├── BleNotification.kt
│ │ ├── Boards.kt
│ │ ├── ChunkProgress.kt
│ │ ├── Field.kt
│ │ ├── JsonMLCFormat.kt
│ │ ├── Node.kt
│ │ ├── NodeState.kt
│ │ ├── OTAMemoryAddress.kt
│ │ ├── OTAMemoryLayout.kt
│ │ ├── Sample.kt
│ │ ├── Sensor.kt
│ │ ├── SensorDescriptor.kt
│ │ ├── SensorStatus.kt
│ │ ├── SubSensorDescriptor.kt
│ │ ├── SubSensorStatus.kt
│ │ └── wesu
│ │ │ ├── Register.kt
│ │ │ └── RegisterCommand.kt
│ │ ├── services
│ │ ├── NodeServerConsumer.kt
│ │ ├── NodeServerProducer.kt
│ │ ├── NodeServerStore.kt
│ │ ├── NodeServiceConsumer.kt
│ │ ├── NodeServiceProducer.kt
│ │ ├── NodeServiceStore.kt
│ │ ├── audio
│ │ │ ├── AudioExtensions.kt
│ │ │ ├── AudioService.kt
│ │ │ ├── AudioServiceImpl.kt
│ │ │ └── codec
│ │ │ │ ├── AudioCodecManager.kt
│ │ │ │ ├── CodecType.kt
│ │ │ │ ├── DecodeParams.kt
│ │ │ │ ├── EncodeParams.kt
│ │ │ │ ├── adpcm
│ │ │ │ ├── ADPCMManager.kt
│ │ │ │ └── ADPCMParams.kt
│ │ │ │ ├── factory
│ │ │ │ ├── AudioCodecManagerProvider.kt
│ │ │ │ └── AudioCodecManagerProviderImpl.kt
│ │ │ │ └── opus
│ │ │ │ ├── OpusManager.kt
│ │ │ │ ├── OpusParams.kt
│ │ │ │ ├── OpusParamsFullBand.kt
│ │ │ │ └── OpusParamsFullDuplex.kt
│ │ ├── calibration
│ │ │ ├── CalibrationService.kt
│ │ │ └── CalibrationServiceImpl.kt
│ │ ├── config
│ │ │ ├── ConfigControlService.kt
│ │ │ └── ConfigControlServiceImpl.kt
│ │ ├── debug
│ │ │ ├── DebugMessage.kt
│ │ │ ├── DebugService.kt
│ │ │ └── DebugServiceImpl.kt
│ │ ├── fw_version
│ │ │ ├── FwVersion.kt
│ │ │ └── FwVersionBoard.kt
│ │ └── ota
│ │ │ ├── FirmwareType.kt
│ │ │ ├── FwConsole.kt
│ │ │ ├── FwFileDescriptor.kt
│ │ │ ├── FwUpdateListener.kt
│ │ │ ├── FwUpgradeParams.kt
│ │ │ ├── ImgFileInputStream.kt
│ │ │ ├── OtaService.kt
│ │ │ ├── OtaServiceImpl.kt
│ │ │ ├── UpgradeStrategy.kt
│ │ │ ├── characteristic
│ │ │ ├── CharacteristicFwUpgrade.kt
│ │ │ └── CharacteristicWithACKFwUpgrade.kt
│ │ │ └── debug
│ │ │ ├── DebugFwUpgrade.kt
│ │ │ ├── DebugFwUpgradeWithResume.kt
│ │ │ ├── FwUpgradeConfiguration.kt
│ │ │ └── STM32Crc32.kt
│ │ └── utils
│ │ ├── BlueVoiceOpusTransportProtocol.kt
│ │ ├── BluetoothExt.kt
│ │ ├── ContextExt.kt
│ │ ├── JsonUtils.kt
│ │ ├── NumberConversion.java
│ │ ├── STL2TransportProtocol.kt
│ │ ├── UnwrapTimestamp.kt
│ │ └── WbOTAUtils.kt
│ └── res
│ └── values
│ └── strings.xml
├── st_opus
├── .gitignore
├── License.md
├── build.gradle.kts
├── consumer-rules.pro
├── proguard-rules.pro
├── publish.gradle
└── src
│ └── main
│ ├── AndroidManifest.xml
│ ├── java
│ └── com
│ │ └── st
│ │ └── BlueSTSDK
│ │ └── Features
│ │ └── Audio
│ │ └── Opus
│ │ └── OpusManager.kt
│ └── jniLibs
│ ├── arm64-v8a
│ └── libopusUser.so
│ ├── armeabi-v7a
│ └── libopusUser.so
│ ├── x86
│ └── libopusUser.so
│ └── x86_64
│ └── libopusUser.so
└── wrapper
├── gradle-wrapper.jar
└── gradle-wrapper.properties
/README.md:
--------------------------------------------------------------------------------
1 | # Android_Module_BlueSTSDK
2 |
3 | Module for creating the BlueST-SDK library
4 |
5 | ## For using it
6 |
7 | Code compiled using gradle 8.11.1
8 |
9 | set on Gradle properties the Github Login name and SSO authentication
10 | Example:
11 |
12 | GPR_USER=PezzoniL
13 | GPR_API_KEY=XXXXXXXXXXXXXXXXXXXXXXXX
14 |
15 | ## Sample app
16 |
17 | This package provides a sample application with some basic functionalities:
18 | - boards discovery and connection
19 | - subscribe to each exported bluetooth SDK features and display the sensors' values in textual way
20 |
21 |
22 | ## st-blue-sdk and st-opus libraries
23 |
24 | This package provides 2 libraries that could be included on the other STMicroelectronics' applications
25 |
26 | For compiling these 2 libraries is necessary to enable all the gradle tasks
27 | So:
28 | 1) Android Studio -> Settings -> Experimental
29 | and uncheck
30 | "Only include test tasks in Gradle task list generated during Gradle Sync"
31 |
32 | 2) Then open the Gradle tab on left and run:
33 | st_blue_sdk/build/assemble
34 | st_blue_sdk/publishing/publishToMavenLocal
35 |
36 | st_opus/build/assemble
37 | st_opus/publishing/publishToMavenLocal
--------------------------------------------------------------------------------
/app/.gitignore:
--------------------------------------------------------------------------------
1 | /build
--------------------------------------------------------------------------------
/app/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # You can control the set of applied configuration files using the
3 | # proguardFiles setting in build.gradle.kts.
4 | #
5 | # For more details, see
6 | # http://developer.android.com/guide/developing/tools/proguard.html
7 |
8 | # If your project uses WebView with JS, uncomment the following
9 | # and specify the fully qualified class name to the JavaScript interface
10 | # class:
11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12 | # public *;
13 | #}
14 |
15 | # Uncomment this to preserve the line number information for
16 | # debugging stack traces.
17 | #-keepattributes SourceFile,LineNumberTable
18 |
19 | # If you keep the line number information, uncomment this to
20 | # hide the original source file name.
21 | #-renamesourcefileattribute SourceFile
--------------------------------------------------------------------------------
/app/src/main/java/com/st/demo/SampleApp.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.demo
9 |
10 | import android.app.Application
11 | import dagger.hilt.android.HiltAndroidApp
12 |
13 | @HiltAndroidApp
14 | class SampleApp : Application()
--------------------------------------------------------------------------------
/app/src/main/java/com/st/demo/ui/theme/Color.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.demo.ui.theme
9 |
10 | import androidx.compose.ui.graphics.Color
11 |
12 | val Scooter = Color(0xFF39a9dc)
13 |
--------------------------------------------------------------------------------
/app/src/main/java/com/st/demo/ui/theme/Type.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.demo.ui.theme
9 |
10 | import androidx.compose.material3.Typography
11 | import androidx.compose.ui.text.TextStyle
12 | import androidx.compose.ui.text.font.FontFamily
13 | import androidx.compose.ui.text.font.FontWeight
14 | import androidx.compose.ui.unit.sp
15 |
16 | val Typography = Typography(
17 | bodyLarge = TextStyle(
18 | fontFamily = FontFamily.Default,
19 | fontWeight = FontWeight.Normal,
20 | fontSize = 16.sp,
21 | lineHeight = 24.sp,
22 | letterSpacing = 0.5.sp
23 | )
24 | )
25 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml:
--------------------------------------------------------------------------------
1 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml:
--------------------------------------------------------------------------------
1 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/app/src/main/res/mipmap-hdpi/ic_launcher.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/app/src/main/res/mipmap-mdpi/ic_launcher.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/app/src/main/res/mipmap-xhdpi/ic_launcher.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp
--------------------------------------------------------------------------------
/app/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
8 |
9 | STBleSDK
10 |
11 | Ble Device List:
12 |
13 | Audio Screen
14 | Test\nAudio
15 |
16 | Updates:
17 | Name: %1$s
18 |
--------------------------------------------------------------------------------
/app/src/main/res/values/themes.xml:
--------------------------------------------------------------------------------
1 |
8 |
9 |
10 |
11 |
12 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/gradle/wrapper.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/gradle/wrapper.zip
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Thu Aug 03 14:09:11 CEST 2023
2 | distributionBase=GRADLE_USER_HOME
3 | distributionPath=wrapper/dists
4 | distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-bin.zip
5 | zipStoreBase=GRADLE_USER_HOME
6 | zipStorePath=wrapper/dists
7 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/.cmake/api/v1/query/client-agp/cache-v2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/arm64-v8a/.cmake/api/v1/query/client-agp/cache-v2
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/.cmake/api/v1/query/client-agp/cmakeFiles-v1:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/arm64-v8a/.cmake/api/v1/query/client-agp/cmakeFiles-v1
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/.cmake/api/v1/query/client-agp/codemodel-v2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/arm64-v8a/.cmake/api/v1/query/client-agp/codemodel-v2
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/.ninja_deps:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/arm64-v8a/.ninja_deps
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/.ninja_log:
--------------------------------------------------------------------------------
1 | # ninja log v5
2 | 1 524 1649334997 CMakeFiles/st_opus.dir/codec/CodecOpus.cpp.o a73e67bb023e72c7
3 | 1 528 1649334997 CMakeFiles/st_opus.dir/utils/SamplesConverter.cpp.o 8e42cf508514f423
4 | 1 580 1649334997 CMakeFiles/st_opus.dir/st_opus.cpp.o 3eed8b72cd69d6d8
5 | 580 698 1649334997 /Users/paolo/workspace/android/STBleSDK/opus/build/intermediates/cxx/Debug/60i1sxs5/obj/arm64-v8a/libst_opus.so 771147a0a321976d
6 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_C.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_C.bin
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_CXX.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_CXX.bin
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/3.18.1-g262b901/CMakeSystem.cmake:
--------------------------------------------------------------------------------
1 | set(CMAKE_HOST_SYSTEM "Darwin-21.4.0")
2 | set(CMAKE_HOST_SYSTEM_NAME "Darwin")
3 | set(CMAKE_HOST_SYSTEM_VERSION "21.4.0")
4 | set(CMAKE_HOST_SYSTEM_PROCESSOR "x86_64")
5 |
6 | include("/Users/paolo/Library/Android/sdk/ndk/21.4.7075529/build/cmake/android.toolchain.cmake")
7 |
8 | set(CMAKE_SYSTEM "Android-1")
9 | set(CMAKE_SYSTEM_NAME "Android")
10 | set(CMAKE_SYSTEM_VERSION "1")
11 | set(CMAKE_SYSTEM_PROCESSOR "aarch64")
12 |
13 | set(CMAKE_CROSSCOMPILING "TRUE")
14 |
15 | set(CMAKE_SYSTEM_LOADED 1)
16 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/TargetDirectories.txt:
--------------------------------------------------------------------------------
1 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/rebuild_cache.dir
2 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/edit_cache.dir
3 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/st_opus.dir
4 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/cmake.check_cache:
--------------------------------------------------------------------------------
1 | # This file is generated by cmake for dependency checking of the CMakeCache.txt file
2 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/st_opus.dir/codec/CodecOpus.cpp.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/st_opus.dir/codec/CodecOpus.cpp.o
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/st_opus.dir/st_opus.cpp.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/st_opus.dir/st_opus.cpp.o
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/st_opus.dir/utils/SamplesConverter.cpp.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/arm64-v8a/CMakeFiles/st_opus.dir/utils/SamplesConverter.cpp.o
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/android_gradle_build_command_st_opus_arm64-v8a.txt:
--------------------------------------------------------------------------------
1 | Executable : /Users/paolo/Library/Android/sdk/cmake/3.18.1/bin/ninja
2 | arguments :
3 | -C
4 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/arm64-v8a
5 | st_opus
6 | jvmArgs :
7 |
8 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/android_gradle_build_stderr_st_opus_arm64-v8a.txt:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/arm64-v8a/android_gradle_build_stderr_st_opus_arm64-v8a.txt
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/android_gradle_build_stdout_st_opus_arm64-v8a.txt:
--------------------------------------------------------------------------------
1 | ninja: Entering directory `/Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/arm64-v8a'
2 | ninja: no work to do.
3 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/arm64-v8a/prefab_config.json:
--------------------------------------------------------------------------------
1 | {
2 | "enabled": false,
3 | "packages": []
4 | }
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/.cmake/api/v1/query/client-agp/cache-v2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/.cmake/api/v1/query/client-agp/cache-v2
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/.cmake/api/v1/query/client-agp/cmakeFiles-v1:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/.cmake/api/v1/query/client-agp/cmakeFiles-v1
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/.cmake/api/v1/query/client-agp/codemodel-v2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/.cmake/api/v1/query/client-agp/codemodel-v2
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/.ninja_deps:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/.ninja_deps
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/.ninja_log:
--------------------------------------------------------------------------------
1 | # ninja log v5
2 | 0 374 1649336668 CMakeFiles/st_opus.dir/codec/CodecOpus.cpp.o 19879bf79cbd1895
3 | 0 383 1649336668 CMakeFiles/st_opus.dir/utils/SamplesConverter.cpp.o bfa5002d316ac612
4 | 1 429 1649336668 CMakeFiles/st_opus.dir/st_opus.cpp.o ad75c4d8ce87c589
5 | 429 510 1649336668 /Users/paolo/workspace/android/STBleSDK/opus/build/intermediates/cxx/Debug/60i1sxs5/obj/armeabi-v7a/libst_opus.so 8cd6db6fcee5e7d3
6 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_C.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_C.bin
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_CXX.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_CXX.bin
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/3.18.1-g262b901/CMakeSystem.cmake:
--------------------------------------------------------------------------------
1 | set(CMAKE_HOST_SYSTEM "Darwin-21.4.0")
2 | set(CMAKE_HOST_SYSTEM_NAME "Darwin")
3 | set(CMAKE_HOST_SYSTEM_VERSION "21.4.0")
4 | set(CMAKE_HOST_SYSTEM_PROCESSOR "x86_64")
5 |
6 | include("/Users/paolo/Library/Android/sdk/ndk/21.4.7075529/build/cmake/android.toolchain.cmake")
7 |
8 | set(CMAKE_SYSTEM "Android-1")
9 | set(CMAKE_SYSTEM_NAME "Android")
10 | set(CMAKE_SYSTEM_VERSION "1")
11 | set(CMAKE_SYSTEM_PROCESSOR "armv7-a")
12 |
13 | set(CMAKE_CROSSCOMPILING "TRUE")
14 |
15 | set(CMAKE_SYSTEM_LOADED 1)
16 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/TargetDirectories.txt:
--------------------------------------------------------------------------------
1 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/rebuild_cache.dir
2 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/edit_cache.dir
3 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/st_opus.dir
4 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/cmake.check_cache:
--------------------------------------------------------------------------------
1 | # This file is generated by cmake for dependency checking of the CMakeCache.txt file
2 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/st_opus.dir/codec/CodecOpus.cpp.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/st_opus.dir/codec/CodecOpus.cpp.o
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/st_opus.dir/st_opus.cpp.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/st_opus.dir/st_opus.cpp.o
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/st_opus.dir/utils/SamplesConverter.cpp.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/CMakeFiles/st_opus.dir/utils/SamplesConverter.cpp.o
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/android_gradle_build_command_st_opus_armeabi-v7a.txt:
--------------------------------------------------------------------------------
1 | Executable : /Users/paolo/Library/Android/sdk/cmake/3.18.1/bin/ninja
2 | arguments :
3 | -C
4 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/armeabi-v7a
5 | st_opus
6 | jvmArgs :
7 |
8 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/android_gradle_build_stderr_st_opus_armeabi-v7a.txt:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/android_gradle_build_stderr_st_opus_armeabi-v7a.txt
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/android_gradle_build_stdout_st_opus_armeabi-v7a.txt:
--------------------------------------------------------------------------------
1 | ninja: Entering directory `/Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/armeabi-v7a'
2 | ninja: no work to do.
3 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/armeabi-v7a/prefab_config.json:
--------------------------------------------------------------------------------
1 | {
2 | "enabled": false,
3 | "packages": []
4 | }
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/.cmake/api/v1/query/client-agp/cache-v2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86/.cmake/api/v1/query/client-agp/cache-v2
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/.cmake/api/v1/query/client-agp/cmakeFiles-v1:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86/.cmake/api/v1/query/client-agp/cmakeFiles-v1
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/.cmake/api/v1/query/client-agp/codemodel-v2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86/.cmake/api/v1/query/client-agp/codemodel-v2
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/.ninja_deps:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86/.ninja_deps
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/.ninja_log:
--------------------------------------------------------------------------------
1 | # ninja log v5
2 | 0 350 1649336669 CMakeFiles/st_opus.dir/codec/CodecOpus.cpp.o e69e78ab9903d9f9
3 | 0 356 1649336669 CMakeFiles/st_opus.dir/utils/SamplesConverter.cpp.o a5a0ebf42af33a6d
4 | 0 399 1649336669 CMakeFiles/st_opus.dir/st_opus.cpp.o ee1168e2f76ee59a
5 | 399 462 1649336669 /Users/paolo/workspace/android/STBleSDK/opus/build/intermediates/cxx/Debug/60i1sxs5/obj/x86/libst_opus.so 292744363370c799
6 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_C.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_C.bin
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_CXX.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_CXX.bin
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/3.18.1-g262b901/CMakeSystem.cmake:
--------------------------------------------------------------------------------
1 | set(CMAKE_HOST_SYSTEM "Darwin-21.4.0")
2 | set(CMAKE_HOST_SYSTEM_NAME "Darwin")
3 | set(CMAKE_HOST_SYSTEM_VERSION "21.4.0")
4 | set(CMAKE_HOST_SYSTEM_PROCESSOR "x86_64")
5 |
6 | include("/Users/paolo/Library/Android/sdk/ndk/21.4.7075529/build/cmake/android.toolchain.cmake")
7 |
8 | set(CMAKE_SYSTEM "Android-1")
9 | set(CMAKE_SYSTEM_NAME "Android")
10 | set(CMAKE_SYSTEM_VERSION "1")
11 | set(CMAKE_SYSTEM_PROCESSOR "i686")
12 |
13 | set(CMAKE_CROSSCOMPILING "TRUE")
14 |
15 | set(CMAKE_SYSTEM_LOADED 1)
16 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/TargetDirectories.txt:
--------------------------------------------------------------------------------
1 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/rebuild_cache.dir
2 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/edit_cache.dir
3 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/st_opus.dir
4 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/cmake.check_cache:
--------------------------------------------------------------------------------
1 | # This file is generated by cmake for dependency checking of the CMakeCache.txt file
2 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/st_opus.dir/codec/CodecOpus.cpp.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/st_opus.dir/codec/CodecOpus.cpp.o
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/st_opus.dir/st_opus.cpp.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/st_opus.dir/st_opus.cpp.o
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/st_opus.dir/utils/SamplesConverter.cpp.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86/CMakeFiles/st_opus.dir/utils/SamplesConverter.cpp.o
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/android_gradle_build_command_st_opus_x86.txt:
--------------------------------------------------------------------------------
1 | Executable : /Users/paolo/Library/Android/sdk/cmake/3.18.1/bin/ninja
2 | arguments :
3 | -C
4 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/x86
5 | st_opus
6 | jvmArgs :
7 |
8 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/android_gradle_build_stderr_st_opus_x86.txt:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86/android_gradle_build_stderr_st_opus_x86.txt
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/android_gradle_build_stdout_st_opus_x86.txt:
--------------------------------------------------------------------------------
1 | ninja: Entering directory `/Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/x86'
2 | ninja: no work to do.
3 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86/prefab_config.json:
--------------------------------------------------------------------------------
1 | {
2 | "enabled": false,
3 | "packages": []
4 | }
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/.cmake/api/v1/query/client-agp/cache-v2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86_64/.cmake/api/v1/query/client-agp/cache-v2
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/.cmake/api/v1/query/client-agp/cmakeFiles-v1:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86_64/.cmake/api/v1/query/client-agp/cmakeFiles-v1
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/.cmake/api/v1/query/client-agp/codemodel-v2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86_64/.cmake/api/v1/query/client-agp/codemodel-v2
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/.ninja_deps:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86_64/.ninja_deps
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/.ninja_log:
--------------------------------------------------------------------------------
1 | # ninja log v5
2 | 1 323 1649336670 CMakeFiles/st_opus.dir/codec/CodecOpus.cpp.o 36ed81286271a125
3 | 1 333 1649336670 CMakeFiles/st_opus.dir/utils/SamplesConverter.cpp.o e097e97620f6a8f0
4 | 1 381 1649336670 CMakeFiles/st_opus.dir/st_opus.cpp.o be71506c1049127a
5 | 382 466 1649336670 /Users/paolo/workspace/android/STBleSDK/opus/build/intermediates/cxx/Debug/60i1sxs5/obj/x86_64/libst_opus.so 815f9f9b1dce3cef
6 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_C.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_C.bin
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_CXX.bin:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/3.18.1-g262b901/CMakeDetermineCompilerABI_CXX.bin
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/3.18.1-g262b901/CMakeSystem.cmake:
--------------------------------------------------------------------------------
1 | set(CMAKE_HOST_SYSTEM "Darwin-21.4.0")
2 | set(CMAKE_HOST_SYSTEM_NAME "Darwin")
3 | set(CMAKE_HOST_SYSTEM_VERSION "21.4.0")
4 | set(CMAKE_HOST_SYSTEM_PROCESSOR "x86_64")
5 |
6 | include("/Users/paolo/Library/Android/sdk/ndk/21.4.7075529/build/cmake/android.toolchain.cmake")
7 |
8 | set(CMAKE_SYSTEM "Android-1")
9 | set(CMAKE_SYSTEM_NAME "Android")
10 | set(CMAKE_SYSTEM_VERSION "1")
11 | set(CMAKE_SYSTEM_PROCESSOR "x86_64")
12 |
13 | set(CMAKE_CROSSCOMPILING "TRUE")
14 |
15 | set(CMAKE_SYSTEM_LOADED 1)
16 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/TargetDirectories.txt:
--------------------------------------------------------------------------------
1 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/rebuild_cache.dir
2 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/edit_cache.dir
3 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/st_opus.dir
4 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/cmake.check_cache:
--------------------------------------------------------------------------------
1 | # This file is generated by cmake for dependency checking of the CMakeCache.txt file
2 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/st_opus.dir/codec/CodecOpus.cpp.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/st_opus.dir/codec/CodecOpus.cpp.o
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/st_opus.dir/st_opus.cpp.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/st_opus.dir/st_opus.cpp.o
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/st_opus.dir/utils/SamplesConverter.cpp.o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86_64/CMakeFiles/st_opus.dir/utils/SamplesConverter.cpp.o
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/android_gradle_build_command_st_opus_x86_64.txt:
--------------------------------------------------------------------------------
1 | Executable : /Users/paolo/Library/Android/sdk/cmake/3.18.1/bin/ninja
2 | arguments :
3 | -C
4 | /Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/x86_64
5 | st_opus
6 | jvmArgs :
7 |
8 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/android_gradle_build_stderr_st_opus_x86_64.txt:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/opus/.cxx/Debug/60i1sxs5/x86_64/android_gradle_build_stderr_st_opus_x86_64.txt
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/android_gradle_build_stdout_st_opus_x86_64.txt:
--------------------------------------------------------------------------------
1 | ninja: Entering directory `/Users/paolo/workspace/android/STBleSDK/opus/.cxx/Debug/60i1sxs5/x86_64'
2 | ninja: no work to do.
3 |
--------------------------------------------------------------------------------
/opus/.cxx/Debug/60i1sxs5/x86_64/prefab_config.json:
--------------------------------------------------------------------------------
1 | {
2 | "enabled": false,
3 | "packages": []
4 | }
--------------------------------------------------------------------------------
/st_blue_sdk/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 | schemas
3 |
--------------------------------------------------------------------------------
/st_blue_sdk/consumer-rules.pro:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/st_blue_sdk/consumer-rules.pro
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/LoggableUnit.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk
9 |
10 | import com.st.blue_sdk.logger.Loggable
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | class LoggableUnit : Loggable {
15 | override val logHeader: String = ""
16 |
17 | override val logValue: String = ""
18 |
19 | override fun toString(): String = "No Data"
20 |
21 | override val logDoubleValues: List = listOf()
22 | }
23 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/api/BoardCatalogApi.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.board_catalog.api
9 |
10 | import com.st.blue_sdk.board_catalog.models.BoardCatalog
11 | import kotlinx.serialization.json.JsonObject
12 | import retrofit2.http.GET
13 | import retrofit2.http.Url
14 |
15 | interface BoardCatalogApi {
16 |
17 | //For Production Catalog
18 | @GET("catalog.json")
19 | suspend fun getFirmwares(): BoardCatalog
20 |
21 | @GET("chksum.json")
22 | suspend fun getDBVersion(): BoardCatalog
23 |
24 | //For Pre-Production Catalog
25 | @GET
26 | suspend fun getFirmwaresFromUrl(@Url url: String): BoardCatalog
27 |
28 | @GET
29 | suspend fun getDBVersionFromUrl(@Url url: String): BoardCatalog
30 |
31 | @GET
32 | suspend fun getDtmiModel(@Url url: String): List
33 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/api/di/Qualifier.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.board_catalog.api.di
9 |
10 | import javax.inject.Qualifier
11 |
12 | @Qualifier
13 | @Retention(AnnotationRetention.BINARY)
14 | annotation class RetrofitBasePath
15 |
16 | @Qualifier
17 | @Retention(AnnotationRetention.BINARY)
18 | annotation class StAppVersion
19 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/api/serializers/BoardStatusTypeSerializer.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.api.serializers
2 |
3 | import com.st.blue_sdk.board_catalog.models.BoardStatus
4 | import kotlinx.serialization.KSerializer
5 | import kotlinx.serialization.descriptors.PrimitiveKind
6 | import kotlinx.serialization.descriptors.PrimitiveSerialDescriptor
7 | import kotlinx.serialization.descriptors.SerialDescriptor
8 | import kotlinx.serialization.encoding.Decoder
9 | import kotlinx.serialization.encoding.Encoder
10 |
11 | class BoardStatusTypeSerializer : KSerializer {
12 |
13 | override val descriptor: SerialDescriptor =
14 | PrimitiveSerialDescriptor("BoardStatus", PrimitiveKind.STRING)
15 |
16 | override fun deserialize(decoder: Decoder): BoardStatus =
17 | BoardStatus.valueOf(decoder.decodeString().uppercase())
18 |
19 | override fun serialize(encoder: Encoder, value: BoardStatus) {
20 | val encoded = value.name.lowercase()
21 | encoder.encodeString(encoded)
22 | }
23 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/api/serializers/BootLoaderTypeSerializer.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.api.serializers
2 |
3 | import com.st.blue_sdk.board_catalog.models.BootLoaderType
4 | import kotlinx.serialization.KSerializer
5 | import kotlinx.serialization.descriptors.PrimitiveKind
6 | import kotlinx.serialization.descriptors.PrimitiveSerialDescriptor
7 | import kotlinx.serialization.descriptors.SerialDescriptor
8 | import kotlinx.serialization.encoding.Decoder
9 | import kotlinx.serialization.encoding.Encoder
10 |
11 | class BootLoaderTypeSerializer : KSerializer {
12 |
13 | override val descriptor: SerialDescriptor =
14 | PrimitiveSerialDescriptor("BootLoaderType", PrimitiveKind.STRING)
15 |
16 | override fun deserialize(decoder: Decoder): BootLoaderType =
17 | BootLoaderType.valueOf(decoder.decodeString().uppercase())
18 |
19 | override fun serialize(encoder: Encoder, value: BootLoaderType) {
20 | val encoded = value.name.lowercase()
21 | encoder.encodeString(encoded)
22 | }
23 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/api/serializers/FirmwareMaturityTypeSerializer.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.api.serializers
2 |
3 | import com.st.blue_sdk.board_catalog.models.FirmwareMaturity
4 | import kotlinx.serialization.KSerializer
5 | import kotlinx.serialization.descriptors.PrimitiveKind
6 | import kotlinx.serialization.descriptors.PrimitiveSerialDescriptor
7 | import kotlinx.serialization.descriptors.SerialDescriptor
8 | import kotlinx.serialization.encoding.Decoder
9 | import kotlinx.serialization.encoding.Encoder
10 |
11 | class FirmwareMaturityTypeSerializer : KSerializer {
12 |
13 | override val descriptor: SerialDescriptor =
14 | PrimitiveSerialDescriptor("FirmwareMaturityType", PrimitiveKind.STRING)
15 |
16 | override fun deserialize(decoder: Decoder): FirmwareMaturity =
17 | FirmwareMaturity.valueOf(decoder.decodeString().uppercase())
18 |
19 | override fun serialize(encoder: Encoder, value: FirmwareMaturity) {
20 | val encoded = value.name.lowercase()
21 | encoder.encodeString(encoded)
22 | }
23 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/db/converters/BleCharacteristicDataConverter.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.board_catalog.db.converters
9 |
10 | import androidx.room.TypeConverter
11 | import com.st.blue_sdk.board_catalog.models.BleCharacteristic
12 | import kotlinx.serialization.decodeFromString
13 | import kotlinx.serialization.encodeToString
14 | import kotlinx.serialization.json.Json
15 |
16 | class BleCharacteristicDataConverter {
17 | @TypeConverter
18 | fun fromBleCharacteristic(value: List): String {
19 | if (value.isEmpty()) return ""
20 | return Json.encodeToString(value)
21 | }
22 |
23 | @TypeConverter
24 | fun toBleCharacteristic(value: String): List {
25 | if (value.isEmpty()) return emptyList()
26 | return Json.decodeFromString(value)
27 | }
28 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/db/converters/BleCharacteristicFormatDataConverter.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.db.converters
2 |
3 | import androidx.room.TypeConverter
4 | import com.st.blue_sdk.board_catalog.models.BleCharacteristicFormat
5 | import kotlinx.serialization.encodeToString
6 | import kotlinx.serialization.json.Json
7 |
8 | class BleCharacteristicFormatDataConverter {
9 | @TypeConverter
10 | fun fromBleCharacteristicFormat(value: List): String {
11 | if (value.isEmpty()) return ""
12 | return Json.encodeToString(value)
13 | }
14 |
15 | @TypeConverter
16 | fun toBleCharacteristicFormat(value: String): List {
17 | if (value.isEmpty()) return emptyList()
18 | return Json.decodeFromString(value)
19 | }
20 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/db/converters/Board_compatibilityDataConverter.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.db.converters
2 |
3 | import androidx.room.TypeConverter
4 | import kotlinx.serialization.encodeToString
5 | import kotlinx.serialization.json.Json
6 |
7 | class Board_compatibilityDataConverter {
8 | @TypeConverter
9 | fun fromBoard_compatibility(value: ArrayList) : String {
10 | return if(value.isNotEmpty()) {
11 | Json.encodeToString(value)
12 | } else {
13 | ""
14 | }
15 | }
16 | @TypeConverter
17 | fun toBoard_compatibility(value: String) : ArrayList {
18 | if (value.isEmpty()) return ArrayList()
19 | return Json.decodeFromString(value)
20 | }
21 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/db/converters/CloudAppDataConverter.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.board_catalog.db.converters
9 |
10 | import androidx.room.TypeConverter
11 | import com.st.blue_sdk.board_catalog.models.CloudApp
12 | import kotlinx.serialization.decodeFromString
13 | import kotlinx.serialization.encodeToString
14 | import kotlinx.serialization.json.Json
15 |
16 | class CloudAppDataConverter {
17 | @TypeConverter
18 | fun fromCloudApp(value: List): String {
19 | if (value.isEmpty()) return ""
20 | return Json.encodeToString(value)
21 | }
22 |
23 | @TypeConverter
24 | fun toCloudApp(value: String): List {
25 | if (value.isEmpty()) return emptyList()
26 | return Json.decodeFromString(value)
27 | }
28 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/db/converters/CompatibleSensorAdapterDataConverter.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.db.converters
2 |
3 | import androidx.room.TypeConverter
4 | import kotlinx.serialization.decodeFromString
5 | import kotlinx.serialization.encodeToString
6 | import kotlinx.serialization.json.Json
7 |
8 | class CompatibleSensorAdapterDataConverter {
9 | @TypeConverter
10 | fun fromCompatibleSensorAdapter(value: List?) : String {
11 | return if(value!=null) {
12 | Json.encodeToString(value)
13 | } else {
14 | ""
15 | }
16 | }
17 | @TypeConverter
18 | fun toCompatibleSensorAdapter(value: String) : List? {
19 | if (value.isEmpty()) return null
20 | return Json.decodeFromString(value)
21 | }
22 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/db/converters/ComponentsDataConverter.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.db.converters
2 |
3 | import androidx.room.TypeConverter
4 | import kotlinx.serialization.decodeFromString
5 | import kotlinx.serialization.encodeToString
6 | import kotlinx.serialization.json.Json
7 |
8 | class ComponentsDataConverter {
9 | @TypeConverter
10 | fun fromComponents(value: List?) : String {
11 | return if(value!=null) {
12 | Json.encodeToString(value)
13 | } else {
14 | ""
15 | }
16 | }
17 | @TypeConverter
18 | fun toComponents(value: String) : List? {
19 | if (value.isEmpty()) return null
20 | return Json.decodeFromString(value)
21 | }
22 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/db/converters/DemoDecoratorDataConverter.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.db.converters
2 |
3 | import androidx.room.TypeConverter
4 | import com.st.blue_sdk.board_catalog.models.DemoDecorator
5 | import kotlinx.serialization.decodeFromString
6 | import kotlinx.serialization.encodeToString
7 | import kotlinx.serialization.json.Json
8 |
9 | class DemoDecoratorDataConverter {
10 | @TypeConverter
11 | fun fromDemoDecorator(value: DemoDecorator): String {
12 | return Json.encodeToString(value)
13 | }
14 |
15 | @TypeConverter
16 | fun toDemoDecorator(value: String): DemoDecorator {
17 | return Json.decodeFromString(value)
18 | }
19 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/db/converters/ExtraExamplesFlowConverter.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.db.converters
2 |
3 | import androidx.room.TypeConverter
4 | import com.st.blue_sdk.board_catalog.models.ExtraExamplesFlow
5 | import kotlinx.serialization.json.Json
6 |
7 |
8 |
9 | class ExtraExamplesFlowConverter {
10 | @TypeConverter
11 | fun fromExtraExamplesFlow(value: List?): String {
12 | return if(value!=null) {
13 | Json.encodeToString(value)
14 | } else {
15 | ""
16 | }
17 | }
18 |
19 | @TypeConverter
20 | fun toExtraExamplesFlow(value: String): List? {
21 | if (value.isEmpty()) return null
22 | return Json.decodeFromString(value)
23 | }
24 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/db/converters/FotaDetailsConverter.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.db.converters
2 |
3 | import androidx.room.TypeConverter
4 | import com.st.blue_sdk.board_catalog.models.FotaDetails
5 | import kotlinx.serialization.decodeFromString
6 | import kotlinx.serialization.encodeToString
7 | import kotlinx.serialization.json.Json
8 |
9 | class FotaDetailsConverter {
10 | @TypeConverter
11 | fun fromFotaDetails(value: FotaDetails): String {
12 | return Json.encodeToString(value)
13 | }
14 |
15 | @TypeConverter
16 | fun toFotaDetails(value: String): FotaDetails {
17 | return Json.decodeFromString(value)
18 | }
19 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/db/converters/OptionByteDataConverter.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.board_catalog.db.converters
9 |
10 | import androidx.room.TypeConverter
11 | import com.st.blue_sdk.board_catalog.models.OptionByte
12 | import kotlinx.serialization.decodeFromString
13 | import kotlinx.serialization.encodeToString
14 | import kotlinx.serialization.json.Json
15 |
16 | class OptionByteDataConverter {
17 | @TypeConverter
18 | fun fromOptionByte(value: List): String {
19 | if (value.isEmpty()) return ""
20 | return Json.encodeToString(value)
21 | }
22 |
23 | @TypeConverter
24 | fun toOptionByte(value: String): List {
25 | if (value.isEmpty()) return emptyList()
26 | return Json.decodeFromString(value)
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/db/converters/PowerModeDataConverter.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.db.converters
2 |
3 | import androidx.room.TypeConverter
4 | import com.st.blue_sdk.board_catalog.models.PowerMode
5 | import kotlinx.serialization.json.Json
6 |
7 | class PowerModeDataConverter {
8 | @TypeConverter
9 | fun fromCompatibleSensorAdapter(value: List?) : String {
10 | return if(value!=null) {
11 | Json.encodeToString(value)
12 | } else {
13 | ""
14 | }
15 | }
16 | @TypeConverter
17 | fun toCompatibleSensorAdapter(value: String) : List? {
18 | if (value.isEmpty()) return null
19 | return Json.decodeFromString(value)
20 | }
21 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/db/converters/SensorConfigurationConverter.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.db.converters
2 |
3 | import androidx.room.TypeConverter
4 | import com.st.blue_sdk.board_catalog.models.SensorConfiguration
5 | import kotlinx.serialization.encodeToString
6 | import kotlinx.serialization.json.Json
7 |
8 | class SensorConfigurationConverter {
9 | @TypeConverter
10 | fun fromSensorConfiguration(value: SensorConfiguration?) : String {
11 | return if(value!=null) {
12 | Json.encodeToString(value)
13 | } else {
14 | ""
15 | }
16 | }
17 | @TypeConverter
18 | fun toSensorConfiguration(value: String) : SensorConfiguration? {
19 | if (value.isEmpty()) return null
20 | return Json.decodeFromString(value)
21 | }
22 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/di/Qualifier.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.board_catalog.di
9 |
10 | import javax.inject.Qualifier
11 |
12 | @Qualifier
13 | @Retention(AnnotationRetention.BINARY)
14 | annotation class Preferences
15 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/BleCharStringValue.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.board_catalog.models
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class BleCharStringValue(
15 | @SerialName(value = "display_name")
16 | val displayName: String,
17 | @SerialName(value = "value")
18 | val value: Int
19 | )
20 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/BleCharacteristicProperty.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.board_catalog.models
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class BleCharacteristicProperty(
15 | @SerialName(value = "length")
16 | val length: Int,
17 | @SerialName(value = "format")
18 | val format: List
19 | )
20 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/BoardCatalogStatus.kt:
--------------------------------------------------------------------------------
1 | @file:UseSerializers(DateSerializer::class)
2 | package com.st.blue_sdk.board_catalog.models
3 |
4 |
5 | import com.st.blue_sdk.board_catalog.api.serializers.DateSerializer
6 | import kotlinx.serialization.SerialName
7 | import kotlinx.serialization.Serializable
8 | import kotlinx.serialization.UseSerializers
9 | import java.util.Date
10 |
11 | @Serializable
12 | data class BoardCatalogStatus(
13 | @SerialName(value = "deprecationDate")
14 | val deprecationDate: Date?=null,
15 | @SerialName(value = "dismissionDate")
16 | val dismissionDate: Date?=null,
17 | )
18 |
19 | fun BoardCatalogStatus.isDeprecated(): Boolean {
20 | val currentDate = Date()
21 | return currentDate.after(deprecationDate)
22 | }
23 |
24 | fun BoardCatalogStatus.isDismissed(): Boolean {
25 | val currentDate = Date()
26 | return currentDate.after(dismissionDate)
27 | }
28 |
29 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/BoardFotaType.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.board_catalog.models
9 |
10 | enum class BoardFotaType {
11 | NO,
12 | YES,
13 | FAST,
14 | WB_MODE,
15 | WB_READY
16 | }
17 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/BoardStatus.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.models
2 |
3 | enum class BoardStatus {
4 | NRND,
5 | ACTIVE
6 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/BootLoaderType.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.models
2 |
3 | enum class BootLoaderType {
4 | NONE,
5 | CUSTOM,
6 | WB,
7 | SBSFU
8 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/CloudApp.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.board_catalog.models
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class CloudApp(
15 | @SerialName(value = "dtmi")
16 | val dtmi: String? = null,
17 | @SerialName(value = "name")
18 | var name: String? = null,
19 | @SerialName(value = "shareable_link")
20 | var shareableLink: String? = null,
21 | @SerialName(value = "url")
22 | var url: String? = null,
23 | @SerialName(value = "dtmi_type")
24 | var dtmiType: String? = null,
25 | @SerialName(value = "description")
26 | val description: String? = null
27 | )
28 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/CutOff.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.models
2 |
3 | import kotlinx.serialization.SerialName
4 | import kotlinx.serialization.Serializable
5 |
6 | @Serializable
7 | data class CutOff(
8 | @SerialName(value = "label")
9 | var label: String,
10 | @SerialName(value = "value")
11 | var value: Int
12 | ) {
13 | override fun toString(): String {
14 | return "Cutoff{" +
15 | "label='" + label + '\'' +
16 | ", value=" + value +
17 | '}'
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/DemoDecorator.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.models
2 |
3 | import kotlinx.serialization.SerialName
4 | import kotlinx.serialization.Serializable
5 |
6 | @Serializable
7 | data class DemoDecorator(
8 | @SerialName(value = "add")
9 | val add: List,
10 | @SerialName(value = "remove")
11 | val remove: List,
12 | @SerialName(value = "rename")
13 | val rename: List
14 | )
15 |
16 | @Serializable
17 | data class DemoRename(
18 | @SerialName(value = "old")
19 | val old: String,
20 | @SerialName(value = "new")
21 | val new: String
22 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/ExtraExampleFlow.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.models
2 |
3 | import androidx.room.ColumnInfo
4 | import kotlinx.serialization.SerialName
5 | import kotlinx.serialization.Serializable
6 |
7 |
8 | @Serializable
9 | data class ExtraExamplesFlow(
10 | @ColumnInfo(name = "model")
11 | @SerialName(value = "model")
12 | val model: String?=null,
13 | @ColumnInfo(name = "examples_flow")
14 | @SerialName(value = "examples_flow")
15 | val examplesFlow: List = listOf()
16 | )
17 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/Field.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.board_catalog.models;
9 |
10 | data class Field(
11 | val unit: String,
12 | val name: String,
13 | val type: Type,
14 | val max: Number,
15 | val min: Number,
16 | val toPlot: Boolean = true
17 | ) {
18 | enum class Type {
19 | Float,
20 | Int64,
21 | UInt32,
22 | Int32,
23 | UInt16,
24 | Int16,
25 | UInt8,
26 | Int8,
27 | ByteArray,
28 |
29 |
30 | RawData,
31 | Unit16 // TODO: Remove this
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/FilterConfiguration.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.models
2 |
3 | import kotlinx.serialization.SerialName
4 | import kotlinx.serialization.Serializable
5 |
6 | @Serializable
7 | data class FilterConfiguration(
8 | @SerialName(value = "highPass")
9 | var highPass: CutOff?=null,
10 | @SerialName(value = "lowPass")
11 | var lowPass: CutOff?=null
12 | )
13 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/FirmwareMaturity.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.models
2 |
3 | enum class FirmwareMaturity {
4 | DRAFT, //Entry added to catalog
5 | BETA, // Release Candidate
6 | RELEASE, // Release
7 | DEMO, // Internal code
8 | CUSTOM, // fwId == 0xFF
9 | SPECIAL // Default
10 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/FotaDetails.kt:
--------------------------------------------------------------------------------
1 | @file:UseSerializers(BoardFotaTypeSerializer::class, BootLoaderTypeSerializer::class)
2 |
3 | package com.st.blue_sdk.board_catalog.models
4 |
5 |
6 | import com.st.blue_sdk.board_catalog.api.serializers.BoardFotaTypeSerializer
7 | import com.st.blue_sdk.board_catalog.api.serializers.BootLoaderTypeSerializer
8 | import kotlinx.serialization.SerialName
9 | import kotlinx.serialization.Serializable
10 | import kotlinx.serialization.UseSerializers
11 |
12 | @Serializable
13 | data class FotaDetails(
14 | @SerialName("partial_fota")
15 | val partialFota: Int? = 0,
16 | @SerialName("type")
17 | val type: BoardFotaType? = BoardFotaType.NO,
18 | @SerialName("max_chunk_length")
19 | var maxChunkLength: Int? = 0,
20 | @SerialName("max_divisor_constraint")
21 | var maxDivisorConstraint: Int? = 0,
22 | @SerialName("fw_url")
23 | var fwUrl: String? = null,
24 | @SerialName("bootloader_type")
25 | val bootloaderType: BootLoaderType? = BootLoaderType.NONE,
26 | @SerialName("mandatory")
27 | val mandatory: Boolean? = false
28 | )
29 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/OptionByteEnumType.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.board_catalog.models
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class OptionByteEnumType(
15 | @SerialName(value = "type")
16 | val type: String? = null,
17 | @SerialName(value = "display_name")
18 | val displayName: String? = null,
19 | @SerialName(value = "comment")
20 | val comment: String? = null,
21 | @SerialName(value = "value")
22 | val value: Int? = null,
23 | @SerialName(value = "icon_code")
24 | val iconCode: Int? = null
25 | )
26 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/board_catalog/models/PowerMode.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.board_catalog.models
2 |
3 | import kotlinx.serialization.SerialName
4 | import kotlinx.serialization.Serializable
5 |
6 | @Serializable
7 | data class PowerMode(
8 | @SerialName(value = "minCustomOdr")
9 | var minCustomSampleTime: Double?=null,
10 | @SerialName(value = "mode")
11 | var mode: Mode = Mode.NONE,
12 | @SerialName(value = "label")
13 | var label: String = "",
14 | @SerialName(value = "odrs")
15 | var odrs: List = listOf()
16 | ) {
17 | enum class Mode(val id: Int) {
18 | NONE(0),
19 | LOW_NOISE(1),
20 | LOW_CURRENT(2),
21 | LOW_POWER(3),
22 | LOW_POWER_2(4),
23 | LOW_POWER_3(5),
24 | LOW_POWER_4(6),
25 | HIGH_PERFORMANCE(7),
26 | HIGH_RESOLUTION(8),
27 | NORMAL_MODE(9)
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/bt/advertise/AdvertiseFilter.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.bt.advertise
9 |
10 | interface AdvertiseFilter {
11 |
12 | /**
13 | * @param advertisingData BLE advertising data
14 | * @return true if advertising data match the filter
15 | * */
16 | fun decodeAdvertiseData(advertisingData: ByteArray): BleAdvertiseInfo?
17 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/bt/advertise/BleAdvertiseInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.bt.advertise
9 |
10 | import com.st.blue_sdk.models.Boards
11 |
12 | interface BleAdvertiseInfo {
13 |
14 | fun getName(): String
15 |
16 | fun getTxPower(): Byte
17 |
18 | fun getAddress(): String?
19 |
20 | fun getFeatureMap(): Long
21 |
22 | fun getOptionBytes(): Long
23 |
24 | fun getDeviceId(): Byte
25 |
26 | fun getProtocolVersion(): Short
27 |
28 | fun getBoardType(): Boards.Model
29 |
30 | fun getFamilyType(): Boards.Family
31 |
32 | fun isBoardSleeping(): Boolean
33 |
34 | fun hasGeneralPurpose(): Boolean
35 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/bt/advertise/BlueNRGAdvertiseInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.bt.advertise
9 |
10 | import com.st.blue_sdk.models.Boards
11 |
12 | class BlueNRGAdvertiseInfo(private val name: String) : BleAdvertiseInfo {
13 |
14 | override fun getName() = name
15 |
16 | override fun getTxPower() = 0.toByte()
17 |
18 | override fun getAddress(): String? = null
19 |
20 | override fun getFeatureMap() = 0L
21 |
22 | override fun getOptionBytes() = 0L
23 |
24 | override fun getDeviceId() = 4.toByte()
25 |
26 | override fun getProtocolVersion() = 1.toShort()
27 |
28 | override fun getBoardType() = Boards.Model.STEVAL_IDB008VX
29 |
30 | override fun getFamilyType() = Boards.Family.OTHER_FAMILY
31 |
32 | override fun isBoardSleeping() = false
33 |
34 | override fun hasGeneralPurpose() = false
35 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/bt/gatt/GattBridge.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.bt.gatt
9 |
10 | import android.bluetooth.BluetoothGattCallback
11 |
12 | /**
13 | * Bridging interface, transform Android BLE API's callbacks to Kotlin flows
14 | */
15 | interface GattBridge {
16 |
17 | fun getBleGattCallback(): BluetoothGattCallback
18 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/di/Qualifiers.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.di
9 |
10 | import javax.inject.Qualifier
11 |
12 | @Qualifier
13 | @Retention(AnnotationRetention.BINARY)
14 | annotation class LogDirectoryPath
15 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/CalibrationStatus.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 |
9 | package com.st.blue_sdk.features
10 |
11 | class CalibrationStatus(
12 | feature: Feature<*>,
13 | commandId: Byte = FEATURE_COMMAND_GET_CONFIGURATION_STATUS,
14 | val status: Boolean
15 | ) :
16 | FeatureResponse(feature = feature, commandId = commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/FeatureCommand.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features
9 |
10 | abstract class FeatureCommand(open val feature: Feature<*>, val commandId: Byte)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/FeatureField.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features
9 |
10 | import com.st.blue_sdk.logger.Loggable
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class FeatureField(
15 | val name: String,
16 | val max: T? = null,
17 | val min: T? = null,
18 | val value: T,
19 | val unit: String? = null
20 | ) : Loggable {
21 |
22 | override val logHeader: String = if (unit.isNullOrEmpty()) {
23 | name
24 | } else {
25 | "$name ($unit)"
26 | }
27 |
28 | override val logValue: String = "$value"
29 |
30 | override val logDoubleValues: List = listOf()
31 | }
32 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/FeatureResponse.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features
9 |
10 | abstract class FeatureResponse(
11 | val feature: Feature<*>,
12 | val commandId: Byte
13 | )
14 |
15 | class EmptyResponse(feature: Feature<*>, commandId: Byte) :
16 | FeatureResponse(feature = feature, commandId = commandId)
17 |
18 | class WriteError(feature: Feature<*>, commandId: Byte) :
19 | FeatureResponse(feature = feature, commandId = commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/GetCalibration.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 |
9 | package com.st.blue_sdk.features
10 |
11 | class GetCalibration(feature: Feature<*>) :
12 | FeatureCommand(feature = feature, commandId = FEATURE_COMMAND_GET_CONFIGURATION_STATUS) {
13 | }
14 |
15 | const val FEATURE_COMMAND_GET_CONFIGURATION_STATUS: Byte = 0xFF.toByte()
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/RawAudio.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features
9 |
10 | import com.st.blue_sdk.logger.Loggable
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class RawAudio(
15 | val data: FeatureField
16 | ) : Loggable {
17 | override val logHeader = data.logHeader
18 | override val logValue = data.logValue
19 | override val logDoubleValues: List = listOf()
20 | }
21 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/RawCommandResponse.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features
9 |
10 | data class RawCommandResponse(
11 | val timeStamp: Long,
12 | val featureMask: Int,
13 | val commandId: Byte,
14 | val payload: ByteArray
15 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/StartCalibration.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 |
9 | package com.st.blue_sdk.features
10 |
11 | class StartCalibration(feature: Feature<*>) :
12 | FeatureCommand(feature = feature, commandId = FEATURE_COMMAND_START_CONFIGURATION) {
13 | }
14 |
15 | const val FEATURE_COMMAND_START_CONFIGURATION: Byte = 0x00
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/StopCalibration.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 |
9 | package com.st.blue_sdk.features
10 |
11 | class StopCalibration(feature: Feature<*>) :
12 | FeatureCommand(feature = feature, commandId = FEATURE_COMMAND_STOP_CONFIGURATION) {
13 | }
14 |
15 | const val FEATURE_COMMAND_STOP_CONFIGURATION: Byte = 0x01
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/acceleration_event/request/EnableDetectionAccelerationEvent.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.acceleration_event.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.acceleration_event.AccelerationEvent
12 | import com.st.blue_sdk.features.acceleration_event.AccelerationEvent.Companion.ACC_EVENT_ENABLE_COMMAND
13 | import com.st.blue_sdk.features.acceleration_event.DetectableEventType
14 |
15 | class EnableDetectionAccelerationEvent(
16 | feature: AccelerationEvent,
17 | val event: DetectableEventType,
18 | val enable: Boolean
19 | ) : FeatureCommand(feature = feature, commandId = ACC_EVENT_ENABLE_COMMAND)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/acceleration_event/response/EnableAccelerationEventResponse.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.acceleration_event.response
9 |
10 | import com.st.blue_sdk.features.FeatureResponse
11 | import com.st.blue_sdk.features.acceleration_event.AccelerationEvent
12 | import com.st.blue_sdk.features.acceleration_event.DetectableEventType
13 |
14 | class EnableAccelerationEventResponse(feature: AccelerationEvent, event: DetectableEventType) :
15 | FeatureResponse(feature = feature, commandId = AccelerationEvent.ACC_EVENT_ENABLE_COMMAND)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/audio/adpcm/AudioADPCMSync.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.audio.adpcm
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class AudioADPCMSync(
16 | val index: FeatureField,
17 | val predSample: FeatureField
18 | ) : Loggable {
19 | override val logHeader = "${index.logHeader}, ${predSample.logHeader}"
20 | override val logValue = "${index.logValue}, ${predSample.logValue}"
21 | override val logDoubleValues: List = listOf()
22 | }
23 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/battery/request/GetBatteryCapacity.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.battery.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.battery.Battery
12 | import com.st.blue_sdk.features.battery.Battery.Companion.COMMAND_GET_BATTERY_CAPACITY
13 |
14 | class GetBatteryCapacity(feature: Battery) :
15 | FeatureCommand(feature = feature, commandId = COMMAND_GET_BATTERY_CAPACITY)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/battery/request/GetBatteryMaxAbsorbedCurrent.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.battery.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.battery.Battery
12 | import com.st.blue_sdk.features.battery.Battery.Companion.COMMAND_GET_MAX_ABSORBED_CURRENT
13 |
14 | class GetBatteryMaxAbsorbedCurrent(feature: Battery) :
15 | FeatureCommand(feature = feature, commandId = COMMAND_GET_MAX_ABSORBED_CURRENT)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/battery/response/BatteryAbsorbedCurrentResponse.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.battery.response
9 |
10 | import com.st.blue_sdk.features.FeatureResponse
11 | import com.st.blue_sdk.features.battery.Battery
12 |
13 | class BatteryAbsorbedCurrentResponse(feature: Battery, commandId: Byte, val current: Float) :
14 | FeatureResponse(feature = feature, commandId = commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/battery/response/BatteryCapacityResponse.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.battery.response
9 |
10 | import com.st.blue_sdk.features.FeatureResponse
11 | import com.st.blue_sdk.features.battery.Battery
12 |
13 | class BatteryCapacityResponse(feature: Battery, commandId: Byte, val capacity: Int) :
14 | FeatureResponse(feature = feature, commandId = commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/beam_forming/request/EnableDisableBeamForming.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.beam_forming.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.beam_forming.BeamForming
12 |
13 | class EnableDisableBeamForming(feature: BeamForming, val enable: Boolean) :
14 | FeatureCommand(feature = feature, commandId = BeamForming.BF_COMMAND_TYPE_ONOFF)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/beam_forming/request/UseStrongBeamFormingAlgorithm.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.beam_forming.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.beam_forming.BeamForming
12 |
13 | class UseStrongBeamFormingAlgorithm(feature: BeamForming, val enable: Boolean) :
14 | FeatureCommand(feature = feature, commandId = BeamForming.BF_COMMAND_TYPE_CHANGE_TYPE)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/co_sensor/COSensorInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.co_sensor
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class COSensorInfo(
16 | val concentration: FeatureField
17 | ) : Loggable {
18 | override val logHeader: String = concentration.logHeader
19 |
20 | override val logValue: String = concentration.logValue
21 | override val logDoubleValues: List = listOf(concentration.value.toDouble())
22 |
23 | override fun toString(): String {
24 | val sampleValue = StringBuilder()
25 | sampleValue.append("\t${concentration.name} = ${concentration.value} ${concentration.unit}\n")
26 | return sampleValue.toString()
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/compass/CompassInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.compass
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class CompassInfo(
16 | val angle: FeatureField
17 | ) : Loggable {
18 | override val logHeader: String = angle.logHeader
19 |
20 | override val logValue: String = angle.logValue
21 | override val logDoubleValues: List = listOf(angle.value.toDouble())
22 |
23 | override fun toString(): String {
24 | val sampleValue = StringBuilder()
25 | sampleValue.append("\t${angle.name} = ${angle.value} ${angle.unit}\n")
26 | return sampleValue.toString()
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/direction_of_arrival/DirectionOfArrivalInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.direction_of_arrival
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class DirectionOfArrivalInfo(
16 | val angle: FeatureField
17 | ) : Loggable {
18 | override val logHeader: String = angle.logHeader
19 |
20 | override val logValue: String = angle.logValue
21 | override val logDoubleValues: List = listOf(angle.value.toDouble())
22 |
23 |
24 | override fun toString(): String {
25 | val sampleValue = StringBuilder()
26 | sampleValue.append("\t${angle.name} = ${angle.value} ${angle.unit}\n")
27 | return sampleValue.toString()
28 | }
29 | }
30 |
31 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/direction_of_arrival/request/SetSensitivityHigh.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.direction_of_arrival.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.direction_of_arrival.DirectionOfArrival
12 |
13 | class SetSensitivityHigh(feature: DirectionOfArrival) :
14 | FeatureCommand(feature = feature, commandId = DirectionOfArrival.COMMAND_SENSITIVITY_HIGH)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/direction_of_arrival/request/SetSensitivityLow.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.direction_of_arrival.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.direction_of_arrival.DirectionOfArrival
12 |
13 | class SetSensitivityLow(feature: DirectionOfArrival) :
14 | FeatureCommand(feature = feature, commandId = DirectionOfArrival.COMMAND_SENSITIVITY_LOW)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/event_counter/EventCounterInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.event_counter
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class EventCounterInfo(
16 | val count: FeatureField
17 | ) : Loggable {
18 | override val logHeader: String = count.logHeader
19 |
20 | override val logValue: String = count.logValue
21 | override val logDoubleValues: List = listOf(count.value.toDouble())
22 |
23 | override fun toString(): String {
24 | val sampleValue = StringBuilder()
25 | sampleValue.append("\t${count.name} = ${count.value}\n")
26 | return sampleValue.toString()
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/exported/ExportedAudioOpusMusicFeature.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.exported
9 |
10 | import java.util.*
11 |
12 | class ExportedAudioOpusMusicFeature(
13 | override val name: String = NAME,
14 | override val isEnabled: Boolean = false,
15 | override val uuid: UUID = UUID.fromString(AUDIO_OPUS_MUSIC_UUID)
16 | ) : ExportedFeature {
17 |
18 | companion object {
19 | const val AUDIO_OPUS_MUSIC_UUID = "00000011-0002-11e1-ac36-0002a5d5c51b"
20 | const val NAME = "ExportedAudioOpusMusicFeature"
21 | }
22 |
23 | override fun copy(isEnabled: Boolean): ExportedFeature =
24 | ExportedAudioOpusMusicFeature(isEnabled = isEnabled)
25 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/exported/ExportedAudioOpusVoiceFeature.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.exported
9 |
10 | import java.util.*
11 |
12 | class ExportedAudioOpusVoiceFeature(
13 | override val name: String = NAME,
14 | override val isEnabled: Boolean = false,
15 | override val uuid: UUID = UUID.fromString(AUDIO_OPUS_VOICE_UUID)
16 | ) : ExportedFeature {
17 |
18 | companion object {
19 | const val NAME = "ExportedAudioOpusVoiceFeature"
20 | const val AUDIO_OPUS_VOICE_UUID = "00000001-0002-11e1-ac36-0002a5d5c51b"
21 | }
22 |
23 | override fun copy(isEnabled: Boolean): ExportedFeature =
24 | ExportedAudioOpusVoiceFeature(isEnabled = isEnabled)
25 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/exported/ExportedFeature.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.exported
9 |
10 | import java.util.*
11 |
12 | interface ExportedFeature {
13 | val name: String
14 | val isEnabled: Boolean
15 | val uuid: UUID
16 |
17 | fun copy(isEnabled: Boolean): ExportedFeature
18 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/ai_logging/request/StartLogging.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.ai_logging.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.extended.ai_logging.AiLogging
12 |
13 | class StartLogging(
14 | feature: AiLogging,
15 | val logMask: Long,
16 | val environmentalFreq: Float,
17 | val inertialFreq: Float,
18 | val audioVolume: Byte
19 | ) :
20 | FeatureCommand(feature = feature, commandId = 0x1) {
21 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/ai_logging/request/StopLogging.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.ai_logging.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.extended.ai_logging.AiLogging
12 |
13 | class StopLogging(feature: AiLogging) :
14 | FeatureCommand(feature = feature, commandId = 0x0) {
15 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/ai_logging/request/UpdateAnnotation.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.ai_logging.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.extended.ai_logging.AiLogging
12 |
13 | class UpdateAnnotation(
14 | feature: AiLogging,
15 | val label: String
16 | ) :
17 | FeatureCommand(feature = feature, commandId = 0x3) {
18 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/binary_content/BinaryContentCommand.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.binary_content
2 |
3 | import com.st.blue_sdk.features.FeatureCommand
4 |
5 | class BinaryContentCommand(feature: BinaryContent, val data: ByteArray) :
6 | FeatureCommand(
7 | feature = feature,
8 | commandId = BinaryContent.FEATURE_SEND_BINARY_CONTENT_COMMAND
9 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/binary_content/RawData.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.binary_content
2 |
3 | import com.st.blue_sdk.features.FeatureField
4 | import com.st.blue_sdk.logger.Loggable
5 | import kotlinx.serialization.Serializable
6 |
7 | @Serializable
8 | data class RawData(
9 | val data: FeatureField,
10 | val bytesRec: FeatureField,
11 | val numberPackets: FeatureField
12 | ) : Loggable {
13 | override val logHeader = data.logHeader
14 | override val logValue = data.logValue
15 |
16 | override val logDoubleValues: List = listOf()
17 | }
18 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/ext_configuration/BanksStatus.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.ext_configuration
9 |
10 | import kotlinx.serialization.Serializable
11 |
12 | @Serializable
13 | data class BanksStatus(
14 | val currentBank: Int,
15 | val fwId1: String,
16 | val fwId2: String
17 | ):java.io.Serializable
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/ext_configuration/CustomCommand.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.ext_configuration
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class CustomCommand(
15 | @SerialName("Name")
16 | val name: String? = null,
17 | @SerialName("Type")
18 | val type: String? = null,
19 | @SerialName("Min")
20 | val min: Int? = null,
21 | @SerialName("DefaultValue")
22 | val default: Int? = null,
23 | @SerialName("Max")
24 | val max: Int? = null,
25 | @SerialName("Desc")
26 | val description: String? = null,
27 | @SerialName("StringValues")
28 | val stringValues: List? = null,
29 | @SerialName("IntegerValues")
30 | val integerValues: List? = null
31 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/ext_configuration/ExtendedFeatureResponse.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.ext_configuration
9 |
10 | import com.st.blue_sdk.features.FeatureResponse
11 |
12 | class ExtendedFeatureResponse(feature: ExtConfiguration, val response: ExtConfigCommandAnswers) :
13 | FeatureResponse(feature = feature, commandId = ExtConfiguration.FEATURE_SEND_EXT_COMMAND)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/ext_configuration/request/ExtendedFeatureCommand.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.ext_configuration.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.extended.ext_configuration.ExtConfiguration
12 |
13 | class ExtendedFeatureCommand(
14 | feature: ExtConfiguration,
15 | val extendedCommand: ExtConfigCommands,
16 | val hasResponse: Boolean = true
17 | ) :
18 | FeatureCommand(
19 | feature = feature,
20 | commandId = ExtConfiguration.FEATURE_SEND_EXT_COMMAND
21 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/ext_configuration/response/ExtCommandResponse.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.ext_configuration.response
9 |
10 | import com.st.blue_sdk.features.FeatureResponse
11 | import com.st.blue_sdk.features.extended.ext_configuration.ExtConfigCommandAnswers
12 | import com.st.blue_sdk.features.extended.ext_configuration.ExtConfiguration
13 | import com.st.blue_sdk.features.extended.ext_configuration.ExtConfiguration.Companion.FEATURE_SEND_EXT_COMMAND
14 |
15 | class ExtCommandResponse(feature: ExtConfiguration, val response: ExtConfigCommandAnswers) :
16 | FeatureResponse(feature = feature, commandId = FEATURE_SEND_EXT_COMMAND)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/fitness_activity/request/EnableActivityDetection.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.fitness_activity.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.extended.fitness_activity.FitnessActivity
12 | import com.st.blue_sdk.features.extended.fitness_activity.FitnessActivityType
13 |
14 | class EnableActivityDetection(
15 | feature: FitnessActivity,
16 | val activityType: FitnessActivityType
17 | ) : FeatureCommand(feature = feature, commandId = ENABLE_FITNESS_ACTIVITY) {
18 | companion object {
19 | const val ENABLE_FITNESS_ACTIVITY = 1.toByte()
20 | }
21 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/LogConfig.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.features.extended.hs_datalog_config.model.Device
12 | import com.st.blue_sdk.features.extended.hs_datalog_config.model.DeviceStatus
13 | import com.st.blue_sdk.logger.Loggable
14 | import kotlinx.serialization.Serializable
15 |
16 | @Serializable
17 | data class LogConfig(
18 | val device: FeatureField,
19 | val deviceStatus: FeatureField
20 | ) : Loggable {
21 | override val logHeader: String = "${device.logHeader}, ${deviceStatus.logHeader}"
22 |
23 | override val logValue: String = "${device.logValue}, ${deviceStatus.logValue}"
24 |
25 | override val logDoubleValues: List = listOf()
26 | }
27 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/model/Device.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.model
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class Device(
15 | @SerialName("deviceInfo") var deviceInfo: DeviceInfo? = null,
16 | @SerialName("sensor") var sensors: List? = emptyList(),
17 | @SerialName("tagConfig") var tags: TagConfig? = null
18 | )
19 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/model/DeviceInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.model
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class DeviceInfo(
15 | @SerialName("serialNumber") var serialNumber: String, // TODO: update ongoing FW side (probably this will be in a sort of UUID format (with no spaces))
16 | @SerialName("alias") var alias: String,
17 | @SerialName("partNumber") var partNumber: String? = null,
18 | @SerialName("URL") val URL: String? = null,
19 | @SerialName("fwName") val fwName: String? = null,
20 | @SerialName("fwVersion") val fwVersion: String? = null,
21 | @SerialName("dataFileExt") val dataFileExt: String? = null,
22 | @SerialName("dataFileFormat") val dataFileFormat: String? = null
23 | )
24 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/model/Response.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.model
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class Response(
15 | @SerialName("JSONVersion")
16 | val version: String,
17 | @SerialName("device")
18 | val device: Device? = null
19 | )
20 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/model/SamplesPerTs.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.model
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class SamplesPerTs(
15 | @SerialName("min") val min: Int,
16 | @SerialName("max") val max: Int,
17 | @SerialName("dataType") val dataType: String
18 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/model/Sensor.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.model
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class Sensor(
15 | @SerialName("id") val id: Int,
16 | @SerialName("name") val name: String,
17 | @SerialName("sensorDescriptor") val sensorDescriptor: SensorDescriptor,
18 | @SerialName("sensorStatus") val sensorStatus: SensorStatus
19 | ) {
20 | override fun equals(other: Any?): Boolean {
21 | if (this === other) return true
22 |
23 | if (javaClass != other?.javaClass) return false
24 |
25 | other as Sensor
26 |
27 | if (id != other.id) return false
28 |
29 | return true
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/model/SensorCoordinate.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.model
9 |
10 | data class SensorCoordinate(val sensorID: Int, val subSensorID: Int)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/model/SensorDescriptor.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.model
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class SensorDescriptor(
15 | @SerialName("subSensorDescriptor") var subSensorDescriptors: List
16 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/model/SensorStatusWId.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.model
9 |
10 | data class SensorStatusWId(
11 | val sensorId: Int?,
12 | val sensorStatus: SensorStatus?
13 | )
14 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/model/SubSensorDescriptor.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.model
9 |
10 | import com.st.blue_sdk.board_catalog.models.SensorType
11 | import kotlinx.serialization.SerialName
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class SubSensorDescriptor(
16 | @SerialName("id") val id: Int,
17 | @SerialName("sensorType") val sensorType: SensorType,
18 | @SerialName("dimensions") val dimensions: Int,
19 | @SerialName("dimensionsLabel") val dimensionsLabel: List,
20 | @SerialName("unit") val unit: String?,
21 | @SerialName("dataType") val dataType: String?,
22 | @SerialName("FS") val fs: List?,
23 | @SerialName("ODR") val odr: List?,
24 | @SerialName("samplesPerTs") val samplesPerTs: SamplesPerTs
25 | )
26 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/model/Tag.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.model
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class Tag(
15 | @SerialName("id") val id: Int,
16 | @SerialName("label") var label: String,
17 | @SerialName("enabled") var isEnabled: Boolean = false
18 | )
19 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/model/TagConfig.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.model
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class TagConfig(
15 | @SerialName("maxTagsPerAcq") var maxTagsPerAcq: Int,
16 | @SerialName("swTags") val softwareTags: List,
17 | @SerialName("hwTags") val hardwareTags: List
18 | )
19 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/model/TagHW.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.model
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class TagHW(
15 | @SerialName("id") val id: Int,
16 | @SerialName("label") var label: String,
17 | @SerialName("enabled") var isEnabled: Boolean = false,
18 | @SerialName("pinDesc") var pinDesc: String = ""
19 | )
20 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/hs_datalog_config/request/HSDataLogCommand.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.hs_datalog_config.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.extended.hs_datalog_config.HSDataLogConfig
12 |
13 | class HSDataLogCommand(feature: HSDataLogConfig, val cmd: HSDCmd) :
14 | FeatureCommand(feature = feature, commandId = 0.toByte())
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/ispu_control/ISPUControlSendJSONCommand.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.ispu_control
2 |
3 | import com.st.blue_sdk.features.FeatureCommand
4 |
5 | class ISPUControlSendJSONCommand(feature: ISPUControlFeature, val data: ByteArray) :
6 | FeatureCommand(
7 | feature = feature,
8 | commandId = ISPUControlFeature.FEATURE_SEND_ISPU_CONTROL_JSON_COMMAND
9 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/ispu_control/ISPUControlSendUCFCommand.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.ispu_control
2 |
3 | import com.st.blue_sdk.features.FeatureCommand
4 |
5 | class ISPUControlSendUCFCommand(feature: ISPUControlFeature, val data: ByteArray) :
6 | FeatureCommand(
7 | feature = feature,
8 | commandId = ISPUControlFeature.FEATURE_SEND_ISPU_CONTROL_UCF_COMMAND
9 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/ispu_control/ISPURawData.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.ispu_control
2 |
3 | import com.st.blue_sdk.features.FeatureField
4 | import com.st.blue_sdk.logger.Loggable
5 | import kotlinx.serialization.Serializable
6 |
7 | @Serializable
8 | data class ISPURawData(
9 | val data: FeatureField,
10 | val bytesRec: FeatureField,
11 | val numberPackets: FeatureField
12 | ) : Loggable {
13 | override val logHeader = data.logHeader
14 | override val logValue = data.logValue
15 |
16 | override val logDoubleValues: List = listOf()
17 | }
18 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/json_nfc/answer/JsonNFCResponse.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.json_nfc.answer
2 |
3 | import com.st.blue_sdk.features.FeatureField
4 | import com.st.blue_sdk.logger.Loggable
5 | import kotlinx.serialization.Serializable
6 |
7 | @Serializable
8 | data class JsonNFCResponse(
9 | val supportedModes: FeatureField
10 | ) : Loggable {
11 | override val logHeader = supportedModes.logHeader
12 |
13 | override val logValue: String = supportedModes.logValue
14 |
15 | override val logDoubleValues: List = listOf()
16 | }
17 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/json_nfc/answer/JsonReadModesResult.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.json_nfc.answer
2 |
3 | import kotlinx.serialization.SerialName
4 |
5 | @kotlinx.serialization.Serializable
6 | data class JsonReadModesResult(
7 | @SerialName("Answer")
8 | val Answer: String?
9 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/json_nfc/request/JsonNFCFeatureWriteCommand.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.json_nfc.request
2 |
3 | import com.st.blue_sdk.features.FeatureCommand
4 | import com.st.blue_sdk.features.extended.json_nfc.JsonNFC
5 |
6 | class JsonNFCFeatureWriteCommand(feature: JsonNFC, val nfcCommand: JsonCommand) :
7 | FeatureCommand(
8 | feature = feature,
9 | commandId = JsonNFC.FEATURE_SEND_NFC_COMMAND
10 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/json_nfc/request/JsonVCard.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.json_nfc.request
2 |
3 | import kotlinx.serialization.SerialName
4 |
5 | @kotlinx.serialization.Serializable
6 | data class JsonVCard(
7 | @SerialName("Name")
8 | var Name: String? = null,
9 | @SerialName("FormattedName")
10 | var FormattedName: String? = null,
11 | @SerialName("Title")
12 | var Title: String? = null,
13 | @SerialName("Org")
14 | var Org: String? = null,
15 | @SerialName("HomeAddress")
16 | var HomeAddress: String? = null,
17 | @SerialName("WorkAddress")
18 | var WorkAddress: String? = null,
19 | @SerialName("Address")
20 | var Address: String? = null,
21 | @SerialName("HomeTel")
22 | var HomeTel: String? = null,
23 | @SerialName("WorkTel")
24 | var WorkTel: String? = null,
25 | @SerialName("CellTel")
26 | var CellTel: String? = null,
27 | @SerialName("HomeEmail")
28 | var HomeEmail: String? = null,
29 | @SerialName("WorkEmail")
30 | var WorkEmail: String? = null,
31 | @SerialName("Url")
32 | var Url: String? = null
33 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/json_nfc/request/JsonWIFI.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.json_nfc.request
2 |
3 | import kotlinx.serialization.SerialName
4 |
5 | @kotlinx.serialization.Serializable
6 | data class JsonWIFI(
7 | @SerialName("NetworkSSID")
8 | val NetworkSSID: String? = null,
9 | @SerialName("NetworkKey")
10 | val NetworkKey: String? = null,
11 | @SerialName("AuthenticationType")
12 | val AuthenticationType: Int = 0,
13 | @SerialName("EncryptionType")
14 | val EncryptionType: Int = 0
15 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/motion_algorithm/request/EnableMotionAlgorithm.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.motion_algorithm.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.extended.motion_algorithm.AlgorithmType
12 | import com.st.blue_sdk.features.extended.motion_algorithm.MotionAlgorithm
13 |
14 | class EnableMotionAlgorithm(
15 | feature: MotionAlgorithm,
16 | val algorithmType: AlgorithmType
17 | ) : FeatureCommand(feature = feature, commandId = ENABLE_MOTION_ALGORITHM) {
18 | companion object {
19 | const val ENABLE_MOTION_ALGORITHM = 1.toByte()
20 | }
21 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/navigation_control/NavigationControlInfo.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.navigation_control
2 |
3 | import com.st.blue_sdk.logger.Loggable
4 |
5 | data class NavigationControlInfo(val name: String,
6 | ): Loggable {
7 | override val logHeader: String = ""
8 |
9 | override val logValue: String = ""
10 |
11 | override fun toString(): String = "To Be Implemented"
12 |
13 | override val logDoubleValues: List = listOf()
14 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/neai_anomaly_detection/request/WriteDetectionCommand.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.neai_anomaly_detection.request
2 |
3 | import com.st.blue_sdk.features.FeatureCommand
4 | import com.st.blue_sdk.features.extended.neai_anomaly_detection.NeaiAnomalyDetection
5 |
6 | class WriteDetectionCommand(
7 | feature: NeaiAnomalyDetection
8 | ) : FeatureCommand(feature = feature, commandId = DETECTION_COMMAND) {
9 | companion object {
10 | const val DETECTION_COMMAND = 2.toByte()
11 | }
12 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/neai_anomaly_detection/request/WriteLearningCommand.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.neai_anomaly_detection.request
2 |
3 | import com.st.blue_sdk.features.FeatureCommand
4 | import com.st.blue_sdk.features.extended.neai_anomaly_detection.NeaiAnomalyDetection
5 |
6 | class WriteLearningCommand(
7 | feature: NeaiAnomalyDetection
8 | ) : FeatureCommand(feature = feature, commandId = LEARNING_COMMAND) {
9 | companion object {
10 | const val LEARNING_COMMAND = 1.toByte()
11 | }
12 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/neai_anomaly_detection/request/WriteResetKnowledgeCommand.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.neai_anomaly_detection.request
2 |
3 | import com.st.blue_sdk.features.FeatureCommand
4 | import com.st.blue_sdk.features.extended.neai_anomaly_detection.NeaiAnomalyDetection
5 |
6 | class WriteResetKnowledgeCommand(
7 | feature: NeaiAnomalyDetection
8 | ) : FeatureCommand(feature = feature, commandId = RESET_KNOWLEDGE_COMMAND) {
9 | companion object {
10 | const val RESET_KNOWLEDGE_COMMAND = 0xFF.toByte()
11 | }
12 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/neai_anomaly_detection/request/WriteStopCommand.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.neai_anomaly_detection.request
2 |
3 | import com.st.blue_sdk.features.FeatureCommand
4 | import com.st.blue_sdk.features.extended.neai_anomaly_detection.NeaiAnomalyDetection
5 |
6 | class WriteStopCommand(
7 | feature: NeaiAnomalyDetection
8 | ) : FeatureCommand(feature = feature, commandId = STOP_COMMAND) {
9 | companion object {
10 | const val STOP_COMMAND = 0.toByte()
11 | }
12 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/neai_class_classification/request/WriteStartClassificationCommand.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.neai_class_classification.request
2 |
3 | import com.st.blue_sdk.features.FeatureCommand
4 | import com.st.blue_sdk.features.extended.neai_class_classification.NeaiClassClassification
5 |
6 | class WriteStartClassificationCommand(
7 | feature: NeaiClassClassification
8 | ) : FeatureCommand(feature = feature, commandId = START_CLASSIFICATION_COMMAND) {
9 | companion object {
10 | const val START_CLASSIFICATION_COMMAND = 1.toByte()
11 | }
12 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/neai_class_classification/request/WriteStopClassificationCommand.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.neai_class_classification.request
2 |
3 | import com.st.blue_sdk.features.FeatureCommand
4 | import com.st.blue_sdk.features.extended.neai_class_classification.NeaiClassClassification
5 |
6 | class WriteStopClassificationCommand(
7 | feature: NeaiClassClassification
8 | ) : FeatureCommand(feature = feature, commandId = STOP_CLASSIFICATION_COMMAND) {
9 | companion object {
10 | const val STOP_CLASSIFICATION_COMMAND = 0.toByte()
11 | }
12 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/neai_extrapolation/request/WriteStartExtrapolationCommand.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.neai_extrapolation.request
2 |
3 | import com.st.blue_sdk.features.FeatureCommand
4 | import com.st.blue_sdk.features.extended.neai_extrapolation.NeaiExtrapolation
5 |
6 | class WriteStartExtrapolationCommand(
7 | feature: NeaiExtrapolation
8 | ) : FeatureCommand(feature = feature, commandId = START_EXTRAPOLATION_COMMAND) {
9 | companion object {
10 | const val START_EXTRAPOLATION_COMMAND = 1.toByte()
11 | }
12 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/neai_extrapolation/request/WriteStopExtrapolationCommand.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.neai_extrapolation.request
2 |
3 | import com.st.blue_sdk.features.FeatureCommand
4 | import com.st.blue_sdk.features.extended.neai_extrapolation.NeaiExtrapolation
5 |
6 | class WriteStopExtrapolationCommand(
7 | feature: NeaiExtrapolation
8 | ) : FeatureCommand(feature = feature, commandId = STOP_EXTRAPOLATION_COMMAND) {
9 | companion object {
10 | const val STOP_EXTRAPOLATION_COMMAND = 0.toByte()
11 | }
12 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/piano/request/CommandPianoSound.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.piano.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.extended.piano.Piano
12 | import com.st.blue_sdk.features.extended.piano.PianoCommand
13 |
14 | class CommandPianoSound(feature: Piano, val command: PianoCommand, val key: Byte? = null) :
15 | FeatureCommand(feature = feature, commandId = PIANO_COMMAND_ID) {
16 | companion object {
17 | const val PIANO_COMMAND_TYPE_STOP = 0x00.toByte()
18 | const val PIANO_COMMAND_TYPE_START = 0x01.toByte()
19 | const val PIANO_COMMAND_ID = 0x00.toByte()
20 | }
21 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/pnpl/PnPLConfig.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.pnpl
2 |
3 | import com.st.blue_sdk.features.FeatureField
4 | import com.st.blue_sdk.features.extended.pnpl.model.PnPLDevice
5 | import com.st.blue_sdk.features.extended.pnpl.model.PnPLSetCommandResponse
6 | import com.st.blue_sdk.logger.Loggable
7 | import kotlinx.serialization.Serializable
8 |
9 | @Serializable
10 | data class PnPLConfig(
11 | val deviceStatus: FeatureField,
12 | val setCommandResponse: FeatureField
13 | ) : Loggable {
14 | override val logHeader = deviceStatus.logHeader
15 |
16 | override val logValue: String = deviceStatus.logValue
17 |
18 | override val logDoubleValues: List = listOf()
19 | }
20 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/pnpl/model/PnPLResponse.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.pnpl.model
2 |
3 | import kotlinx.serialization.SerialName
4 | import kotlinx.serialization.json.JsonObject
5 |
6 |
7 | @kotlinx.serialization.Serializable
8 | data class PnPLResponse(
9 | @SerialName("schema_version")
10 | val schemaVersion: String,
11 | @SerialName("uuid")
12 | val uuid: String,
13 | @SerialName("devices")
14 | val devices: List
15 | )
16 |
17 | @kotlinx.serialization.Serializable
18 | data class PnPLDevice(
19 | @SerialName("board_id")
20 | val boardId: Int?,
21 | @SerialName("fw_id")
22 | val fwId: Int?,
23 | @SerialName("sn")
24 | val serialNumber: String?,
25 | @SerialName("pnpl_ble_responses")
26 | val pnplBleResponses: Boolean?,
27 | @SerialName("components")
28 | val components: List
29 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/pnpl/model/PnPLSetCommandResponse.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.pnpl.model
2 |
3 | import kotlinx.serialization.SerialName
4 | import kotlinx.serialization.Serializable
5 | import kotlinx.serialization.json.JsonObject
6 |
7 |
8 | @Serializable
9 | data class PnPLSetCommandResponse(
10 | @SerialName(value = "PnPL_Response")
11 | val response: PnpLSetCommandResponseEntry?
12 | )
13 |
14 | @Serializable
15 | data class PnpLSetCommandResponseEntry(
16 | @SerialName(value = "message")
17 | val message: String?= null,
18 | @SerialName(value = "status")
19 | val status: Boolean,
20 | // @SerialName(value = "value")
21 | // Not Correct because it could be also a scalar value
22 | // val value: JsonObject?=null
23 | )
24 |
25 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/raw_controlled/RawControlledInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.raw_controlled
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class RawControlledInfo(
16 | val data: List>
17 | ) : Loggable {
18 | override val logHeader: String = data.joinToString(separator = ", ") { it.logHeader }
19 |
20 | override val logValue: String = data.joinToString(separator = ", ") { it.logValue }
21 |
22 | override val logDoubleValues: List = listOf()
23 |
24 | override fun toString(): String {
25 | val sampleValue = StringBuilder()
26 | data.forEach { sampleValue.append("\t${it.name} = ${it.value}\n") }
27 | return sampleValue.toString()
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/raw_controlled/model/RawCustom.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.raw_controlled.model
2 |
3 | import kotlinx.serialization.SerialName
4 | import kotlinx.serialization.Serializable
5 |
6 | @Serializable
7 | data class RawCustom(
8 | @SerialName(value = "output")
9 | val output: List
10 | )
11 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/raw_controlled/model/RawCustomEntry.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.raw_controlled.model
2 |
3 | import kotlinx.serialization.SerialName
4 | import kotlinx.serialization.Serializable
5 |
6 | @Serializable
7 | data class RawCustomEntry(
8 | @SerialName(value = "name")
9 | val name: String,
10 | @SerialName(value = "type")
11 | val type:RawPnPLCustomEntryFormat,
12 | @SerialName(value = "size")
13 | val elements: Int=1
14 |
15 | ) {
16 | @kotlinx.serialization.Transient
17 | var values: MutableList = mutableListOf()
18 |
19 | enum class RawPnPLCustomEntryFormat {
20 | uint8_t,
21 | char,
22 | int8_t,
23 | uint16_t,
24 | int16_t,
25 | uint32_t,
26 | int32_t,
27 | float
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/raw_controlled/model/RawPnPLEntry.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.raw_controlled.model
9 |
10 | data class RawPnPLEntry(
11 | val name: String,
12 | val displayName: String?=null,
13 | val format: RawPnPLEntryFormat
14 | )
15 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/raw_controlled/model/RawPnPLEntryEnumLabel.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.raw_controlled.model
2 |
3 | import kotlinx.serialization.SerialName
4 | import kotlinx.serialization.Serializable
5 |
6 | @Serializable
7 | data class RawPnPLEntryEnumLabel(
8 | @SerialName(value = "value")
9 | val value: Int,
10 | @SerialName(value = "label")
11 | val label: String,
12 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/raw_controlled/model/RawStreamIdEntry.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.raw_controlled.model
9 |
10 | data class RawStreamIdEntry(
11 | val componentName: String,
12 | val streamId: Int,
13 | val formats: List,
14 | val customFormat: RawCustom?=null
15 | )
16 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/scene_description/SceneDescriptionInfo.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.extended.scene_description
2 |
3 | import com.st.blue_sdk.logger.Loggable
4 |
5 | data class SceneDescriptionInfo(val name: String,
6 | ): Loggable {
7 | override val logHeader: String = ""
8 |
9 | override val logValue: String = ""
10 |
11 | override fun toString(): String = "To Be Implemented"
12 |
13 | override val logDoubleValues: List = listOf()
14 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/extended/tof_multi_object/request/CommandPresenceRecognition.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.extended.tof_multi_object.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.extended.tof_multi_object.ToFMultiObject
12 |
13 | class CommandPresenceRecognition(feature: ToFMultiObject, val enable: Boolean) :
14 | FeatureCommand(feature = feature, commandId = TOF_PRESENCE_COMMAND_ID) {
15 | companion object {
16 | const val TOF_PRESENCE_DISABLE = 0x00.toByte()
17 | const val TOF_PRESENCE_ENABLE = 0x01.toByte()
18 | const val TOF_PRESENCE_COMMAND_ID = 0x00.toByte()
19 | }
20 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/external/std/BodySensorLocationInfo.kt:
--------------------------------------------------------------------------------
1 | package com.st.blue_sdk.features.external.std
2 |
3 | import com.st.blue_sdk.features.FeatureField
4 | import com.st.blue_sdk.logger.Loggable
5 | import kotlinx.serialization.Serializable
6 |
7 | @Serializable
8 | data class BodySensorLocationInfo(
9 | val bodySensorLocation: FeatureField,
10 |
11 | ) : Loggable {
12 | override val logHeader: String =
13 | bodySensorLocation.logHeader
14 |
15 | override val logValue: String =
16 | bodySensorLocation.logValue
17 |
18 | override val logDoubleValues: List = listOf()
19 |
20 | override fun toString(): String {
21 | val sampleValue = StringBuilder()
22 | sampleValue.append("\t${bodySensorLocation.name} = ${bodySensorLocation.value}\n")
23 |
24 | return sampleValue.toString()
25 | }
26 | }
27 |
28 | enum class BodySensorLocationType {
29 | Other,
30 | Chest,
31 | Wrist,
32 | Finger,
33 | Hand,
34 | EarLobe,
35 | Foot,
36 | NotKnown
37 | }
38 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/external/stm32/led_and_reboot/ControlLedCommand.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.external.stm32.led_and_reboot
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureCommand
12 |
13 | class ControlLedCommand(
14 | feature: Feature<*>,
15 | commandId: Byte,
16 | val deviceId: Byte,
17 | val turnOn: Boolean
18 | ) : FeatureCommand(feature, commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/external/stm32/led_and_reboot/RebootCommand.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.external.stm32.led_and_reboot
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureCommand
12 |
13 | class RebootCommand(
14 | feature: Feature<*>,
15 | commandId: Byte,
16 | val deviceId: Byte
17 | ) : FeatureCommand(feature, commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/free_fall/FreeFallInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.free_fall
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class FreeFallInfo(
16 | val freeFall: FeatureField
17 | ) : Loggable {
18 | override val logHeader: String = freeFall.logHeader
19 |
20 | override val logValue: String = freeFall.logValue
21 |
22 | override val logDoubleValues: List = listOf(freeFall.value.toDouble())
23 |
24 | override fun toString(): String {
25 | val sampleValue = StringBuilder()
26 | sampleValue.append("\t${freeFall.name} = ${freeFall.value}\n")
27 | return sampleValue.toString()
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/general_purpose/GeneralPurposeInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.general_purpose
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class GeneralPurposeInfo(
16 | val data: List>
17 | ) : Loggable {
18 | override val logHeader: String = data.joinToString(separator = ", ") { it.logHeader }
19 |
20 | override val logValue: String = data.joinToString(separator = ", ") { it.logValue }
21 |
22 | override val logDoubleValues: List = listOf()
23 |
24 | override fun toString(): String {
25 | val sampleValue = StringBuilder()
26 | data.forEach { sampleValue.append("\t${it.name} = ${it.value}\n") }
27 | return sampleValue.toString()
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/humidity/HumidityInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.humidity
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class HumidityInfo(
16 | val humidity: FeatureField
17 | ) : Loggable {
18 | override val logHeader: String = humidity.logHeader
19 |
20 | override val logValue: String = humidity.logValue
21 |
22 | override val logDoubleValues: List = listOf(humidity.value.toDouble())
23 |
24 | override fun toString(): String {
25 | val sampleValue = StringBuilder()
26 | sampleValue.append("\t${humidity.name} = ${humidity.value} ${humidity.unit}\n")
27 | return sampleValue.toString()
28 | }
29 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/logging/sd/SDLoggingInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.logging.sd
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | class SDLoggingInfo(
16 | val loggingStatus: FeatureField,
17 | val featureIds: FeatureField>,
18 | val logInterval: FeatureField
19 | ) : Loggable {
20 |
21 | override val logHeader: String =
22 | "${loggingStatus.logHeader} ,${featureIds.logHeader}, ${logInterval.logHeader}"
23 |
24 | override val logValue: String =
25 | "${loggingStatus.logHeader} ,${featureIds.logValue}, ${logInterval.logValue}"
26 |
27 | override val logDoubleValues: List = listOf()
28 | }
29 |
30 | enum class LoggingStatus {
31 | STOPPED, STARTED, NO_SD, IO_ERROR
32 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/logging/sd/commands/StartLogging.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.logging.sd.commands
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureCommand
12 | import com.st.blue_sdk.features.logging.sd.SDLoggingFeature.Companion.START_SD_LOGGING
13 |
14 | class StartLogging(
15 | feature: Feature<*>,
16 | commandId: Byte = START_SD_LOGGING,
17 | val featureMasks: Set,
18 | val interval: Long
19 | ) : FeatureCommand(feature, commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/logging/sd/commands/StopLogging.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.logging.sd.commands
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureCommand
12 | import com.st.blue_sdk.features.logging.sd.SDLoggingFeature.Companion.STOP_SD_LOGGING
13 |
14 | class StopLogging(feature: Feature<*>, commandId: Byte = STOP_SD_LOGGING) :
15 | FeatureCommand(feature, commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/luminosity/LuminosityInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.luminosity
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class LuminosityInfo(
16 | val luminosity: FeatureField
17 | ) : Loggable {
18 | override val logHeader: String = luminosity.logHeader
19 | override val logValue: String = luminosity.logValue
20 |
21 | override val logDoubleValues: List = listOf(luminosity.value.toDouble())
22 |
23 | override fun toString(): String {
24 | val sampleValue = StringBuilder()
25 | sampleValue.append("\t${luminosity.name} = ${luminosity.value} ${luminosity.unit}\n")
26 | return sampleValue.toString()
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/mems_norm/MemsNormInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.mems_norm
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class MemsNormInfo(
16 | val norm: FeatureField
17 | ) : Loggable {
18 | override val logHeader: String = norm.logHeader
19 |
20 | override val logValue: String = norm.logValue
21 |
22 | override val logDoubleValues: List = listOf(norm.value.toDouble())
23 |
24 | override fun toString(): String {
25 | val sampleValue = StringBuilder()
26 | sampleValue.append("\t${norm.name} = ${norm.value}\n")
27 | return sampleValue.toString()
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/motion_intensity/MotionIntensityInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.motion_intensity
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class MotionIntensityInfo(
16 | val intensity: FeatureField,
17 | ) : Loggable {
18 | override val logHeader: String = intensity.logHeader
19 |
20 | override val logValue: String = intensity.logValue
21 |
22 | override val logDoubleValues: List = listOf(intensity.value.toDouble())
23 |
24 | override fun toString(): String {
25 | val sampleValue = StringBuilder()
26 | sampleValue.append("\t${intensity.name} = ${intensity.value}\n")
27 | return sampleValue.toString()
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/ota/ImageInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.ota
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class ImageInfo(
16 | val flashLB: FeatureField,
17 | val flashUB: FeatureField,
18 | val protocolVersionMajor: FeatureField,
19 | val protocolVersionMinor: FeatureField
20 | ) : Loggable {
21 | override val logHeader: String =
22 | "${flashLB.logHeader}, ${flashUB.logHeader}, ${protocolVersionMajor.logHeader}, ${protocolVersionMinor.logHeader}"
23 |
24 | override val logValue: String =
25 | "${flashLB.logValue}, ${flashUB.logValue}, ${protocolVersionMajor.logValue}, ${protocolVersionMinor.logValue}"
26 |
27 | override val logDoubleValues: List = listOf()
28 |
29 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/ota/nrg/request/ImageTUUpload.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.ota.nrg.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.ota.nrg.NewImageTUContentFeature
12 | import com.st.blue_sdk.features.ota.nrg.NewImageTUContentFeature.Companion.UPLOAD_COMMAND
13 |
14 | class ImageTUUpload(
15 | feature: NewImageTUContentFeature,
16 | val payload: ByteArray
17 | ) : FeatureCommand(feature, commandId = UPLOAD_COMMAND)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/ota/nrg/request/WriteNewImageParameter.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.ota.nrg.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.ota.nrg.NewImageFeature
12 |
13 | class WriteNewImageParameter(
14 | feature: NewImageFeature,
15 | val otaAckEvery: Byte,
16 | val imageSize: Long,
17 | val baseAddress: Long
18 | ) : FeatureCommand(feature = feature, commandId = NewImageFeature.SEND_PARAMETER)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/ota/nrg/response/ImageTUContentInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.ota.nrg.response
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | class ImageTUContentInfo(
16 | val expectedWriteLength: FeatureField
17 | ) : Loggable {
18 |
19 | override val logHeader: String
20 | get() = expectedWriteLength.logHeader
21 |
22 | override val logValue: String
23 | get() = expectedWriteLength.logValue
24 |
25 | override val logDoubleValues: List = listOf()
26 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/ota/nrg/response/NewImageInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.ota.nrg.response
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class NewImageInfo(
16 | val otaAckEvery: FeatureField,
17 | val imageSize: FeatureField,
18 | val baseAddress: FeatureField
19 | ) : Loggable {
20 |
21 | override val logHeader: String =
22 | "${otaAckEvery.logHeader}, ${imageSize.logHeader}, ${baseAddress.logHeader}"
23 |
24 | override val logValue: String =
25 | "${otaAckEvery.logValue}, ${imageSize.logValue}, ${baseAddress.logValue}"
26 |
27 | override val logDoubleValues: List = listOf()
28 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/ota/stm32wb/requests/CancelUpload.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.ota.stm32wb.requests
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureCommand
12 | import com.st.blue_sdk.features.ota.stm32wb.OTAControl
13 |
14 | class CancelUpload(feature: Feature<*>, commandId: Byte = OTAControl.CANCEL_COMMAND) :
15 | FeatureCommand(feature, commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/ota/stm32wb/requests/FinishUpload.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.ota.stm32wb.requests
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureCommand
12 | import com.st.blue_sdk.features.ota.stm32wb.OTAControl.Companion.UPLOAD_FINISHED_COMMAND
13 |
14 | class FinishUpload(feature: Feature<*>, commandId: Byte = UPLOAD_FINISHED_COMMAND) :
15 | FeatureCommand(feature, commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/ota/stm32wb/requests/RebootToOTAMode.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.ota.stm32wb.requests
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureCommand
12 | import com.st.blue_sdk.features.ota.stm32wb.OTAReboot.Companion.REBOOT_OTA_MODE
13 |
14 | class RebootToOTAMode(
15 | feature: Feature<*>,
16 | commandId: Byte = REBOOT_OTA_MODE,
17 | val sectorOffset: Byte,
18 | val numSector: Byte
19 | ) : FeatureCommand(feature, commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/ota/stm32wb/requests/StartUpload.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.ota.stm32wb.requests
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureCommand
12 |
13 | class StartUpload(feature: Feature<*>, commandId: Byte, val address: Long, val nbSectorsToErase: Long?) :
14 | FeatureCommand(feature, commandId) {
15 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/ota/stm32wb/requests/StopUpload.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.ota.stm32wb.requests
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureCommand
12 | import com.st.blue_sdk.features.ota.stm32wb.OTAControl.Companion.STOP_COMMAND
13 |
14 | class StopUpload(feature: Feature<*>, commandId: Byte = STOP_COMMAND) :
15 | FeatureCommand(feature, commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/ota/stm32wb/requests/UploadOTAData.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.ota.stm32wb.requests
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureCommand
12 |
13 | class UploadOTAData(feature: Feature<*>, commandId: Byte, val payload: ByteArray) :
14 | FeatureCommand(feature, commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/ota/stm32wb/response/WillRebootInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.ota.stm32wb.response
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureResponse
12 | import com.st.blue_sdk.logger.Loggable
13 |
14 | class WillRebootInfo(feature: Feature<*>, commandId: Byte, val infoType: WillRebootInfoType) :
15 | FeatureResponse(feature, commandId), Loggable {
16 |
17 | override val logHeader: String = ""
18 |
19 | override val logValue: String = ""
20 |
21 | override val logDoubleValues: List = listOf()
22 | }
23 |
24 | enum class WillRebootInfoType {
25 | REBOOT,
26 | READY_TO_RECEIVE_FILE,
27 | ERROR_NO_FREE,
28 | OTHER
29 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/pressure/PressureInfo.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.pressure
9 |
10 | import com.st.blue_sdk.features.FeatureField
11 | import com.st.blue_sdk.logger.Loggable
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class PressureInfo(
16 | val pressure: FeatureField
17 | ) : Loggable {
18 | override val logHeader: String = pressure.logHeader
19 |
20 | override val logValue: String = pressure.logValue
21 |
22 | override val logDoubleValues: List = listOf(pressure.value.toDouble())
23 |
24 | override fun toString(): String {
25 | val sampleValue = StringBuilder()
26 | sampleValue.append("\t${pressure.name} = ${pressure.value} ${pressure.unit}\n")
27 | return sampleValue.toString()
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/remote/switch/ChangeRemoteSwitchStatusCommand.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.remote.switch
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureCommand
12 | import com.st.blue_sdk.features.remote.switch.RemoteSwitch.Companion.SET_REMOTE_SWITCH_COMMAND
13 |
14 | class ChangeRemoteSwitchStatusCommand(
15 | feature: Feature<*>,
16 | commandId: Byte = SET_REMOTE_SWITCH_COMMAND,
17 | val newStatus: Byte,
18 | val nodeId: Int
19 | ) : FeatureCommand(feature, commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/sensor_fusion/Quaternion.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.sensor_fusion
9 |
10 | import kotlinx.serialization.Serializable
11 | import kotlin.math.sqrt
12 |
13 | @Serializable
14 | data class Quaternion(
15 | val timeStamp: Long,
16 | val qi: Float,
17 | val qj: Float,
18 | val qk: Float,
19 | val qs: Float
20 | ) {
21 |
22 | override fun toString(): String {
23 | return "\tTS= $timeStamp\n\t\tqi = $qi\n\t\tqj = $qj\n\t\tqk = $qk\n\t\tqs = $qs\n"
24 | }
25 |
26 | companion object {
27 | fun getQs(qi: Float, qj: Float, qk: Float): Float {
28 | val t = 1 - (qi * qi + qj * qj + qk * qk)
29 | return if (t > 0) sqrt(t) else 0f
30 | }
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/switchfeature/request/SwitchOff.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.switchfeature.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.switchfeature.SwitchFeature
12 |
13 | class SwitchOff(feature: SwitchFeature) :
14 | FeatureCommand(feature = feature, commandId = SwitchFeature.COMMAND_SWITCH_OFF)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/switchfeature/request/SwitchOn.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.switchfeature.request
9 |
10 | import com.st.blue_sdk.features.FeatureCommand
11 | import com.st.blue_sdk.features.switchfeature.SwitchFeature
12 |
13 | class SwitchOn(feature: SwitchFeature) :
14 | FeatureCommand(feature = feature, commandId = SwitchFeature.COMMAND_SWITCH_ON)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/features/switchfeature/response/SwitchOnOffResponse.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.features.switchfeature.response
9 |
10 | import com.st.blue_sdk.features.FeatureResponse
11 | import com.st.blue_sdk.features.switchfeature.SwitchFeature
12 | import com.st.blue_sdk.features.switchfeature.SwitchStatusType
13 |
14 | class SwitchOnOffResponse(feature: SwitchFeature, commandId: Byte, val status: SwitchStatusType) :
15 | FeatureResponse(feature = feature, commandId = commandId)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/logger/Loggable.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.logger
9 |
10 | interface Loggable {
11 | val logHeader: String
12 |
13 | val logValue: String
14 |
15 | val logDoubleValues: List
16 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/logger/Logger.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.logger
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureUpdate
12 | import com.st.blue_sdk.models.Node
13 |
14 | interface Logger {
15 |
16 | var isEnabled: Boolean
17 |
18 | val id: String
19 |
20 | fun log(node: Node, feature: Feature<*>, update: FeatureUpdate<*>): Boolean
21 |
22 | fun clear()
23 | }
24 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/logger/db_logger/db/LoggerDB.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.logger.db_logger.db
9 |
10 | import androidx.room.Database
11 | import androidx.room.RoomDatabase
12 | import androidx.room.TypeConverters
13 | import com.st.blue_sdk.logger.db_logger.db.converters.DateConverter
14 | import com.st.blue_sdk.logger.db_logger.db.model.FeatureLog
15 | import com.st.blue_sdk.logger.db_logger.db.model.FeatureUpdateLog
16 |
17 | @Database(
18 | version = 1,
19 | exportSchema = true,
20 | entities = [
21 | FeatureLog::class,
22 | FeatureUpdateLog::class
23 | ]
24 | )
25 | @TypeConverters(DateConverter::class)
26 | abstract class LoggerDB : RoomDatabase() {
27 | abstract fun loggerDao(): LoggerDao
28 | }
29 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/logger/db_logger/db/LoggerDao.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.logger.db_logger.db
9 |
10 | import androidx.room.Dao
11 | import androidx.room.Insert
12 | import androidx.room.OnConflictStrategy
13 | import com.st.blue_sdk.logger.db_logger.db.model.FeatureLog
14 | import com.st.blue_sdk.logger.db_logger.db.model.FeatureUpdateLog
15 |
16 | @Dao
17 | interface LoggerDao {
18 |
19 | @Insert(onConflict = OnConflictStrategy.REPLACE)
20 | fun addLog(featureLog: FeatureLog)
21 |
22 | @Insert(onConflict = OnConflictStrategy.REPLACE)
23 | fun addLog(featureUpdateLog: FeatureUpdateLog)
24 | }
25 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/logger/db_logger/db/converters/DateConverter.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.logger.db_logger.db.converters
9 |
10 | import androidx.room.TypeConverter
11 | import java.text.SimpleDateFormat
12 | import java.util.*
13 |
14 | class DateConverter {
15 | companion object {
16 | const val DATE_FORMAT = "dd/MM/yyyy HH:mm:ss.SSS"
17 | }
18 |
19 | @TypeConverter
20 | fun fromDate(value: Date): String {
21 | val formatter = SimpleDateFormat(DATE_FORMAT, Locale.getDefault())
22 | return formatter.format(value)
23 | }
24 |
25 | @TypeConverter
26 | fun toDate(value: String): Date {
27 | val formatter = SimpleDateFormat(DATE_FORMAT, Locale.getDefault())
28 | return formatter.parse(value)
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/logger/db_logger/db/model/FeatureLog.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.logger.db_logger.db.model
9 |
10 | import androidx.room.Entity
11 | import androidx.room.PrimaryKey
12 | import java.util.*
13 |
14 | @Entity
15 | data class FeatureLog(
16 | val nodeName: String,
17 | val featureName: String,
18 | val timestamp: Date
19 | ) {
20 |
21 | @PrimaryKey
22 | var id: Long = nodeName.hashCode() + featureName.hashCode() + timestamp.time
23 | }
24 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/logger/db_logger/db/model/FeatureLogWithUpdates.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.logger.db_logger.db.model
9 |
10 | import androidx.room.Embedded
11 | import androidx.room.Relation
12 |
13 | data class FeatureLogWithUpdates(
14 | @Embedded
15 | val featureLog: FeatureLog,
16 | @Relation(
17 | parentColumn = "id",
18 | entityColumn = "featureLogId"
19 | )
20 | val featureUpdateLog: List
21 | )
22 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/logger/db_logger/db/model/FeatureUpdateLog.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.logger.db_logger.db.model
9 |
10 | import androidx.room.Entity
11 | import androidx.room.PrimaryKey
12 | import java.util.*
13 |
14 | @Entity
15 | data class FeatureUpdateLog(
16 | val featureLogId: Long,
17 | val timestamp: Date,
18 | val hostTimestamp: Long,
19 | val data: String,
20 | val rawData: String
21 | ) {
22 | @PrimaryKey(autoGenerate = true)
23 | var id: Long = 0
24 | }
25 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/models/BleNotification.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.models
9 |
10 | import android.bluetooth.BluetoothGattCharacteristic
11 |
12 | data class BleNotification(val characteristic: BluetoothGattCharacteristic, val data: ByteArray) {
13 |
14 | override fun equals(other: Any?): Boolean {
15 | if (this === other) return true
16 | if (javaClass != other?.javaClass) return false
17 |
18 | other as BleNotification
19 |
20 | if (!data.contentEquals(other.data)) return false
21 |
22 | return true
23 | }
24 |
25 | override fun hashCode(): Int {
26 | return data.contentHashCode()
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/models/ChunkProgress.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.models
9 |
10 | data class ChunkProgress(
11 | val total: Int = 100,
12 | val current: Int = 0
13 | )
14 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/models/Field.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.models;
9 |
10 | data class Field(
11 | val unit: String,
12 | val name: String,
13 | val type: Type,
14 | val max: Number,
15 | val min: Number,
16 | val toPlot: Boolean = true
17 | ) {
18 | enum class Type {
19 | Float,
20 | Int64,
21 | UInt32,
22 | Int32,
23 | UInt16,
24 | Int16,
25 | UInt8,
26 | Int8,
27 | ByteArray
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/models/NodeState.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.models
9 |
10 |
11 | /** State of the node */
12 | enum class NodeState {
13 |
14 | /** we open a connection with the node */
15 | Connecting,
16 |
17 | /** we are connected with the node but services are yet to be discovered*/
18 | Connected,
19 |
20 | /** Services has been discovered but features are not yet processed*/
21 | ServicesDiscovered,
22 |
23 | /** connected with the node and services are discovered. User can use the board */
24 | Ready,
25 |
26 | /** we are closing the node connection */
27 | Disconnecting,
28 |
29 | /** connection with the board closed */
30 | Disconnected
31 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/models/OTAMemoryAddress.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.models
9 |
10 | data class OTAMemoryAddress(val min: Long, val max: Long, val sectorSize: Long)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/models/OTAMemoryLayout.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.models
9 |
10 | data class OTAMemoryLayout(
11 | val firstSector: Short,
12 | val nSector: Short,
13 | val sectorSize: Short
14 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/models/Sensor.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.models
9 |
10 | import kotlinx.serialization.Serializable
11 |
12 | @Serializable
13 | data class Sensor(
14 | val id: Int,
15 | val name: String,
16 | val sensorDescriptor: SensorDescriptor,
17 | val sensorStatus: SensorStatus
18 | ) : Comparable {
19 | override fun compareTo(other: Sensor): Int = id - other.id
20 |
21 | fun getSubSensorStatusForId(id: Int): SubSensorStatus? {
22 | val index = sensorDescriptor.subSensorDescriptors.indexOfFirst { it.id == id }
23 | return if (index >= 0) {
24 | sensorStatus.subSensorStatusList[index]
25 | } else {
26 | null
27 | }
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/models/SensorDescriptor.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.models
9 |
10 | import kotlinx.serialization.Serializable
11 |
12 | @Serializable
13 | data class SensorDescriptor(
14 | val subSensorDescriptors: List
15 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/models/SubSensorDescriptor.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.models
9 |
10 | import com.st.blue_sdk.board_catalog.models.SensorType
11 | import kotlinx.serialization.SerialName
12 | import kotlinx.serialization.Serializable
13 |
14 | @Serializable
15 | data class SubSensorDescriptor(
16 | val id: Int,
17 | val sensorType: SensorType,
18 | val dimensions: Int,
19 | val dimensionsLabel: List,
20 | val unit: String?,
21 | val dataType: String?,
22 | @SerialName("FS") val fs: List?,
23 | @SerialName("ODR") val odr: List?,
24 | val samplesPerTs: SamplesPerTs
25 | )
26 |
27 | @Serializable
28 | data class SamplesPerTs(
29 | val min: Int,
30 | val max: Int,
31 | val dataType: String
32 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/models/SubSensorStatus.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.models
9 |
10 | import kotlinx.serialization.SerialName
11 | import kotlinx.serialization.Serializable
12 |
13 | @Serializable
14 | data class SubSensorStatus(
15 | val isActive: Boolean,
16 | @SerialName("ODR") val odr: Double?,
17 | @SerialName("ODRMeasured") val odrMeasured: Double?,
18 | val initialOffset: Double?,
19 | val samplesPerTs: Int,
20 | @SerialName("FS") val fs: Double?,
21 | val sensitivity: Double?,
22 | val usbDataPacketSize: Int,
23 | val sdWriteBufferSize: Int,
24 | val wifiDataPacketSize: Int,
25 | val comChannelNumber: Int,
26 | val ucfLoaded: Boolean,
27 | //var paramsLocked: Boolean = false
28 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/NodeServerConsumer.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services
9 |
10 | import com.st.blue_sdk.bt.server.NodeServer
11 |
12 | interface NodeServerConsumer {
13 |
14 | fun getNodeServer(nodeId: String): NodeServer?
15 |
16 | fun getNodeServers(): List
17 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/NodeServerProducer.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services
9 |
10 | import com.st.blue_sdk.bt.server.NodeServer
11 | import com.st.blue_sdk.features.exported.ExportedFeature
12 | import com.st.blue_sdk.models.Node
13 | import java.util.*
14 |
15 | interface NodeServerProducer {
16 |
17 | fun createServer(
18 | node: Node,
19 | exportedServicesWithFeatures: Map>
20 | ): NodeServer
21 |
22 | fun removeServer(nodeId: String)
23 |
24 | fun clear()
25 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/NodeServiceConsumer.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services
9 |
10 | import com.st.blue_sdk.NodeService
11 |
12 | interface NodeServiceConsumer {
13 |
14 | fun getNodeService(nodeId: String): NodeService?
15 |
16 | fun getNodeServices(): List
17 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/NodeServiceProducer.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services
9 |
10 | import android.bluetooth.le.ScanResult
11 | import com.st.blue_sdk.NodeService
12 | import com.st.blue_sdk.bt.advertise.BleAdvertiseInfo
13 |
14 | interface NodeServiceProducer {
15 |
16 | fun createService(scanResult: ScanResult, advertiseInfo: BleAdvertiseInfo): NodeService
17 |
18 | fun removeService(nodeId: String)
19 |
20 | fun clear()
21 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/audio/AudioExtensions.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.audio
9 |
10 | import java.nio.ByteBuffer
11 |
12 | fun ShortArray.toByteArray(): ByteArray {
13 | val buffer = ByteBuffer.allocate(2 * this.size)
14 | this.forEach { shortValue ->
15 | val high: Byte = (shortValue.toInt() shr 8).toByte()
16 | val low: Byte = (shortValue.toInt() and 0xFF).toByte()
17 | buffer.put(low)
18 | buffer.put(high)
19 | }
20 | return buffer.array()
21 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/audio/codec/AudioCodecManager.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.audio.codec
9 |
10 | import com.st.blue_sdk.features.FeatureUpdate
11 | import kotlinx.coroutines.flow.Flow
12 |
13 | interface AudioCodecManager {
14 |
15 | val type: CodecType
16 |
17 | val codecName: String
18 |
19 | val channels: Int
20 |
21 | val samplingFreq: Int
22 |
23 | val isAudioEnabled: Boolean
24 |
25 | suspend fun init(configFlow: Flow>): Boolean
26 |
27 | fun enable(enable: Boolean)
28 |
29 | fun setEncodeParams(params: EncodeParams)
30 |
31 | fun getDecodeParams(): DecodeParams
32 |
33 | fun encode(data: ShortArray): ByteArray
34 |
35 | fun decode(data: ByteArray): ShortArray
36 |
37 | fun reset()
38 |
39 | fun destroy()
40 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/audio/codec/CodecType.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.audio.codec
9 |
10 | enum class CodecType {
11 | OPUS,
12 | ADPCM
13 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/audio/codec/DecodeParams.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.audio.codec
9 |
10 | interface DecodeParams {
11 |
12 | var samplingFreq: Int
13 |
14 | var channels: Int
15 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/audio/codec/EncodeParams.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.audio.codec
9 |
10 | interface EncodeParams {
11 | val frameSize: Int
12 |
13 | val samplingFreq: Int
14 |
15 | val channels: Int
16 |
17 | val frameSizePCM: Int
18 |
19 | val application: Int
20 |
21 | fun bitRate(isLe2MPhySupported: Boolean): Int =
22 | if (isLe2MPhySupported) highBitRate else lowBitRate
23 |
24 | val highBitRate: Int
25 |
26 | val lowBitRate: Int
27 |
28 | val isVbr: Boolean
29 |
30 | val complexity: Int
31 | }
32 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/audio/codec/adpcm/ADPCMParams.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.audio.codec.adpcm
9 |
10 | import com.st.blue_sdk.services.audio.codec.DecodeParams
11 |
12 | data class ADPCMParams(
13 | override var samplingFreq: Int,
14 | override var channels: Int,
15 | val index: Short,
16 | val predSample: Int,
17 | ) : DecodeParams
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/audio/codec/factory/AudioCodecManagerProvider.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.audio.codec.factory
9 |
10 | import com.st.blue_sdk.services.audio.codec.AudioCodecManager
11 | import com.st.blue_sdk.services.audio.codec.CodecType
12 |
13 | interface AudioCodecManagerProvider {
14 |
15 | fun createAudioCodecManager(
16 | nodeId: String,
17 | type: CodecType,
18 | isLe2MPhySupported: Boolean
19 | ): AudioCodecManager
20 |
21 | fun getAudioCodecManager(nodeId: String): AudioCodecManager?
22 |
23 | fun removeAudioCodecManager(nodeId: String): Boolean
24 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/audio/codec/opus/OpusParams.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.audio.codec.opus
9 |
10 | import com.st.blue_sdk.features.extended.audio.opus.OPUS_DEC_CHANNELS
11 | import com.st.blue_sdk.features.extended.audio.opus.OPUS_DEC_MS
12 | import com.st.blue_sdk.features.extended.audio.opus.OPUS_DEC_SAMPLING_FREQ
13 | import com.st.blue_sdk.services.audio.codec.DecodeParams
14 |
15 | data class OpusParams(
16 | val frameSize: Float,
17 | override var samplingFreq: Int,
18 | override var channels: Int
19 | ) : DecodeParams {
20 | companion object {
21 | fun getDefault() = OpusParams(
22 | frameSize = OPUS_DEC_MS,
23 | samplingFreq = OPUS_DEC_SAMPLING_FREQ,
24 | channels = OPUS_DEC_CHANNELS,
25 | )
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/audio/codec/opus/OpusParamsFullBand.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.audio.codec.opus
9 |
10 | import com.st.blue_sdk.services.audio.codec.EncodeParams
11 |
12 | class OpusParamsFullBand : EncodeParams {
13 | override val frameSize: Int = 300
14 | override val samplingFreq: Int = 48000
15 | override val channels: Int = 2
16 | override val frameSizePCM: Int = 1920
17 | override val application: Int = 2049
18 | override val highBitRate: Int = 192000
19 | override val lowBitRate: Int = 96000
20 | override val isVbr: Boolean = false
21 | override val complexity: Int = 4
22 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/audio/codec/opus/OpusParamsFullDuplex.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.audio.codec.opus
9 |
10 | import com.st.blue_sdk.services.audio.codec.EncodeParams
11 |
12 | class OpusParamsFullDuplex : EncodeParams {
13 | override val frameSize: Int = 300
14 | override val samplingFreq: Int = 16000
15 | override val channels: Int = 1
16 | override val frameSizePCM: Int = 320
17 | override val application: Int = 2048
18 | override val highBitRate: Int = 24000
19 | override val lowBitRate: Int = 24000
20 | override val isVbr: Boolean = false
21 | override val complexity: Int = 0
22 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/calibration/CalibrationService.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 |
9 | package com.st.blue_sdk.services.calibration
10 |
11 | import com.st.blue_sdk.features.CalibrationStatus
12 | import com.st.blue_sdk.features.Feature
13 |
14 | interface CalibrationService {
15 |
16 | suspend fun startCalibration(feature: Feature<*>, nodeId: String): CalibrationStatus
17 |
18 | suspend fun getCalibration(feature: Feature<*>, nodeId: String): CalibrationStatus
19 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/config/ConfigControlService.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.config
9 |
10 | import com.st.blue_sdk.features.Feature
11 | import com.st.blue_sdk.features.FeatureCommand
12 | import com.st.blue_sdk.features.FeatureResponse
13 | import kotlinx.coroutines.flow.Flow
14 |
15 | interface ConfigControlService {
16 |
17 | val configControlUpdates: Flow
18 |
19 | suspend fun init()
20 |
21 | fun hasBleConfigService(): Boolean
22 |
23 | suspend fun writeFeatureCommand(
24 | featureCommand: FeatureCommand,
25 | feature: Feature<*>,
26 | writeTimeout: Long = 1000,
27 | responseTimeout: Long = 2000,
28 | retry: Int = 0,
29 | retryDelay: Long = 250
30 | ): FeatureResponse?
31 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/debug/DebugMessage.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.debug
9 |
10 | data class DebugMessage(val payload: String, val isError: Boolean)
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/fw_version/FwVersion.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.fw_version
9 |
10 | import kotlinx.serialization.Serializable
11 |
12 | @Serializable
13 | abstract class FwVersion(
14 | var majorVersion: Int = 1,
15 | var minorVersion: Int = 0,
16 | var patchVersion: Int = 0
17 | ) {
18 | override fun toString(): String = "$majorVersion.$minorVersion.$patchVersion"
19 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/ota/FirmwareType.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.ota
9 |
10 | enum class FirmwareType {
11 | BLE_FW,
12 | BOARD_FW
13 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/ota/FwConsole.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.ota
9 |
10 | interface FwConsole {
11 |
12 | fun launchFirmwareUpgrade(
13 | nodeId: String,
14 | fwType: FirmwareType,
15 | fileDescriptor: FwFileDescriptor,
16 | params: FwUpgradeParams? = null,
17 | fwUpdateListener: FwUpdateListener
18 | ): Boolean
19 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/ota/FwUpgradeParams.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.ota
9 |
10 | sealed class FwUpgradeParams {
11 | class Stm32WbParams(
12 | val offset: Long,
13 | val sectorCount: Byte,
14 | val address: Long
15 | ) : FwUpgradeParams()
16 | }
17 |
18 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/ota/OtaService.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.ota
9 |
10 | import com.st.blue_sdk.services.fw_version.FwVersionBoard
11 |
12 | interface OtaService {
13 |
14 | suspend fun updateFirmware(nodeId: String): FwConsole?
15 |
16 | suspend fun getFwVersion(nodeId: String): FwVersionBoard?
17 |
18 | fun getFwUpdateStrategy(nodeId: String): UpgradeStrategy
19 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/ota/UpgradeStrategy.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.ota
9 |
10 | enum class UpgradeStrategy {
11 | DEBUG_CONSOLE,
12 | CHARACTERISTIC,
13 | NRG,
14 | UNKNOWN
15 | }
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/services/ota/debug/FwUpgradeConfiguration.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.services.ota.debug
9 |
10 | data class FwUpgradeConfiguration(
11 | val payloadSize: Int,
12 | val
13 | packageDelay: Long,
14 | val notifyInterval: Int
15 | )
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/utils/ContextExt.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.utils
9 |
10 | import android.Manifest.permission.BLUETOOTH
11 | import android.content.Context
12 | import android.content.pm.PackageManager
13 | import androidx.core.content.ContextCompat
14 |
15 | fun Context.hasBluetoothPermission(): Boolean =
16 | ContextCompat.checkSelfPermission(this, BLUETOOTH) == PackageManager.PERMISSION_GRANTED
17 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/java/com/st/blue_sdk/utils/UnwrapTimestamp.kt:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (c) 2022(-0001) STMicroelectronics.
3 | * All rights reserved.
4 | * This software is licensed under terms that can be found in the LICENSE file in
5 | * the root directory of this software component.
6 | * If no LICENSE file comes with this software, it is provided AS-IS.
7 | */
8 | package com.st.blue_sdk.utils
9 |
10 | class UnwrapTimestamp {
11 |
12 | companion object {
13 | private const val NEAR_TO_END_TH = (1 shl 16) - 100
14 | }
15 |
16 | private var reset = 0L
17 | private var lastTimestamp = 0L
18 |
19 | fun next() = unwrap(lastTimestamp + 1)
20 |
21 | fun unwrap(ts: Long): Long {
22 | if (lastTimestamp > NEAR_TO_END_TH && lastTimestamp > ts)
23 | reset++
24 | lastTimestamp = ts
25 |
26 | return reset * (1 shl 16) + ts
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/st_blue_sdk/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
8 |
9 |
10 |
11 | An error occurred while scanning BLE devices
12 |
--------------------------------------------------------------------------------
/st_opus/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 | /.cxx
--------------------------------------------------------------------------------
/st_opus/consumer-rules.pro:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/st_opus/consumer-rules.pro
--------------------------------------------------------------------------------
/st_opus/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # You can control the set of applied configuration files using the
3 | # proguardFiles setting in build.gradle.kts.
4 | #
5 | # For more details, see
6 | # http://developer.android.com/guide/developing/tools/proguard.html
7 |
8 | # If your project uses WebView with JS, uncomment the following
9 | # and specify the fully qualified class name to the JavaScript interface
10 | # class:
11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12 | # public *;
13 | #}
14 |
15 | # Uncomment this to preserve the line number information for
16 | # debugging stack traces.
17 | #-keepattributes SourceFile,LineNumberTable
18 |
19 | # If you keep the line number information, uncomment this to
20 | # hide the original source file name.
21 | #-renamesourcefileattribute SourceFile
22 |
--------------------------------------------------------------------------------
/st_opus/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
8 |
--------------------------------------------------------------------------------
/st_opus/src/main/jniLibs/arm64-v8a/libopusUser.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/st_opus/src/main/jniLibs/arm64-v8a/libopusUser.so
--------------------------------------------------------------------------------
/st_opus/src/main/jniLibs/armeabi-v7a/libopusUser.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/st_opus/src/main/jniLibs/armeabi-v7a/libopusUser.so
--------------------------------------------------------------------------------
/st_opus/src/main/jniLibs/x86/libopusUser.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/st_opus/src/main/jniLibs/x86/libopusUser.so
--------------------------------------------------------------------------------
/st_opus/src/main/jniLibs/x86_64/libopusUser.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/st_opus/src/main/jniLibs/x86_64/libopusUser.so
--------------------------------------------------------------------------------
/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STMicroelectronics/BlueSTSDK_Android/c3826b3544614c239299454e1ac8683358a80e09/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Wed Feb 22 13:21:53 CET 2023
2 | distributionBase=GRADLE_USER_HOME
3 | distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-bin.zip
4 | distributionPath=wrapper/dists
5 | zipStorePath=wrapper/dists
6 | zipStoreBase=GRADLE_USER_HOME
7 |
--------------------------------------------------------------------------------