Loading services/tuner/TunerFrontend.cpp +10 −10 Original line number Diff line number Diff line Loading @@ -115,16 +115,6 @@ TunerFrontend::~TunerFrontend() { return mFrontend->setLnb(static_cast<TunerLnb*>(lnb.get())->getId()); } ::ndk::ScopedAStatus TunerFrontend::setLna(bool bEnable) { if (mFrontend == nullptr) { ALOGD("IFrontend is not initialized"); return ::ndk::ScopedAStatus::fromServiceSpecificError( static_cast<int32_t>(Result::UNAVAILABLE)); } return mFrontend->setLna(bEnable); } ::ndk::ScopedAStatus TunerFrontend::linkCiCamToFrontend(int32_t ciCamId, int32_t* _aidl_return) { if (mFrontend == nullptr) { ALOGD("IFrontend is not initialized"); Loading Loading @@ -174,6 +164,16 @@ TunerFrontend::~TunerFrontend() { return ::ndk::ScopedAStatus::ok(); } ::ndk::ScopedAStatus TunerFrontend::getHardwareInfo(std::string* _aidl_return) { if (mFrontend == nullptr) { ALOGD("IFrontend is not initialized"); return ::ndk::ScopedAStatus::fromServiceSpecificError( static_cast<int32_t>(Result::UNAVAILABLE)); } return mFrontend->getHardwareInfo(_aidl_return); } /////////////// FrontendCallback /////////////////////// ::ndk::ScopedAStatus TunerFrontend::FrontendCallback::onEvent(FrontendEventType frontendEventType) { ALOGV("FrontendCallback::onEvent, type=%d", frontendEventType); Loading services/tuner/TunerFrontend.h +1 −1 Original line number Diff line number Diff line Loading @@ -56,13 +56,13 @@ public: FrontendScanType in_frontendScanType) override; ::ndk::ScopedAStatus stopScan() override; ::ndk::ScopedAStatus setLnb(const shared_ptr<ITunerLnb>& in_lnb) override; ::ndk::ScopedAStatus setLna(bool in_bEnable) override; ::ndk::ScopedAStatus linkCiCamToFrontend(int32_t in_ciCamId, int32_t* _aidl_return) override; ::ndk::ScopedAStatus unlinkCiCamToFrontend(int32_t in_ciCamId) override; ::ndk::ScopedAStatus close() override; ::ndk::ScopedAStatus getStatus(const vector<FrontendStatusType>& in_statusTypes, vector<FrontendStatus>* _aidl_return) override; ::ndk::ScopedAStatus getFrontendId(int32_t* _aidl_return) override; ::ndk::ScopedAStatus getHardwareInfo(std::string* _aidl_return) override; struct FrontendCallback : public BnFrontendCallback { FrontendCallback(const shared_ptr<ITunerFrontendCallback> tunerFrontendCallback) Loading services/tuner/TunerService.cpp +10 −0 Original line number Diff line number Diff line Loading @@ -260,6 +260,16 @@ bool TunerService::hasITuner() { return ::ndk::ScopedAStatus::ok(); } ::ndk::ScopedAStatus TunerService::setLna(bool bEnable) { if (!hasITuner()) { ALOGD("get ITuner failed"); return ::ndk::ScopedAStatus::fromServiceSpecificError( static_cast<int32_t>(Result::UNAVAILABLE)); } return mTuner->setLna(bEnable); } string TunerService::addFilterToShared(const shared_ptr<TunerFilter>& sharedFilter) { Mutex::Autolock _l(mSharedFiltersLock); Loading services/tuner/TunerService.h +1 −0 Original line number Diff line number Diff line Loading @@ -76,6 +76,7 @@ public: ::ndk::ScopedAStatus openSharedFilter(const string& in_filterToken, const shared_ptr<ITunerFilterCallback>& in_cb, shared_ptr<ITunerFilter>* _aidl_return) override; ::ndk::ScopedAStatus setLna(bool in_bEnable) override; string addFilterToShared(const shared_ptr<TunerFilter>& sharedFilter); void removeSharedFilter(const shared_ptr<TunerFilter>& sharedFilter); Loading services/tuner/aidl/android/media/tv/tuner/ITunerFrontend.aidl +5 −7 Original line number Diff line number Diff line Loading @@ -68,13 +68,6 @@ interface ITunerFrontend { */ void setLnb(in ITunerLnb lnb); /** * Enable or Disable Low Noise Amplifier (LNA). * * @param bEnable enable Lna or not. */ void setLna(in boolean bEnable); /** * Link Frontend to the cicam with given id. * Loading @@ -101,4 +94,9 @@ interface ITunerFrontend { * Gets the id of the frontend. */ int getFrontendId(); /** * Request hardware information about the frontend. */ String getHardwareInfo(); } Loading
services/tuner/TunerFrontend.cpp +10 −10 Original line number Diff line number Diff line Loading @@ -115,16 +115,6 @@ TunerFrontend::~TunerFrontend() { return mFrontend->setLnb(static_cast<TunerLnb*>(lnb.get())->getId()); } ::ndk::ScopedAStatus TunerFrontend::setLna(bool bEnable) { if (mFrontend == nullptr) { ALOGD("IFrontend is not initialized"); return ::ndk::ScopedAStatus::fromServiceSpecificError( static_cast<int32_t>(Result::UNAVAILABLE)); } return mFrontend->setLna(bEnable); } ::ndk::ScopedAStatus TunerFrontend::linkCiCamToFrontend(int32_t ciCamId, int32_t* _aidl_return) { if (mFrontend == nullptr) { ALOGD("IFrontend is not initialized"); Loading Loading @@ -174,6 +164,16 @@ TunerFrontend::~TunerFrontend() { return ::ndk::ScopedAStatus::ok(); } ::ndk::ScopedAStatus TunerFrontend::getHardwareInfo(std::string* _aidl_return) { if (mFrontend == nullptr) { ALOGD("IFrontend is not initialized"); return ::ndk::ScopedAStatus::fromServiceSpecificError( static_cast<int32_t>(Result::UNAVAILABLE)); } return mFrontend->getHardwareInfo(_aidl_return); } /////////////// FrontendCallback /////////////////////// ::ndk::ScopedAStatus TunerFrontend::FrontendCallback::onEvent(FrontendEventType frontendEventType) { ALOGV("FrontendCallback::onEvent, type=%d", frontendEventType); Loading
services/tuner/TunerFrontend.h +1 −1 Original line number Diff line number Diff line Loading @@ -56,13 +56,13 @@ public: FrontendScanType in_frontendScanType) override; ::ndk::ScopedAStatus stopScan() override; ::ndk::ScopedAStatus setLnb(const shared_ptr<ITunerLnb>& in_lnb) override; ::ndk::ScopedAStatus setLna(bool in_bEnable) override; ::ndk::ScopedAStatus linkCiCamToFrontend(int32_t in_ciCamId, int32_t* _aidl_return) override; ::ndk::ScopedAStatus unlinkCiCamToFrontend(int32_t in_ciCamId) override; ::ndk::ScopedAStatus close() override; ::ndk::ScopedAStatus getStatus(const vector<FrontendStatusType>& in_statusTypes, vector<FrontendStatus>* _aidl_return) override; ::ndk::ScopedAStatus getFrontendId(int32_t* _aidl_return) override; ::ndk::ScopedAStatus getHardwareInfo(std::string* _aidl_return) override; struct FrontendCallback : public BnFrontendCallback { FrontendCallback(const shared_ptr<ITunerFrontendCallback> tunerFrontendCallback) Loading
services/tuner/TunerService.cpp +10 −0 Original line number Diff line number Diff line Loading @@ -260,6 +260,16 @@ bool TunerService::hasITuner() { return ::ndk::ScopedAStatus::ok(); } ::ndk::ScopedAStatus TunerService::setLna(bool bEnable) { if (!hasITuner()) { ALOGD("get ITuner failed"); return ::ndk::ScopedAStatus::fromServiceSpecificError( static_cast<int32_t>(Result::UNAVAILABLE)); } return mTuner->setLna(bEnable); } string TunerService::addFilterToShared(const shared_ptr<TunerFilter>& sharedFilter) { Mutex::Autolock _l(mSharedFiltersLock); Loading
services/tuner/TunerService.h +1 −0 Original line number Diff line number Diff line Loading @@ -76,6 +76,7 @@ public: ::ndk::ScopedAStatus openSharedFilter(const string& in_filterToken, const shared_ptr<ITunerFilterCallback>& in_cb, shared_ptr<ITunerFilter>* _aidl_return) override; ::ndk::ScopedAStatus setLna(bool in_bEnable) override; string addFilterToShared(const shared_ptr<TunerFilter>& sharedFilter); void removeSharedFilter(const shared_ptr<TunerFilter>& sharedFilter); Loading
services/tuner/aidl/android/media/tv/tuner/ITunerFrontend.aidl +5 −7 Original line number Diff line number Diff line Loading @@ -68,13 +68,6 @@ interface ITunerFrontend { */ void setLnb(in ITunerLnb lnb); /** * Enable or Disable Low Noise Amplifier (LNA). * * @param bEnable enable Lna or not. */ void setLna(in boolean bEnable); /** * Link Frontend to the cicam with given id. * Loading @@ -101,4 +94,9 @@ interface ITunerFrontend { * Gets the id of the frontend. */ int getFrontendId(); /** * Request hardware information about the frontend. */ String getHardwareInfo(); }