1<?xml version='1.0' encoding='utf-8'?> 2<!-- Copyright (C) 2023 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<powerPolicy version="1.0"> 18 19 <customComponents> 20 <customComponent value="1000">CUSTOM_COMPONENT_1</customComponent> 21 <customComponent value="1003">CUSTOM_COMPONENT_SPECIAL_SENSOR</customComponent> 22 <customComponent value="1002">CUSTOM_COMPONENT_AUX_INPUT</customComponent> 23 <customComponent value="500">INCORRECT_CUSTOM_COMPONENT</customComponent> 24 </customComponents> 25 26 <policyGroups> 27 <policyGroup id="basic_policy_group"> 28 <defaultPolicy state="WaitForVHAL" id="policy_id_other_on"/> 29 <defaultPolicy state="On" id="policy_id_other_untouched"/> 30 </policyGroup> 31 <policyGroup id="no_default_policy_group"> 32 <noDefaultPolicy state="WaitForVHAL"/> 33 <noDefaultPolicy state="On"/> 34 </policyGroup> 35 <policyGroup id="mixed_policy_group"> 36 <defaultPolicy state="WaitForVHAL" id="policy_id_other_on"/> 37 <noDefaultPolicy state="On"/> 38 </policyGroup> 39 </policyGroups> 40 41 <policies> 42 <policy id="expected_to_be_registered"> 43 <otherComponents behavior="on"/> 44 </policy> 45 <policy id="policy_id_other_off"> 46 <otherComponents behavior="off"/> 47 <component id="POWER_COMPONENT_AUDIO">off</component> 48 <component id="POWER_COMPONENT_DISPLAY">off</component> 49 <component id="POWER_COMPONENT_WIFI">on</component> 50 <component id="POWER_COMPONENT_VISUAL_INTERACTION">off</component> 51 <component id="CUSTOM_COMPONENT_1">off</component> 52 <component id="CUSTOM_COMPONENT_SPECIAL_SENSOR">off</component> 53 <component id="CUSTOM_COMPONENT_AUX_INPUT">on</component> 54 <component id="INCORRECT_CUSTOM_COMPONENT">on</component> 55 </policy> 56 <policy id="policy_id_other_untouched"> 57 <otherComponents behavior="untouched"/> 58 <component id="POWER_COMPONENT_AUDIO">on</component> 59 <component id="POWER_COMPONENT_DISPLAY">on</component> 60 <component id="POWER_COMPONENT_BLUETOOTH">on</component> 61 <component id="POWER_COMPONENT_WIFI">on</component> 62 <component id="POWER_COMPONENT_VOICE_INTERACTION">on</component> 63 <component id="POWER_COMPONENT_VISUAL_INTERACTION">on</component> 64 <component id="POWER_COMPONENT_TRUSTED_DEVICE_DETECTION">on</component> 65 </policy> 66 <policy id="policy_id_other_on"> 67 <otherComponents behavior="on"/> 68 <component id="POWER_COMPONENT_AUDIO">off</component> 69 <component id="POWER_COMPONENT_VOICE_INTERACTION">off</component> 70 <component id="POWER_COMPONENT_VISUAL_INTERACTION">off</component> 71 <component id="POWER_COMPONENT_TRUSTED_DEVICE_DETECTION">off</component> 72 </policy> 73 <policy id="policy_id_other_none"> 74 <component id="POWER_COMPONENT_AUDIO">off</component> 75 <component id="POWER_COMPONENT_WIFI">on</component> 76 <component id="POWER_COMPONENT_VOICE_INTERACTION">off</component> 77 <component id="POWER_COMPONENT_VISUAL_INTERACTION">off</component> 78 <component id="POWER_COMPONENT_TRUSTED_DEVICE_DETECTION">off</component> 79 </policy> 80 </policies> 81 82 <systemPolicyOverrides> 83 <policy id="system_power_policy_no_user_interaction"> 84 <component id="POWER_COMPONENT_BLUETOOTH">on</component> 85 <component id="POWER_COMPONENT_NFC">on</component> 86 <component id="POWER_COMPONENT_TRUSTED_DEVICE_DETECTION">off</component> 87 </policy> 88 </systemPolicyOverrides> 89 90</powerPolicy> 91