Kayak83
Posts: 10
Joined: Wed May 04, 2016 5:54 pm

Re: RPi Cam Web Interface

Wed May 11, 2016 3:06 am

Is there any way to get this to stream on WAN via port forwarding? I didn't see any options to stream remotely and that's a shame because it's better than motionpie IMO., which I reverted to for my IP camera I made.

Kayak83
Posts: 10
Joined: Wed May 04, 2016 5:54 pm

Re: RPi Cam Web Interface

Wed May 11, 2016 4:33 am

Is port forwarding for remote viewing not an option? Can someone help me out?

btidey
Posts: 1616
Joined: Sun Feb 17, 2013 6:51 pm

Re: RPi Cam Web Interface

Wed May 11, 2016 8:20 am

Kayak83 wrote:Is port forwarding for remote viewing not an option? Can someone help me out?
I access my cameras from the Internet using this software via port forwarding.

However, port forwarding is something you set up on your router not part of this software itself. There is a small section on the wiki about this but it is out of date and not terribly useful. I have updated it a bit with following material.

Steps are

1) Set up security on your camera by installing or re-installing with username:password and optionally choose a different port for access other than the default 80. Changing the port is not necessary but can be helpful in avoiding conflicts with other web uses and provides a bit of extra security against web scanners. It also allows multiple cameras by using different ports on each one.

2) Test security locally e.g. http://cameraip:port and make sure login is OK.

3) Login to your router and
a) Find its WAN IP address. This will be needed to get access from internet.
b) Set up port forward so that the port selected is redirected to the cameraip
c) The way to do this is obviously dependent on the actual router model. Check out http://www.howtogeek.com/66214/how-to-f ... ur-router/

4) To use a regular name from the WAN rather than the WAN IP of your router then set up a dynamic DNS account at a service like http://freedns.afraid.org

Kayak83
Posts: 10
Joined: Wed May 04, 2016 5:54 pm

Re: RPi Cam Web Interface

Wed May 11, 2016 3:49 pm

I've successfully set up port forwarding on lots of camera in the past. Right now I'm running motioneyeOS with the Raspberry Pi with port forwarding since I couldn't get it to work on RPi Cam.

I'm thinking everything might need to be set up initially on first install. Login credentials, port, etc. I left everything default on first try and when I tried to change to port # to anything other than the default 80, it wouldn't work. It'd be great if the port # and login security was part of the main web GUI like motioneye.

I might try a fresh install tonight and see if that works.

btidey
Posts: 1616
Joined: Sun Feb 17, 2013 6:51 pm

Re: RPi Cam Web Interface

Wed May 11, 2016 4:25 pm

Kayak83 wrote:I've successfully set up port forwarding on lots of camera in the past. Right now I'm running motioneyeOS with the Raspberry Pi with port forwarding since I couldn't get it to work on RPi Cam.

I'm thinking everything might need to be set up initially on first install. Login credentials, port, etc. I left everything default on first try and when I tried to change to port # to anything other than the default 80, it wouldn't work. It'd be great if the port # and login security was part of the main web GUI like motioneye.

I might try a fresh install tonight and see if that works.
I can successfully change round settings like security, port, subfolder etc by rerunning the installation if using the recommended ./install.sh method and using the Apache web server. It is possible there may be issues if using nginx as that is less tested when changing things around.

btidey
Posts: 1616
Joined: Sun Feb 17, 2013 6:51 pm

Re: RPi Cam Web Interface

Wed May 11, 2016 10:15 pm

After the install.sh script runs a reboot is not normally required and running ./start.sh was sufficient to start the system.

I have amended the install.sh so that it offers to run ./start.sh instead of offering a reboot.

wh7qq
Posts: 1314
Joined: Thu Oct 09, 2014 2:50 am

Re: RPi Cam Web Interface

Wed May 11, 2016 10:20 pm

This is a really dumb question that probably has been asked and answered elsewhere but I don't know the right keywords to find it. I am trying to load RPi-Cam to an SD card set up with q4os which is based on raspbian but uses a different desktop. Raspbian comes pre-installed with "git" but q4os does not and after doing

