blob: 53b8b3f153eb6863429140a0cdf9755571fbee6c [file] [log] [blame]
Jinsuk Kim91120c52014-05-08 17:12:51 +09001/*
2 * Copyright (C) 2014 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
17package android.hardware.hdmi;
18
Jinsuk Kim6d97f5b2014-06-16 11:41:42 +090019import android.hardware.hdmi.HdmiCecDeviceInfo;
20import android.hardware.hdmi.HdmiPortInfo;
Jinsuk Kim91120c52014-05-08 17:12:51 +090021import android.hardware.hdmi.IHdmiControlCallback;
Jinsuk Kim6d97f5b2014-06-16 11:41:42 +090022import android.hardware.hdmi.IHdmiDeviceEventListener;
Jinsuk Kim78d695d2014-05-13 16:36:15 +090023import android.hardware.hdmi.IHdmiHotplugEventListener;
Jinsuk Kim9c37e1f2014-07-02 08:29:26 +090024import android.hardware.hdmi.IHdmiInputChangeListener;
Jungshik Janga6b2a7a2014-07-16 18:04:49 +090025import android.hardware.hdmi.IHdmiRecordRequestListener;
Jungshik Jangea67c182014-06-19 22:19:20 +090026import android.hardware.hdmi.IHdmiSystemAudioModeChangeListener;
Jinsuk Kim119160a2014-07-07 18:48:10 +090027import android.hardware.hdmi.IHdmiVendorCommandListener;
Jinsuk Kim91120c52014-05-08 17:12:51 +090028
Jinsuk Kim6d97f5b2014-06-16 11:41:42 +090029import java.util.List;
30
Jinsuk Kim91120c52014-05-08 17:12:51 +090031/**
32 * Binder interface that clients running in the application process
33 * will use to perform HDMI-CEC features by communicating with other devices
34 * on the bus.
35 *
36 * @hide
37 */
38interface IHdmiControlService {
Jinsuk Kim78d695d2014-05-13 16:36:15 +090039 int[] getSupportedTypes();
40 void oneTouchPlay(IHdmiControlCallback callback);
41 void queryDisplayStatus(IHdmiControlCallback callback);
42 void addHotplugEventListener(IHdmiHotplugEventListener listener);
43 void removeHotplugEventListener(IHdmiHotplugEventListener listener);
Jinsuk Kim6d97f5b2014-06-16 11:41:42 +090044 void addDeviceEventListener(IHdmiDeviceEventListener listener);
Jinsuk Kima6ce7702014-05-11 06:54:49 +090045 void deviceSelect(int logicalAddress, IHdmiControlCallback callback);
Jinsuk Kim6d97f5b2014-06-16 11:41:42 +090046 void portSelect(int portId, IHdmiControlCallback callback);
Jinsuk Kimc068bb52014-07-07 16:59:20 +090047 void sendKeyEvent(int deviceType, int keyCode, boolean isPressed);
Jinsuk Kim6d97f5b2014-06-16 11:41:42 +090048 List<HdmiPortInfo> getPortInfo();
Jungshik Jangea67c182014-06-19 22:19:20 +090049 boolean canChangeSystemAudioMode();
50 boolean getSystemAudioMode();
51 void setSystemAudioMode(boolean enabled, IHdmiControlCallback callback);
52 void addSystemAudioModeChangeListener(IHdmiSystemAudioModeChangeListener listener);
53 void removeSystemAudioModeChangeListener(IHdmiSystemAudioModeChangeListener listener);
Jinsuk Kim92b77cf2014-06-27 16:39:26 +090054 void setControlEnabled(boolean enabled);
Jungshik Janga13da0d2014-06-30 16:26:06 +090055 void setArcMode(boolean enabled);
Jinsuk Kim160a6e52014-07-02 06:16:36 +090056 void setOption(int option, int value);
Jinsuk Kim4d43d932014-07-03 16:43:58 +090057 void setProhibitMode(boolean enabled);
Jungshik Jangbffb0632014-07-22 16:56:52 +090058 void setSystemAudioVolume(int oldIndex, int newIndex, int maxIndex);
59 void setSystemAudioMute(boolean mute);
Jinsuk Kim9c37e1f2014-07-02 08:29:26 +090060 void setInputChangeListener(IHdmiInputChangeListener listener);
61 List<HdmiCecDeviceInfo> getInputDevices();
Jinsuk Kim119160a2014-07-07 18:48:10 +090062 void sendVendorCommand(int deviceType, int targetAddress, in byte[] params,
63 boolean hasVendorId);
64 void addVendorCommandListener(IHdmiVendorCommandListener listener, int deviceType);
Jungshik Jangbffb0632014-07-22 16:56:52 +090065 void setOneTouchRecordRequestListener(IHdmiRecordRequestListener listener);
66 void startOneTouchRecord(int recorderAddress, in byte[] recordSource);
67 void startTimerRecording(int recorderAddress, in byte[] recordSource);
Jinsuk Kim91120c52014-05-08 17:12:51 +090068}