Help configuring Arduino to trigger DI on IP-camera

Hello all.

I’m in the middle of a project and could really need some help from here.

I’ve put up an IP-cam for a customer overlooking the queue to a truck wash. The camera detects “loitering” in the queue area and triggers an alarm on the NVR which in turn activates a set of lights to let the guys know there’s a truck waiting in line.

I’ve discovered that this setup is not good enough because the alarm turns off after about two minutes even though the truck is still waiting in line. The conclusion from the manufacturer’s tech support is that there is no camera-based solution matching my needs.

Therefore i’m thinking about having an Arduino detect whenever there’s a truck waiting in line and trigger the Digital Input on the camera which in turn activates the lights.

The lights are already installed and working (running on a 12V power supply activated by a relay from the NVR).

See screenshot from the camera to get a feeling of the surroundings

https://i.imgur.com/FrKEvnM.png

My questions are as follows:

Can you think of any other way i can achieve what I’m describing?

I have some Arduino Pro Mini’s lying around I’m planning on using.

Are these suitable?

What kind of sensor should I use to detect trucks in the queue?

Will a distance sensor placed on the wall with the camera do the job?

I really hope I don’t have to mount anything “behind” the truck

How would I go about coding the Arduino to only trigger whenever a truck has been in the queue for say 10 secs and NOT whenever a truck just drives by?

How should I wire the Arduino to the DI on the camera?

The terminal on the camera can be setup as either “normally high” or “normally low” in the software

I’m really hoping for some input on this one. Anything is appreciated!

My first order of business would be to figure out how to detect the truck. My suggestion is a photoelectric through-beam sensor with the emitter and detector facing each other across the queue. A coil under the ground would probably be more durable, but then you have to dig up the concrete!

That’s really the most important part of the project, and probably the hardest to get right. I’ve seen so many things that go wrong trying to detect objects…

Anyway, then you can take the detector output and using an Arduino, time delay relay, PLC or whatever, trigger the camera after the input has been active for 10 seconds. That part should be more straightforward.

If you’re looking for someone to build this system for you, send me a PM.

Thank you for your reply, Lyndon. I sent you a PM.

I would still like some inputs on how to wire the arduino to the camera and how to code the Arduino for beam breaking. Also what kind of IR-light source I should use for this beam.

Can anyone shed some lights on this for me?

I covered this in my PM, but to anyone using this project as a future reference: an ultrasonic sensor would probably have fewer false positives than an IR sensor outdoors.