Loading cmds/statsd/src/atoms.proto +4 −3 Original line number Diff line number Diff line Loading @@ -1943,7 +1943,8 @@ message FullBatteryCapacity { } /** * Pulls the temperature of various parts of the device, in Celsius. * Pulls the temperature of various parts of the device. * The units are tenths of a degree Celsius. Eg: 30.3C is reported as 303. * * Pulled from: * frameworks/base/cmds/statsd/src/external/ResourceThermalManagerPuller.cpp Loading @@ -1955,6 +1956,6 @@ message Temperature { // The name of the temperature source. Eg. CPU0 optional string sensor_name = 2; // Temperature in degrees C. optional float temperature_C = 3; // Temperature in tenths of a degree C. optional int32 temperature_dC = 3; } cmds/statsd/src/external/ResourceThermalManagerPuller.cpp +3 −1 Original line number Diff line number Diff line Loading @@ -120,7 +120,9 @@ bool ResourceThermalManagerPuller::PullInternal(vector<shared_ptr<LogEvent>>* da wallClockTimestampNs, elapsedTimestampNs); ptr->write((static_cast<int>(temps[i].type))); ptr->write(temps[i].name); ptr->write(temps[i].currentValue); // Convert the temperature to an int. int32_t temp = static_cast<int>(temps[i].currentValue * 10); ptr->write(temp); ptr->init(); data->push_back(ptr); } Loading Loading
cmds/statsd/src/atoms.proto +4 −3 Original line number Diff line number Diff line Loading @@ -1943,7 +1943,8 @@ message FullBatteryCapacity { } /** * Pulls the temperature of various parts of the device, in Celsius. * Pulls the temperature of various parts of the device. * The units are tenths of a degree Celsius. Eg: 30.3C is reported as 303. * * Pulled from: * frameworks/base/cmds/statsd/src/external/ResourceThermalManagerPuller.cpp Loading @@ -1955,6 +1956,6 @@ message Temperature { // The name of the temperature source. Eg. CPU0 optional string sensor_name = 2; // Temperature in degrees C. optional float temperature_C = 3; // Temperature in tenths of a degree C. optional int32 temperature_dC = 3; }
cmds/statsd/src/external/ResourceThermalManagerPuller.cpp +3 −1 Original line number Diff line number Diff line Loading @@ -120,7 +120,9 @@ bool ResourceThermalManagerPuller::PullInternal(vector<shared_ptr<LogEvent>>* da wallClockTimestampNs, elapsedTimestampNs); ptr->write((static_cast<int>(temps[i].type))); ptr->write(temps[i].name); ptr->write(temps[i].currentValue); // Convert the temperature to an int. int32_t temp = static_cast<int>(temps[i].currentValue * 10); ptr->write(temp); ptr->init(); data->push_back(ptr); } Loading