• DepthAI
  • How to run OAK-D camera and S7-1200 PLC together

Hi,

I want to make object traking system. I'm using just OAK-D camera and S7-1200 PLC. I will define imaginary line on the cam. If the object pass the line , camera will give data/logic 1 to PLC . How can i make it?

Thanks,

    Hi eraydoan
    The OAK-D won't work directly with the PLC, since you need a library (python, cpp) to interact with the device.
    You can however use an intermediary rpi, and control the GPIO outputs to signal to the PLC.

    Thoughts?
    Jaka

      Hi jakaskerl

      Is rpi for just programming or for permanent use the OAK-D ? Could you send me simply a block diagram for i understand?

      Thanks

      Eray

        Hi eraydoan
        [ OAK-D Camera ] ---(USB connection)---> [ Raspberry Pi ] ---(GPIO/Signal)---> [ S7-1200 PLC ]

        Another option would be to use POE camera and use the m8 connector pin as the trigger. But you would still need a host machine to run the postprocessing code.

        Thanks,
        Jaka

        Hi jakaskerl

        Thanks a lot. I have last question. I have OAK-D Camera.

        OAK-D Camera has Intel Myriad X 4TOPS and Expansion interfaces: GPIO, SPI, UART.

        There is already a processor and GPIO. Isn't it possible with these? Why is rpi needed?

        Thanks,

        Eray

          Hi eraydoan

          1. Because the PCB is not exposed in the Oak-D variant.
          2. MyriadX is not designed to run heavy-general purpose scripts. It's a VPU used to accelerate ML and image processing tasks. The RPI on the other hand has a general-purpose processor.
            And you need a way to connect to the device, since you need to upload your pipeline to it first. The host side (RPI, PC, etc) does that.

          Thanks,
          Jaka