blob: 28ef660c8d2ae8e0d77146fc956d18efac93f8cb [file] [log] [blame]
Eric Laurent27ef4d82016-10-14 15:46:06 -07001/*
2 * Copyright (C) 2016 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
Mikhail Naganov10548292016-10-31 10:39:47 -070017#define LOG_TAG "audiohalservice"
Eric Laurent27ef4d82016-10-14 15:46:06 -070018
Mikhail Naganov10548292016-10-31 10:39:47 -070019#include <hidl/LegacySupport.h>
20#include <android/hardware/audio/2.0/IDevicesFactory.h>
21#include <android/hardware/audio/effect/2.0/IEffectsFactory.h>
Eric Laurent27ef4d82016-10-14 15:46:06 -070022#include <android/hardware/soundtrigger/2.0/ISoundTriggerHw.h>
Eric Laurenta1745882016-11-21 10:41:22 -080023#include <android/hardware/broadcastradio/1.0/IBroadcastRadioFactory.h>
Eric Laurent27ef4d82016-10-14 15:46:06 -070024
25using android::hardware::IPCThreadState;
26using android::hardware::ProcessState;
Mikhail Naganov10548292016-10-31 10:39:47 -070027using android::hardware::audio::effect::V2_0::IEffectsFactory;
28using android::hardware::audio::V2_0::IDevicesFactory;
Eric Laurent27ef4d82016-10-14 15:46:06 -070029using android::hardware::soundtrigger::V2_0::ISoundTriggerHw;
Mikhail Naganov10548292016-10-31 10:39:47 -070030using android::hardware::registerPassthroughServiceImplementation;
Eric Laurenta1745882016-11-21 10:41:22 -080031using android::hardware::broadcastradio::V1_0::IBroadcastRadioFactory;
Eric Laurent27ef4d82016-10-14 15:46:06 -070032
33int main(int /* argc */, char* /* argv */ []) {
Mikhail Naganov10548292016-10-31 10:39:47 -070034 registerPassthroughServiceImplementation<IDevicesFactory>("audio_devices_factory");
35 registerPassthroughServiceImplementation<IEffectsFactory>("audio_effects_factory");
36 registerPassthroughServiceImplementation<ISoundTriggerHw>("sound_trigger.primary");
Eric Laurenta1745882016-11-21 10:41:22 -080037 registerPassthroughServiceImplementation<IBroadcastRadioFactory>("broadcastradio");
Mikhail Naganov10548292016-10-31 10:39:47 -070038 return android::hardware::launchRpcServer(16);
Eric Laurent27ef4d82016-10-14 15:46:06 -070039}