Code: Select all

apt-get install git
and trying to git clone the repository, it asks me for a username and password which, of course, I do not have. How can I download the RPi-Cam Web Interface or install a username and password in git? I am about to throw the computer and monitor down the stairs to the concrete driveway with frustration over the username/password gunk everywhere! :x :x

User avatar
Mettauk
Posts: 235
Joined: Mon Dec 10, 2012 12:40 pm
Location: Zarg

Re: RPi Cam Web Interface

Wed May 11, 2016 10:24 pm

Kayak83 wrote:I've successfully set up port forwarding on lots of camera in the past. Right now I'm running motioneyeOS with the Raspberry Pi with port forwarding since I couldn't get it to work on RPi Cam.

I'm thinking everything might need to be set up initially on first install. Login credentials, port, etc. I left everything default on first try and when I tried to change to port # to anything other than the default 80, it wouldn't work. It'd be great if the port # and login security was part of the main web GUI like motioneye.

I might try a fresh install tonight and see if that works.
To edit the port used by RPi Cam either re install OR see the details hereviewtopic.php?p=556258#p556258
As humans we have been the same for a very very long time, technology changes how we do... not who we are as people.

Kayak83
Posts: 10
Joined: Wed May 04, 2016 5:54 pm

Re: RPi Cam Web Interface

Wed May 11, 2016 10:43 pm

Started the reinstall of this but after it's complete I'm getting:

raspimjpeg: no process found
php: no process found
motion: no process found

Getting into cd Rpi_Cam_Web_Interface then ./start.sh returns:

motion: no process found

EDIT/UPDATE:
Not sure what the heck was going on, but going from memory from the first time I had this working, I remember trying out a script I found via youtube that was an attempt to get Motioneye installed on Raspbian https://www.youtube.com/watch?v=G7DwPzSbLlc . The camera wouldn't work with motioneye for some reason, BUT the installer did install some missing components that I'm not sure why weren't installing in the first place. I.e.- motion and ffmpeg, etc. So after running through that youtube tutorial I went ran the "Original Installation method" installer and got everything set up to work, including changing the port number and adding login security.

Now it's working with IP Cam Viewer on Android using the " Raspberry" and "RPi Cam Web Interface" method, leaving the channel number blank.

SUCCESS!!

wh7qq
Posts: 1314
Joined: Thu Oct 09, 2014 2:50 am

Re: RPi Cam Web Interface

Thu May 12, 2016 8:21 am

Started the reinstall of this but after it's complete I'm getting:

raspimjpeg: no process found
php: no process found
motion: no process found

Getting into cd Rpi_Cam_Web_Interface then ./start.sh returns:

motion: no process found
From several installs on Raspbian/Pi2 hardware, this is normal behavior. In spite of the ominous sounding messages, you just have to open the browser to the ip address of the device with the camera attached: probably 192.168.1.X. Motion doesn't load or present any adjustments until you click on the "start motion" key. All the expected functions are present on the web interface.

Kayak83
Posts: 10
Joined: Wed May 04, 2016 5:54 pm

Re: RPi Cam Web Interface

Thu May 12, 2016 3:28 pm

wh7qq wrote:
Started the reinstall of this but after it's complete I'm getting:

raspimjpeg: no process found
php: no process found
motion: no process found

Getting into cd Rpi_Cam_Web_Interface then ./start.sh returns:

motion: no process found
From several installs on Raspbian/Pi2 hardware, this is normal behavior. In spite of the ominous sounding messages, you just have to open the browser to the ip address of the device with the camera attached: probably 192.168.1.X. Motion doesn't load or present any adjustments until you click on the "start motion" key. All the expected functions are present on the web interface.

The camera wouldn't load on the web browser after install. See the above post edit I made though in bold as I have found a solution and it's working now.

Martin94
Posts: 1
Joined: Fri May 13, 2016 6:30 am

Re: RPi Cam Web Interface

Fri May 13, 2016 6:35 am

How to set the default directory that save the images and videos?

User avatar
Mettauk
Posts: 235
Joined: Mon Dec 10, 2012 12:40 pm
Location: Zarg

