blob: 7c151eb1b8c49b78e5ada4764e719431ea5b2cb3 [file] [edit]
edition = "2023";
package milotic_tlbmc;
import "entity_common_config.proto";
import "hal_common_config.proto";
import "sensor_instance_properties.proto";
message AdcChannel {
// The name of the file that contains the ADC reading for this channel.
string file_name = 1;
// The threshold for the raw signal voltage value to be considered as
// high/low virtual GPIO value.
int64 gpio_threshold_millivolts = 2;
// Sensor instance specific properties.
SensorInstanceProperties instance_properties = 3;
}
enum AdcSensorType {
ADC_SENSOR_TYPE0_UNKNOWN = 0;
ADC_SENSOR_TYPE1_TLA2024 = 1;
ADC_SENSOR_TYPE2_MAX11611 = 2;
ADC_SENSOR_TYPE3_ADS1015 = 3;
ADC_SENSOR_TYPE4_MAX1363 = 4;
ADC_SENSOR_TYPE5_ADS7142 = 5;
}
// Config for a set of ADC telemetry based on the iio sysfs readings.
// A single config will generate a list of sensors.
message AdcSensorConfig {
// The name of the ADC device, matching the "name" file under the device
// directory.
string device_name = 1;
// The common config for the entity.
EntityCommonConfig entity_common_config = 2;
// The channels to be collected from the ADC device.
repeated AdcChannel channels = 3;
// The common config for the HAL.
HalCommonConfig hal_common_config = 4;
// The type of the ADC sensor.
AdcSensorType type = 5;
}