Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not receiving updated values while registering to a property #4

Open
lavanyapisini opened this issue Aug 30, 2023 · 2 comments
Open

Comments

@lavanyapisini
Copy link

I'm unable to receive the updated values of vendor property in the Android app, initially I'm getting some value when we are trying to getIntProperty for that Vendor property. We also have the code for registerCallback but not receiving the values when they are updated at VHAL layer.

@nkh-lab
Copy link
Owner

nkh-lab commented Aug 30, 2023

It looks like a problem in your application. By the way, you can use this project (https://github.com/nkh-lab/car-api-hello-world) as an example application and also this manifest (https://github.com/nkh-lab/ aosp-ncar-manifest) to get the NCAR AOSP where the given VHAL is used with the mentioned application.

@lavanyapisini
Copy link
Author

In VHAL layer we have already implemented "VENDOR_PARKING_LIGHTS_STATE" property, and the same property I'm trying to register from Android app, also we have taken the same Android code from here and just replaced the Vendor property of ours.

Please find the below app code:


private void registerVendorProperty() {
mCarPropertyManager.registerCallback(new CarPropertyManager.CarPropertyEventCallback() {
@OverRide
public void onChangeEvent(CarPropertyValue carPropertyValue) {
Log.d(TAG, "VENDOR_PARKING_LIGHTS_STATE: onChangeEvent(" + carPropertyValue.getValue() + ")");
mVendorTest1sCounterPropertyView.setPropValue(String.valueOf(carPropertyValue.getValue()));
}

        @Override
        public void onErrorEvent(int propId, int zone) {
            Log.d(TAG, "VENDOR_PARKING_LIGHTS_STATE: onErrorEvent(" + propId + ", " + zone + ")");
        }
    }, VendorProperty.VENDOR_PARKING_LIGHTS_STATE, CarPropertyManager.SENSOR_RATE_NORMAL);

}


We have tested this property at VHAL with GRPC server client and it is working fine, but not reaching to app.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants