Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b5fbbfe2 authored by Hridya Valsaraju's avatar Hridya Valsaraju
Browse files

Add GNSS HAL service

Bug: 31974439
Test: GPS Location available on Maps(on Angler).

Change-Id: I17ba8fab47bc25a1158089ec2b8e8cd54ec650e1
parent 441a9309
Loading
Loading
Loading
Loading
+24 −0
Original line number Diff line number Diff line
@@ -27,3 +27,27 @@ LOCAL_SHARED_LIBRARIES := \
    libhardware

include $(BUILD_SHARED_LIBRARY)

include $(CLEAR_VARS)
LOCAL_MODULE_RELATIVE_PATH := hw
LOCAL_MODULE := android.hardware.gnss@1.0-service
LOCAL_INIT_RC := android.hardware.gnss@1.0-service.rc
LOCAL_SRC_FILES := \
    service.cpp \

LOCAL_SHARED_LIBRARIES := \
    liblog \
    libcutils \
    libdl \
    libbase \
    libutils \
    libhardware_legacy \
    libhardware \

LOCAL_SHARED_LIBRARIES += \
    libhwbinder \
    libhidlbase \
    libhidltransport \
    android.hardware.gnss@1.0 \

include $(BUILD_EXECUTABLE)
+4 −0
Original line number Diff line number Diff line
service gnss_service /system/bin/hw/android.hardware.gnss@1.0-service
    class main
    user system
    group system
+12 −0
Original line number Diff line number Diff line
#define LOG_TAG "android.hardware.gnss@1.0-service"

#include <android/hardware/gnss/1.0/IGnss.h>

#include <hidl/LegacySupport.h>

using android::hardware::gnss::V1_0::IGnss;
using android::hardware::defaultPassthroughServiceImplementation;

int main() {
    return defaultPassthroughServiceImplementation<IGnss>("gnss");
}