ZMLarch / Motion / Vloopback Autorun

Support and queries relating to third party Live CDs and DVD, VM images and other packaged distributions
Post Reply
jamest142
Posts: 4
Joined: Sun Jan 17, 2010 5:45 pm

ZMLarch / Motion / Vloopback Autorun

Post by jamest142 »

Hiya
Sorry - I am a newbie on Linux, and this may be hopefully a very simple question.
I have installed ZM from the ZMLarch CD to a laptop HDD, and have got all the modules working correctly with my PCMCIA capture card. (ZM, Motion, Vloopback)

However, every time I boot the laptop, I have to type the following into terminal:-

sudo -i
zmrc stop
modprobe videodev
modprobe vloopback
/usr/local/bin/motion
zmrc start

If I type this in manually, the system works great.
Is there a way to do a sort of 'autoexec.bat' type file, such that the above runs automatically at the end of the boot sequence?

Best regards

James T
User avatar
kingofkya
Posts: 1110
Joined: Mon Mar 26, 2007 6:07 am
Location: Las Vegas, Nevada

Post by kingofkya »

simply add

videodev
vloopback


to

/etc/modules



but to anser the original question

/etc/init.d/rc.local

is where you put startup comands
jamest142
Posts: 4
Joined: Sun Jan 17, 2010 5:45 pm

Post by jamest142 »

Hiya

Bostin thanks - it worked.

rc.local is under /etc/ though

Just copied the 2 modprobes, and the motion start line, and it now autostarts everything.

Best regards

James T :D
littlej
Posts: 68
Joined: Sun Oct 18, 2009 11:46 am

Post by littlej »

how did u managed to install vloopback ? i mean what setings u used in zm for it? i havent had any success with it... was working with motion, but could not make it work with zm also at same time. maybe u can post some how-to. thanks
jamest142
Posts: 4
Joined: Sun Jan 17, 2010 5:45 pm

Post by jamest142 »

Hiya

Bear in mind I have only done it once, with a lot of trial and error... :roll:

1st of all - make sure the camera / video source works through ZoneMinder (ZM).
Install Motion, Stop ZM, and make sure you can see the camera through motion. (http://localhost:8081)

Check with your install of Linux, and ensure you use the following:-

ln -s /usr/src/linux-2.4.18-4 /usr/src/linux

The /usr/scr/linux-2.4.18-4 will be different depending on your build version.

To Install VLoopback

sudo -i
Copy to /usr/local/vloopback
tar -xvzf vloopback-1.18.tar.gz (again - use the correct file version)
cd vloopback-1.18 (or whatever!)
make
make install

set the motion.conf to videodevice /dev/video0
videopipe /dev/video1

remove any ; in front of these 2, otherwise it will ignore the line... (Wasted a few nights trying to figure that one out!)

Set the video in ZM to be /dev/Video2
Video 4 Linux needs to Version 1
YUY420 Colour

Restart the system.

Stop ZM
Open Terminal

sudo -i
modprobe videodev
modprobe vloopback
/usr/local/bin/motion
exit
exit

Start ZM


The following links are where I got all the info from:-

http://www.lavrsen.dk/twiki/bin/view/Mo ... backDevice

http://www.lavrsen.dk/foswiki/bin/view/ ... backDevice

http://www.lavrsen.dk/foswiki/bin/view/ ... ideInstall

http://www.zoneminder.com/forums/viewto ... ght=motion

Many thanks to sledgehammer for his initial 'how to'

The important thing is to get video working in ZM first, then Motion.


Apologies if I have missed anything, but bear in mind the above is from my random notes I made when doing it, and I may have missed some bits out, but the dev/video are the correct numbers for my system. :oops:

Best regards

James T
Post Reply