Re: RPi Cam Web Interface

Fri May 13, 2016 7:27 am

Martin94 wrote:How to set the default directory that save the images and videos?
Edit raspimjpeg about 2/3 way down you will see a list of locations for video, stills, time lapse etc.

Code: Select all

sudo nano /etc/raspimjpeg
As humans we have been the same for a very very long time, technology changes how we do... not who we are as people.

Morcegolas
Posts: 4
Joined: Wed Dec 04, 2013 1:14 pm

Re: RPi Cam Web Interface

Sat May 14, 2016 2:57 pm

Hi guys, I'm trying to get this working, but no luck with motion, I think it is always recording and I can't stop recording, see this video because my english is not the best, hope anybody can help me.


Thanks.

btidey
Posts: 1616
Joined: Sun Feb 17, 2013 6:51 pm

Re: RPi Cam Web Interface

Sat May 14, 2016 5:00 pm

Morcegolas wrote:Hi guys, I'm trying to get this working, but no luck with motion, I think it is always recording and I can't stop recording, see this video because my english is not the best, hope anybody can help me.


Thanks.
Can't see the video as it is 'private'. Try using the internal motion detect method. If you are still having difficulty then zip up the scheduleLog.txt file in the web folder and post here.

359
Posts: 16
Joined: Thu May 29, 2014 7:55 pm

Re: RPi Cam Web Interface

Sat May 14, 2016 10:58 pm

Hi, a servoblaster question. I have set up a pan and tilt mech, 2 servos running from pin 7 and 21 on the header. I can only reliably control only one. The other stutters, freezes and jumps. This is the one connected to the up and down arrow in the web interface.

If I switch the servo connections, the left and right controls the up/down servo perfectly. So to me, not a hardware issue, not the servo under powered or binding. It's hard to explain honestly.

My question is, I think (!), how to check the 'output' command from the web interface up and down arrow, the actual command sent to servoblaster. Where would I find this? I am thinking the up/down arrow command is not the same as the right/left.

Any thoughts please?

EDIT: Working, turns out for whatever reason, pin 7 on header was a bad one, maybe sharing with something?

Switched to 21 and 22, working from gpio power also..phew
Last edited by 359 on Sun May 15, 2016 12:11 am, edited 1 time in total.

Morcegolas
Posts: 4
Joined: Wed Dec 04, 2013 1:14 pm

Re: RPi Cam Web Interface

Sat May 14, 2016 11:18 pm

Hello again guys, don't ask me how or why but I manage to get this working, nice!

One little question, in Camera Settings - Annotations is it possible have two lines instead of one?

Thanks and nice job here, going to try time-lapse soon ;)

btidey
Posts: 1616
Joined: Sun Feb 17, 2013 6:51 pm

Re: RPi Cam Web Interface

Sun May 15, 2016 9:04 am

Morcegolas wrote:Hello again guys, don't ask me how or why but I manage to get this working, nice!

One little question, in Camera Settings - Annotations is it possible have two lines instead of one?

Thanks and nice job here, going to try time-lapse soon ;)
The Annotaion interface into the camera is a single string. However, it will automatically wrap to following lines if it can't fit so you can achieve this by making the string longer and inserting spaces as required.

texy
Forum Moderator
Forum Moderator
Posts: 5155
Joined: Sat Mar 03, 2012 10:59 am
Location: Berkshire, England

Re: RPi Cam Web Interface

Sun May 15, 2016 9:57 am

Hi,
I am using a v2 camera. With timelapse, I am unable to view the video after conversion via the web interface - the a new tab is created but black screen - pressing the play button does nothing and there time length is zero. Where is the created video stored?

thanks,
Texy
Various male/female 40- and 26-way GPIO header for sale here ( IDEAL FOR YOUR PiZero ):
https://www.raspberrypi.org/forums/viewtopic.php?f=93&t=147682#p971555

Morcegolas
Posts: 4
Joined: Wed Dec 04, 2013 1:14 pm

Re: RPi Cam Web Interface

Sun May 15, 2016 10:01 am

Thanks Btiday

Cherax
Posts: 1
Joined: Sun May 15, 2016 3:40 pm

Re: RPi Cam Web Interface

Sun May 15, 2016 3:56 pm

0lly wrote:
m4rky wrote: Thats exactly what I was looking for. Thanks for your help :D
I use a NAS as NFS-Server
On Rpi install

Code: Select all

sudo apt-get install nfs-common rpcbind
sudo service rpcbind start
sudo service nfs-common start
mount the nfs-share
(modify the location "192.168.178.14:/i-data/6b86fde7/nfs/rpicam")

Code: Select all

sudo nano /etc/fstab
add 192.168.178.14:/i-data/6b86fde7/nfs/rpicam /var/www/media nfs defaults 0 1
and reboot

test

Code: Select all

mount
..
192.168.178.14:/i-data/6b86fde7/nfs/rpicam on /var/www/media type nfs (rw,relatime,vers=3,rsize=32768,wsize=32768,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=192.168.178.14,mountvers=3,mountport=4171,mountproto=udp,local_lock=none,addr=192.168.178.14)

Code: Select all

df
Dateisystem 1K-Blöcke Benutzt Verfügbar Verw% Eingehängt auf
rootfs 7515692 2952440 4212628 42% /
/dev/root 7515692 2952440 4212628 42% /
devtmpfs 183312 0 183312 0% /dev
tmpfs 38316 240 38076 1% /run
tmpfs 5120 0 5120 0% /run/lock
tmpfs 76620 56 76564 1% /run/shm
/dev/mmcblk0p1 57288 19120 38168 34% /boot
192.168.178.14:/i-data/6b86fde7/nfs/rpicam 1922352480 1461040256 461312224 77% /var/www/media

Hello,
I know your post is two years old, but perhaps you can help me out nevertheless somehow. I have mounted my NAS to /var/www/media usings cifs in fstab. When I record images or videos with RPI Cam Control the recorded files appear on the raspberry as well as on the NAS. When I delete these files from the NAS they automatically get deleted from the rpi and vice-versa. Is there any way to prevent these files from being recorded on the SD-card and to make them record directly on the NAS?

An alternative option would be to record them as they are right now (recorded files are synchronised between rpi and NAS automatically), and just have the files erased automatically from the SD-card after they have been written to the NAS.

Could you help me out with this?

Thanks!

btidey
Posts: 1616
Joined: Sun Feb 17, 2013 6:51 pm

Re: RPi Cam Web Interface

Sun May 15, 2016 5:20 pm

texy wrote:Hi,
I am using a v2 camera. With timelapse, I am unable to view the video after conversion via the web interface - the a new tab is created but black screen - pressing the play button does nothing and there time length is zero. Where is the created video stored?

thanks,
Texy
It should create the converted time lapse video in same media folder. It does the conversion by putting the time lapse images in a subfolder (like t0003) and then running the conversion on files in this folder. THe folder is then removed after the conversion is complete.

Check the log file to see the conversion command which should be something like

Code: Select all

 start lapse convert:(avconv -r 5 -i /var/www/media/t0003/i_%05d.jpg -r 5 -vcodec libx264 -crf 20 -g 5 /var/www/media/tl_0003_0001_20160515_170554.mp4 ; rm -rf /var/www/media/t0003;) >/dev/null 2>&1 &
It is possible that something may be going wrong if a subfolder is used for the media or time lapse files storage. I would need to check that.

Edit: Looking at code I think it is OK if you have installed into a sub-folder under /var/www but there may be a problem if you have added paths into the storage location for the time lapse files (in /etc/raspimjpeg)

tianheng123
Posts: 13
Joined: Mon Aug 03, 2015 4:14 pm

Re: RPi Cam Web Interface

Sun May 15, 2016 6:10 pm

Hi,
I am trying to build a web app (a flask app run with mod_wsgi) which controlling several gpio pins. In the meanwhile, I would like to keep the Cam Web interface alive.
I am wondering whether I can put both web app and interface on one server?
Or if not possible...can someone shed some light with embedding of interface in my web app?

texy
Forum Moderator
Forum Moderator
Posts: 5155
Joined: Sat Mar 03, 2012 10:59 am
Location: Berkshire, England

Re: RPi Cam Web Interface

Sun May 15, 2016 7:43 pm

btidey wrote:
texy wrote:Hi,
I am using a v2 camera. With timelapse, I am unable to view the video after conversion via the web interface - the a new tab is created but black screen - pressing the play button does nothing and there time length is zero. Where is the created video stored?

thanks,
Texy
It should create the converted time lapse video in same media folder. It does the conversion by putting the time lapse images in a subfolder (like t0003) and then running the conversion on files in this folder. THe folder is then removed after the conversion is complete.

Check the log file to see the conversion command which should be something like

Code: Select all

 start lapse convert:(avconv -r 5 -i /var/www/media/t0003/i_%05d.jpg -r 5 -vcodec libx264 -crf 20 -g 5 /var/www/media/tl_0003_0001_20160515_170554.mp4 ; rm -rf /var/www/media/t0003;) >/dev/null 2>&1 &
It is possible that something may be going wrong if a subfolder is used for the media or time lapse files storage. I would need to check that.

Edit: Looking at code I think it is OK if you have installed into a sub-folder under /var/www but there may be a problem if you have added paths into the storage location for the time lapse files (in /etc/raspimjpeg)
Hi,
I have not changed the folder or any other options from the defaults. The only thing I've done is change the timelapse interval from 3 seconds to 10 seconds. I can see the jpg being produced in the media folder. The setting for the conversion are also at default - avconv -r 5 -i i_%05d.jpg -r 5 -vcodec libx264 -crf 20 -g 5
When I hit the Start Convert button, the webpage goes back to the 'files' page with 'busy' displayed above the thumbnail and that's how it stays. However a mp4 file is created in the media folder, but it is only 48 bytes in size.
This is the log entry :

Code: Select all

[2016/05/15 19:22:27] start lapse convert:(avconv -r 5 -i /var/www/html/media/t0                                                     005/i_%05d.jpg -r 5 -vcodec libx264 -crf 20 -g 5 /var/www/html/media/tl_0005_000                                                     1_20160515_184007.mp4 ; rm -rf /var/www/html/media/t0005;) >/dev/null 2>&1 &
Texy
Various male/female 40- and 26-way GPIO header for sale here ( IDEAL FOR YOUR PiZero ):
https://www.raspberrypi.org/forums/viewtopic.php?f=93&t=147682#p971555

centos90
Posts: 25
Joined: Fri Jul 31, 2015 4:18 pm

Re: RPi Cam Web Interface

Mon May 16, 2016 2:48 pm

Hi, I need some help to get this running, see errors below. thanks

[email protected]:~/RPi_Cam_Web_Interface $ sudo sh start.sh
+ readlink -f start.sh
+ dirname /home/pi/RPi_Cam_Web_Interface/start.sh
+ cd /home/pi/RPi_Cam_Web_Interface
+ source ./config.txt
start.sh: 40: start.sh: source: not found
+ fn_stop
+ sudo killall raspimjpeg
raspimjpeg: no process found
+ sudo killall php
php: no process found
+ sudo killall motion
motion: no process found
+ sudo mkdir -p /dev/shm/mjpeg
+ sudo chown www-data:www-data /dev/shm/mjpeg
+ sudo chmod 777 /dev/shm/mjpeg
+ sleep 1
+ sudo su -c raspimjpeg > /dev/null & www-data
mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)
mmal: mmal_component_create_core: could not create component 'vc.ril.camera' (1)
sh: 1: /var/www/html/macros/error_hard.sh: Permission denied
+ [ -e /etc/debian_version ]
+ sleep 1
+ sudo su -c php /var/www//schedule.php > /dev/null & www-data
[email protected]:~/RPi_Cam_Web_Interface $ mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)
mmal: mmal_component_create_core: could not create component 'vc.ril.camera' (1)
sh: 1: /var/www/html/macros/error_hard.sh: Permission denied
mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)

Return to “Camera board”