# 4.1 in wsl 2.0: no camera detected

**URL:** <https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909>\
**Category:** Docker\
**Tags:** python, windows\
**Created:** [May 7, 2024, 3:03pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909 "2024-05-07T15:03:59Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![bblumberg](https://community.stereolabs.com/user_avatar/community.stereolabs.com/bblumberg/32/93_2.png) [@bblumberg](https://community.stereolabs.com/u/bblumberg)\
**Post date:** [May 7, 2024, 3:03pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/1 "2024-05-07T15:03:59Z")

</div>

What is the status of using the zed sdk 4.1.1 in wsl 2.0? I tried using the docker image for Ubuntu 22.04, and using usbipd, lsusb sees both the camera and the hid, but when running the container, no camera is detected. When I checked /etc/udev/udev.conf in the docker container, I didn’t see any sl specific entries.

Thanks!

---

<div class="post-metadata">

**Author:** ![Myzhar](https://community.stereolabs.com/user_avatar/community.stereolabs.com/myzhar/32/11_2.png) [@Myzhar](https://community.stereolabs.com/u/Myzhar)\
**Post date:** [May 7, 2024, 3:09pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/2 "2024-05-07T15:09:27Z")

</div>

> [@bblumberg](#):
>
> When I checked /etc/udev/udev.conf in the docker container, I didn’t see any sl specific entries.

Does it work if you manually add the required udev rule?

---

<div class="post-metadata">

**Author:** ![bblumberg](https://community.stereolabs.com/user_avatar/community.stereolabs.com/bblumberg/32/93_2.png) [@bblumberg](https://community.stereolabs.com/u/bblumberg)\
**Post date:** [May 7, 2024, 3:10pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/3 "2024-05-07T15:10:30Z")

</div>

Thanks for the quick reply!!! What is the required udev rule and I will try that.

---

<div class="post-metadata">

**Author:** ![Myzhar](https://community.stereolabs.com/user_avatar/community.stereolabs.com/myzhar/32/11_2.png) [@Myzhar](https://community.stereolabs.com/u/Myzhar)\
**Post date:** [May 7, 2024, 3:22pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/4 "2024-05-07T15:22:30Z")

</div>

This one  
[99-slabs.rules](https://community.stereolabs.com/uploads/short-url/bh4i8VHAVNjpW4S6CFA0x0DbWTX.rules) (4.6 KB)  
it must be located in `/etc/udev/rules.d/`

---

<div class="post-metadata">

**Author:** ![bblumberg](https://community.stereolabs.com/user_avatar/community.stereolabs.com/bblumberg/32/93_2.png) [@bblumberg](https://community.stereolabs.com/u/bblumberg)\
**Post date:** [May 7, 2024, 3:47pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/5 "2024-05-07T15:47:37Z")

</div>

Ok, I added that to the container (and restarted the container), and the camera was still not detected. I also added it to the wsl ubuntu /etc/… and still no luck.

---

<div class="post-metadata">

**Author:** ![Myzhar](https://community.stereolabs.com/user_avatar/community.stereolabs.com/myzhar/32/11_2.png) [@Myzhar](https://community.stereolabs.com/u/Myzhar)\
**Post date:** [May 7, 2024, 4:36pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/6 "2024-05-07T16:36:05Z")

</div>

Please run `ZED Diagnostic` and send the report file that it generates

---

<div class="post-metadata">

**Author:** ![bblumberg](https://community.stereolabs.com/user_avatar/community.stereolabs.com/bblumberg/32/93_2.png) [@bblumberg](https://community.stereolabs.com/u/bblumberg)\
**Post date:** [May 7, 2024, 4:41pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/7 "2024-05-07T16:41:53Z")

</div>

Ok, I will need to build a container that has the sdk because the docker image from dockerhub does not include the tools (I was surprised at that).

Thanks as always for your help.

bb

---

<div class="post-metadata">

**Author:** ![bblumberg](https://community.stereolabs.com/user_avatar/community.stereolabs.com/bblumberg/32/93_2.png) [@bblumberg](https://community.stereolabs.com/u/bblumberg)\
**Post date:** [May 7, 2024, 5:34pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/8 "2024-05-07T17:34:53Z")

</div>

## See below… bb

[ZED\_Diagnostic\_Results.json](https://community.stereolabs.com/uploads/short-url/kNuY9CasZ2U3v7ptC14brDBdctu.json) (5.4 KB)

```auto
{
    "AI Models": {
        "info": [
            "MULTI CLASS DETECTION is not optimized",
            "MULTI CLASS MEDIUM DETECTION is not optimized",
            "MULTI CLASS ACCURATE DETECTION is not optimized",
            "HUMAN BODY FAST DETECTION is not optimized",
            "HUMAN BODY MEDIUM DETECTION is not optimized",
            "HUMAN BODY ACCURATE DETECTION is not optimized",
            "HUMAN BODY 38 FAST DETECTION is not optimized",
            "HUMAN BODY 38 MEDIUM DETECTION is not optimized",
            "HUMAN BODY 38 ACCURATE DETECTION is not optimized",
            "PERSON HEAD DETECTION is not optimized",
            "PERSON HEAD ACCURATE DETECTION is not optimized",
            "REID ASSOCIATION is not optimized",
            "NEURAL DEPTH is not optimized",
            "NEURAL PLUS DEPTH is not optimized"
        ]
    },
    "Camera Test": {
        "InternalDevicesCount": 2,
        "ZEDCount": 0,
        "error": [
            "<b>Camera not detected</b> <br/> Make sure the camera is plugged in or try another USB 3.0 port."
        ]
    },
    "Devices": {
        "CorruptedFirmware": false,
        "MCUDetected": true,
        "USBList": [
            {
                "USBMode": 3,
                "USB_path": "/1",
                "bDescriptorType": 1,
                "bDeviceProtocol": 1,
                "bLength": 18,
                "bMaxPacketSize0": 9,
                "bNumConfigurations": 1,
                "bcdDevice": "1.0",
                "bcdUSB": "3.0",
                "bcdUSBClass": 239,
                "bcdUSBSubClass": 2,
                "busNumber": 2,
                "device": "ZED mini",
                "iManufacturer": 1,
                "iProduct": 2,
                "iSerial": 0,
                "idProduct": "0xf682",
                "idVendor": "0x2b03"
            },
            {
                "USBMode": 2,
                "USB_path": "/1",
                "bDescriptorType": 1,
                "bDeviceProtocol": 0,
                "bLength": 18,
                "bMaxPacketSize0": 64,
                "bNumConfigurations": 1,
                "bcdDevice": "2.5",
                "bcdUSB": "2.0",
                "bcdUSBClass": 0,
                "bcdUSBSubClass": 0,
                "busNumber": 1,
                "device": "ZED mini MCU",
                "iManufacturer": 1,
                "iProduct": 2,
                "iSerial": 3,
                "idProduct": "0xf681",
                "idVendor": "0x2b03"
            }
        ],
        "USBMode": 3,
        "ZED Camera Module Detected": 63106,
        "ZED MCU Module Detected": 63105,
        "ZEDDetected": true,
        "notTested": [
            "Please connect a camera to test the USB connection."
        ]
    },
    "Graphics Card": {
        "deviceCount": 1,
        "deviceDriverVersion": 12040,
        "devices": [
            {
                "arch": "Ada Lovelace",
                "computeCapability": "8.9",
                "cores": 9728,
                "name": "NVIDIA GeForce RTX 4080",
                "totalMemoryBytes": "17170956288",
                "totalMemoryMB": 16375.5
            }
        ],
        "glx_info": "OpenGL vendor string: Mesa\nOpenGL renderer string: llvmpipe (LLVM 15.0.7, 256 bits)\nOpenGL core profile version string: 4.5 (Core Profile) Mesa 23.2.1-1ubuntu3.1~22.04.2\nOpenGL core profile shading language version string: 4.50\nOpenGL core profile context flags: (none)\nOpenGL core profile profile mask: core profile\nOpenGL core profile extensions:\nOpenGL version string: 4.5 (Compatibility Profile) Mesa 23.2.1-1ubuntu3.1~22.04.2\nOpenGL shading language version string: 4.50\nOpenGL context flags: (none)\nOpenGL profile mask: compatibility profile\nOpenGL extensions:\nOpenGL ES profile version string: OpenGL ES 3.2 Mesa 23.2.1-1ubuntu3.1~22.04.2\nOpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.20\nOpenGL ES profile extensions:\n",
        "initResult": 0,
        "valid": [
            "<b>Graphics card: </b> NVIDIA GeForce RTX 4080"
        ]
    },
    "Processor": {
        "OS": "Ubuntu 22.04.3 LTS ",
        "avxSupported": true,
        "coreCount": "28",
        "cpu": " Intel(R) Core(TM) i7-14700K",
        "datetime": "2024-05-07 17:27:15",
        "hyperThreading": "1",
        "motherboard": ", ",
        "ramCapacity": "33.532187",
        "ramUsage": "",
        "ramUsed": "33.203290",
        "threadCount": "56",
        "valid": [
            "<b>Processor: </b> Intel(R) Core(TM) i7-14700K"
        ]
    },
    "ZED SDK": {
        "CUDA Toolkit version": "V12.1.105 -->located in /usr/local/cuda-12.1/bin/nvcc",
        "CUDA loading": false,
        "GPU Driver Version": "Driver Version : 551.76",
        "GPU Performance": " Performance State : P8",
        "ZED SDK Version (Diag)": "4.1.1",
        "ZED SDK Version (RT)": "4.1.1",
        "ai": {
            "checkAI": true,
            "cudaVersion": 12010,
            "cudnnCudartVersion": 12020,
            "cudnnVersion": 8907,
            "cudnnVersionExpected": 8907,
            "tensorVersion": 8601
        },
        "binFiles": [
            "libsl_ai.so",
            "libsl_zed.so",
            "libsl_zed_static.a"
        ],
        "resourcesFiles": [
        ],
        "resourcesFilesExpected": [
            "objects_performance_3.2"
        ],
        "valid": [
            "<b>ZED SDK version:</b> 4.1.1",
            "<b>CUDA version:</b> V12.1.105"
        ]
    }
}

```

---

<div class="post-metadata">

**Author:** ![Myzhar](https://community.stereolabs.com/user_avatar/community.stereolabs.com/myzhar/32/11_2.png) [@Myzhar](https://community.stereolabs.com/u/Myzhar)\
**Post date:** [May 8, 2024, 7:53am UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/9 "2024-05-08T07:53:12Z")

</div>

Can you try to open the camera with `cheese` or `guvcview` to verify that the RGB stream is available?

---

<div class="post-metadata">

**Author:** ![bblumberg](https://community.stereolabs.com/user_avatar/community.stereolabs.com/bblumberg/32/93_2.png) [@bblumberg](https://community.stereolabs.com/u/bblumberg)\
**Post date:** [May 8, 2024, 11:30am UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/10 "2024-05-08T11:30:20Z")

</div>

Thanks for the suggestion. Using cheese inside the container or outside the container results in the same No Device Found, even though lsusb sees the 2 devices.

bb

---

<div class="post-metadata">

**Author:** ![Myzhar](https://community.stereolabs.com/user_avatar/community.stereolabs.com/myzhar/32/11_2.png) [@Myzhar](https://community.stereolabs.com/u/Myzhar)\
**Post date:** [May 8, 2024, 12:05pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/11 "2024-05-08T12:05:37Z")

</div>

This means that the UVC driver of the virtual machine is not working as expected.

Unfortunately, I cannot help you fix this type of Ubuntu problem.  
Please try to search the internet to find a suitable solution for WSL2.

---

<div class="post-metadata">

**Author:** ![bblumberg](https://community.stereolabs.com/user_avatar/community.stereolabs.com/bblumberg/32/93_2.png) [@bblumberg](https://community.stereolabs.com/u/bblumberg)\
**Post date:** [May 8, 2024, 12:25pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/12 "2024-05-08T12:25:59Z")

</div>

Yes, I think that I will need to rebuild the kernel, so outside your scope.

It would be good for [stereolabs](https://www.stereolabs.com/) to have a support page on using the camera in wsl since this does keep coming up, even if it is a link to instructions on how to rebuild the kernel.

Thanks again for being so responsive.

bb

---

<div class="post-metadata">

**Author:** ![bblumberg](https://community.stereolabs.com/user_avatar/community.stereolabs.com/bblumberg/32/93_2.png) [@bblumberg](https://community.stereolabs.com/u/bblumberg)\
**Post date:** [May 8, 2024, 4:16pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/13 "2024-05-08T16:16:57Z")

</div>

So… I followed the directions in this Medium post: wsl2-webcam ([https://medium.com/software-dev-explore/wsl2-webcam-23c1dc9408ae](https://medium.com/software-dev-explore/wsl2-webcam-23c1dc9408ae) ) to rebuild the wsl kernel. As someone else has said, it is straightforward if you follow the directions. Once I rebuilt the kernel per the instructions, I was able to use v4l2, so the video stream is working now (you still have to do the usbipd stuff). So progress.

I now am having USB issues with the device. I have attached the report from Diagnostics. Any ideas?

Yes, I think that I will need to rebuild the kernel, so outside your scope.

It would be good for [stereolabs](https://www.stereolabs.com/) to have a support page on using the camera in wsl since this does keep coming up, even if it is a link to instructions on how to rebuild the kernel.

Thanks again for being so responsive.

bb

---

<div class="post-metadata">

**Author:** ![Myzhar](https://community.stereolabs.com/user_avatar/community.stereolabs.com/myzhar/32/11_2.png) [@Myzhar](https://community.stereolabs.com/u/Myzhar)\
**Post date:** [May 8, 2024, 4:22pm UTC](https://community.stereolabs.com/t/4-1-in-wsl-2-0-no-camera-detected/5909/14 "2024-05-08T16:22:30Z")

</div>

Hi,  
I guess now the problem is related to `udev`.  
The SDK cannot access the HID device and reports a USB error.

Best regards

Walter

**Walter Lucetti**  
_Senior Computer Engineer_  
SDK / Robotics / HW  
[Stereolabs](https://www.stereolabs.com/) Support
