I'd like to use EVS camera system from Android Automotive in Android Emulator.
I've added a camera of my computer to the emulated OS with hw.camera.back=webcam0 in the emulator's config.ini file. Then I've built sdk_car_x86_64 with ENABLE_CAMERA_SERVICE, Gallery2 package and some camera-related permissions from frameworks/native/data/etc/. Now I can open the standard AOSP Camera application, and it works.
Then, I've added few more services: [email protected], [email protected], [email protected] and camera.v4l2 package. With some extra configuration the EvsEnumerator starts and I can run evs_app, but it's empty - it shows black screen and the 'close' button only. Well, it's obvious, because etc/automotive/evs/evs_configuration_override.xml points to /dev/video0 and there is no /dev/video* device in my system - therefore V4L2 returns no devices to EvsDriver (evs-related logs below).
2023-10-06 13:49:08.661 250-250 evsmanagerd pid-250 I EVS manager starting
2023-10-06 13:49:08.674 250-250 evsmanagerd pid-250 I Main thread entering thread pool
2023-10-06 13:49:08.674 250-257 evsmanagerd pid-250 I EVS managed service connecting to hardware service at hw/1
2023-10-06 13:49:08.674 250-257 evsmanagerd pid-250 I hardwareServiceName: hw/1
2023-10-06 13:49:14.693 250-257 evsmanagerd pid-250 I EVS managed service is starting as android.hardware.automotive.evs.IEvsEnumerator/default
2023-10-06 13:49:14.696 250-257 evsmanagerd pid-250 I Registration complete
2023-10-06 13:49:08.748 251-251 EvsDriver pid-251 I EVS Hardware Enumerator service is starting
2023-10-06 13:49:08.750 251-251 EvsDriver pid-251 I Parsing configuration file takes 9.145000e-01 ms.
2023-10-06 13:49:08.750 251-251 EvsDriver pid-251 I enumerateCameras: Starting dev/video* enumeration
2023-10-06 13:49:08.750 251-251 EvsDriver pid-251 I Found 0 qualified video capture devices of 0 checked.
2023-10-06 13:49:08.750 251-251 EvsDriver pid-251 I enumerateDisplays: Starting display enumeration
2023-10-06 13:49:13.725 251-251 EvsDriver pid-251 I Display 401cec6a7a2b7b00 is detected on the port, 0
2023-10-06 13:49:13.725 251-251 EvsDriver pid-251 I Found 1 displays
2023-10-06 13:49:13.726 251-251 EvsDriver pid-251 I EVS Hardware Enumerator is ready
2023-10-06 13:49:13.726 251-543 EvsDriver pid-251 I Start monitoring new V4L2 devices
2023-10-06 13:49:14.708 251-640 EvsDriver pid-251 I Display resolution is 1024x768
2023-10-06 13:49:08.678 249-249 EvsApp pid-249 I EVS app starting
2023-10-06 13:49:08.680 249-249 EvsApp pid-249 I Acquiring EVS Enumerator
2023-10-06 13:49:14.696 249-249 EvsApp pid-249 I Acquiring EVS Display
2023-10-06 13:49:14.698 249-249 EvsApp pid-249 I Connecting to Vehicle HAL
2023-10-06 13:49:14.703 249-249 EvsApp pid-249 I Constructing state controller
2023-10-06 13:49:24.705 249-249 EvsApp evs_app I Camera list callback received 0cameras.
2023-10-06 13:49:24.705 249-249 EvsApp evs_app I Entering running state
2023-10-06 13:49:24.708 249-784 EvsApp evs_app I Activated state 4
From static code analysis I found that Camera API (used by Camera applications) uses some EmulatedCameraProvider to access the emulated camera, probably without V4L2.
I don't know, what can I do next. It seems the kernel supports the camera itself (Camera app works) but V4L2 doesn't create /dev/video* representations, and the workaround from Google (EmulatedCameraProvider) applies to Camera API only, not the EVS.
Any help will be appreciated.