Peiyong Lin | 5696075 | 2022-09-30 21:52:52 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2022 The Android Open Source Project |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | package android.hardware.thermal; |
| 18 | |
| 19 | import android.hardware.thermal.TemperatureType; |
| 20 | |
| 21 | @VintfStability |
| 22 | parcelable TemperatureThreshold { |
| 23 | /** |
| 24 | * This temperature's type. |
| 25 | */ |
| 26 | TemperatureType type; |
| 27 | /** |
| 28 | * Name of this temperature matching the Temperature struct. |
| 29 | * All temperatures of the same "type" must have a different "name", |
| 30 | * e.g., cpu0, battery. Clients use it to match Temperature struct. |
| 31 | */ |
| 32 | String name; |
| 33 | /** |
| 34 | * Hot throttling temperature constant for this temperature sensor in |
| 35 | * level defined in ThrottlingSeverity including shutdown. Throttling |
| 36 | * happens when temperature >= threshold. If not available, set to NAN. |
| 37 | * Unit is same as Temperature's value. |
| 38 | * The number of thresholds must be the same as ThrottlingSeverity#len. |
| 39 | */ |
| 40 | float[] hotThrottlingThresholds; |
| 41 | /** |
| 42 | * Cold throttling temperature constant for this temperature sensor in |
| 43 | * level defined in ThrottlingSeverity including shutdown. Throttling |
| 44 | * happens when temperature <= threshold. If not available, set to NAN. |
| 45 | * Unit is same as Temperature's value. |
| 46 | * The number of theresholds must be the same as ThrottlingSeverity#len. |
| 47 | */ |
| 48 | float[] coldThrottlingThresholds; |
| 49 | } |