[Release] - an app for AI camera/webcam motion/object detection/recognition (motion, person, pet, vehicle, face using tinyCam)

You'd have to tweak the app code I think to achieve your single device approach. At the moment the parameter in the Webhook sent from tinyCam drives different virtual motion sensors as you know. So you could tweak the code to interpret these events instead to drive a single device I suppose. Depends really on your end game, whatever you are trying to achieve. Maybe keep it simple as it is now and use Rule Machine to drive other automations?

I didn't run into any certificate issues with tinyCam so I don't think I can help you with that, sorry. Hope you get it resolved. Please keep us posted on your progress!

Good Evening. Angus_M, could you please guide me on setup a camera with tinyCam? I am using iPhone and HE C-7. Where from I can get the driver and Apps? Is there any tested camera that can be used? I can use POE, or RJ45 with power supply. Please help. Thanks

Hi.

Best to check online for setup instructions for tinyCam and to select a camera that is supported by tinyCAM. This may help...

https://tinycammonitor.com/support.html

I'm just running a powered Samsung Smartcam and it works perfectly well.

Remember you need to have tinyCam running on an always-on computer somewhere on your LAN (eg. a tablet or old phone you can leave in the property to run the tinyCam webserver).

Then install the apps (parent and child) on your HE hub by copying the code above in this thread (around post 19 for the parent app and post 42 for the updated child app). Yeah, I know I should get these into HPM :weary:

As long as the connection between your camera(s) and tinyCam works in the "live view" of tinyCam then everything else should be fine. Remember to put your camera in tinyCam into "background mode" if you want to run other apps on your always-on device and tinyCam will go into the background but still sense on motion/objects.

Please also note that this approach using my app in the thread above is best suited to powered cameras, not battery powered cameras. This is because tinyCam will continually access the camera for motion/object detection, leading to rapid power decline if it's battery powered.

There is no special driver required. Just create a virtual motion sensor in HE for each type of motion/object detection you want for each camera. So you could have 3 for a camera (eg. cam1_motion, cam1_person, cam1_face if you want to trigger on motion, person and face detection for that camera). Then when you run the parent app which you use to create a child for each camera, select those virtual motion devices to link to the Webhook that the app generates. Then stick that Webhook into the motion menu of tinyCam for that camera.

I posted more instructions above and various screenshots of the menus to assist above in the thread (around post 28 I think).

Good luck!

1 Like

Good Morning
Thanks for detailed information. I am going to order camera soon and install them as per suggestions, Thank you

Thank you very much, TinyCam is working, excellent, I appreciate your help. Now, the last piece. Please guide me on how to watch live stream in the tile. Thanks again

This should help...

Read down the thread because my initial approach in post #1 was simplified in post #2 (there is no need for the iframe driver) :slight_smile:

Thank you, thank you.

Greetings to you.
Angus_M, I am using iFrame to make sure live view is working. But geeting message as follows:

The webpage at https://192.168.0.7:8083/axis-cgi/mjpg/video.cgi?user=admin&pwd=admin&camera=cam1&resolution=320x240 might be temporarily down or it may have moved permanently to a new web address.

Any suggestion? Thanks

Camer=cam1 should be
Camer=1

And assuming your username and password are correct

1 Like

Yeah "...camera=1..." I think

Also note that the iframe driver is not necessary. You can just use an image tile and put the url directly into the image parameter or the background parameter. Using background will scale the image to fit the tile, which is quite handy.

1 Like

Thank you. Excellent !!!! working very good!!!!

1 Like

Many thanks!!!

1 Like

hello
I currently have bunch of mostly hikvision camera that are on my hik vision NVR. my home internet is LTE so i cannot do inbound ports.

is it possible to get this work ? it seems like i need device on my lan to get hte camerfeeds and that will then send them to hubitat via tiny cam?

The advantage of MotionEye would be you may be able to scale it better, and you can run on more platforms. It is also a free opensource product. I am not sure how powerful TinyCam is, but i can take Motion and put it on a unraid server in a docker, a VM, a raspberry pi, pretty much anything and support whatever camera count i want with it. It's biggest limit though is that it doesn't seem to integrate with cloud service based cameras like Arlo or blink like TinyCam. If the camera supports RTSP, or ONVIF though it is good.

From what i have been able to find with Tinycam it appears to need either a Android or IOS device. Is that true. What have you found to be a realistic camera limit for the main server running Tinycam pro.

1 Like

Yeah, I run TinyCam on a cheap 10.1" Teclast (Chinese) Android tablet which I also use to access my custom dashboard, so it's always on and remains in the house. It may certainly make sense to have a PC-based system if you have a large deployment of cameras. My system runs my 4 cameras quite well, no issues. You could certainly modify the app above to take webhooks from different systems. The app's simply a way to take an inbound GET url, decode the info from the parameters, and then activate the relevant virtual motion sensor.

You'd have to check your cameras are supported. I linked above somewhere to the tinyCam support page which lists the cameras they support. It's a huge list so you will probably be ok but best to check carefully.

Yes,you need an always-on Android​ ​computer running TinyCam on your LAN. The HE app above takes a Webhook which you set in the TinyCam app for each camera, and decodes that to drive virtual motion sensors you set up in HE for motion and the various object detection types (person, face, pet, vehicle). If you want to display your cameras on your dashboards then you use image tiles in your HE dashboard and simply put the url provided by TinyCam's webserver (again, see posts above) into the background field of the tile, so that the video is autoscaled to fill the dashboard tile.

So I just test this will the option in Motion to call a webhook. Worked like a charm. All I had to do was set the last part for the variable of what type of motion to hard code "Motion". So this means this will also work for anyone using that software as well.

1 Like

Yeah exactly. Nice solution!

I find that using motion for light on triggers is not that good (too many false positives for motion from cameras). But for keeping cameras on using the object detection in tinyCam to cancel timeouts, it works really well!

I noticed that in the driver it mentions TinyCam is available for PC -- but I can't find the download on the official site. Is this a mistake?

I think that's a mistake. Sorry about that. I recall someone used the app to get their Blue Iris integration working along similar lines (since at the end of the day this is just an app to decode a webhook and control virtual motion sensors accordingly). That system is definitely available on PC.

[UPDATE] - I edited the code segments above to indicate that tinyCam is an Android​ app only. Sorry for any confusion.