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

Re: RPi Cam Web Interface

Thu Apr 16, 2015 10:54 pm

morticiaskeeper wrote:Robert

I've just copied those files back to the Raspi.

Chrome on iOS now works fine.

Safari worked, but was a little slow. never using Safari, that may be normal!
So just to be totally clear those two files made the iOS browsers work but the latest released ones don't?

Could you try this pair to double check what is going on? These will have the stream select button under system which should by default show the MJPEG stream button indicating Default is being used. If it shows Default then push that.
Attachments
index.zip
(6.93 KiB) Downloaded 71 times

cormad
Posts: 27
Joined: Mon Jan 19, 2015 1:59 pm

Re: RPi Cam Web Interface

Fri Apr 17, 2015 3:27 am

Would love to get this working :)

I followed the instructions to a T. After I reset and installed and reset again I went to my IP and just get a blank page. I can still Putty and winSCP into my pi.

Any ideas what I missed or need to configure?

Thanks

morticiaskeeper
Posts: 101
Joined: Mon Aug 27, 2012 6:05 pm

Re: RPi Cam Web Interface

Fri Apr 17, 2015 6:38 am

btidey wrote:
So just to be totally clear those two files made the iOS browsers work but the latest released ones don't?

Could you try this pair to double check what is going on? These will have the stream select button under system which should by default show the MJPEG stream button indicating Default is being used. If it shows Default then push that.
Yes, the two files made it work on iOS in Chrome.

I've just put the newer files in. the stream select button is there indicating DEFAULT. The stream shows a still frame. close the iPad cover into sleep, open it up again and we have a live stream.

Safari shows LOADING in MJPEG, and a still frame in DEFAULT. Putting the iPad to sleep does not start the stream.

Both streams work fine in Android.

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

Re: RPi Cam Web Interface

Fri Apr 17, 2015 8:42 am

morticiaskeeper wrote:
I've just put the newer files in. the stream select button is there indicating DEFAULT. The stream shows a still frame. close the iPad cover into sleep, open it up again and we have a live stream.

Safari shows LOADING in MJPEG, and a still frame in DEFAULT. Putting the iPad to sleep does not start the stream.

Both streams work fine in Android.
I didn't intend the button to be confusing but if it is showing DEFAULT then the browser is currently in MJPEG streaming mode. It is a toggle and shows what you will get if you click it not what it is currently using.

Button shows MJPEG- Streaming - you are currently in Default streaming image at a time mode and will go to MJPEG streaming if you click it.

Button shows DEFAULT streaming - You are currently in MJPEG streaming and will go to DEFAULT streaming if you click it.

Cookies should mean that it remembers the mode last selected.

morticiaskeeper
Posts: 101
Joined: Mon Aug 27, 2012 6:05 pm

Re: RPi Cam Web Interface

Fri Apr 17, 2015 8:53 am

Yes, i worked that out.

I've put the old files back in and it works perfectly.

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

Re: RPi Cam Web Interface

Fri Apr 17, 2015 9:04 am

cormad wrote:Would love to get this working :)

I followed the instructions to a T. After I reset and installed and reset again I went to my IP and just get a blank page. I can still Putty and winSCP into my pi.

Any ideas what I missed or need to configure?

Thanks
You shouldn't need to configure anything to get started. If you get a blank screen rather than a host unavailable message then that would indicate that Apache is running and browsing to your pi camera should fetch the index.php page.

What browser / platform are you using to browse from?

Few basic checks.

If you WInScp to /var/www you should see a bunch of files including index.php and js and css folders.

Use putty to show what is running (ps -A) The list should include some apache2 items and raspimjpeg

Try browsing to http://cameraIP/Copyright.txt Replace cameraIP with real IP. That should show just a copyright piece of text and shows the basic web server side is functioning.

jarrah31
Posts: 125
Joined: Wed Oct 10, 2012 10:16 am

Re: RPi Cam Web Interface

Fri Apr 17, 2015 10:51 am

Is there a way to change the preview stream size via the GUI? (I can't see the option)

I know that within /etc/raspimjpeg I can change the following to have a width of 800:

Code: Select all

# Preview Options
#
# fps_preview = video_fps (below) / divider
#
width 512
quality 25
divider 1
to

Code: Select all

# Preview Options
#
# fps_preview = video_fps (below) / divider
#
width 800
quality 25
divider 1
However it would be nice if this could be done via the GUI and have the setting retained over reboots?

Thanks.

P.S. Thanks for fixing the Safari problem where I couldn't modify values within textboxes. Also MJPEG stream works well on Safari in OSX and iOS - much smoother! Each time I check this thread there are some amazing updates that improve overall functionality. Great work Rob and Silvan!

As a future feature request, do you know if its technically possible to have multiple video streams shown on a single webpage? I'm thinking along the lines of managing multiple cameras from a central location... :)

jarrah31
Posts: 125
Joined: Wed Oct 10, 2012 10:16 am

Re: RPi Cam Web Interface

Fri Apr 17, 2015 11:00 am

Hey Rob, having just looked at the first post, you should have a bitcoin or PayPal donate button as well what with all the work you're putting into this...

Perhaps the two could go on the wiki? Or maybe as part of your signature?

Full respect to Silvan and all the work he has put into this, but you helped revitalise this project and have been a constant presence, helping others and updating the program! Both of you should benefit! :)

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

Re: RPi Cam Web Interface

Fri Apr 17, 2015 11:13 am

morticiaskeeper wrote:Yes, i worked that out.

I've put the old files back in and it works perfectly.
At the moment I'm struggling to see why there is any significant difference between old files and new ones if Default streaming is in operation.

If you want to keep trying here is a test index.php that logs the streaming mode it is going to ask for (visible under scheduler show log) and also is hard wired to use Default Streaming no matter what. So you can still select MJPEG and Default but under the hood it always uses Default.

The log should show Using Streaming mode 0 after Default is selected and Using Streaming mode 1 after MJPEG is selected

The script file included is unchanged from the release version as it is just always being told to use Default.

jarrah31
Posts: 125
Joined: Wed Oct 10, 2012 10:16 am

Re: RPi Cam Web Interface

Fri Apr 17, 2015 11:18 am

btidey wrote:Now incorporates changes from pyjamasam (thanks) which means the main preview image is a mjpeg stream rather than image fetches.

css tweak included to hopefully resolve problem with input of settings from some browsers.
I use iSpy Connect to manage multiple RPi Cam streams by monitoring the preview stream for motion. It's not the best solution due to the lack of quality streaming offers, but I like how I can specify portions of the screen to monitor movement and view all camera feeds/videos from one web interface.

So far I've been using the following within the JPEG URL video source which streams around 5fps:

http://<ip>:<port>/cam.jpg

Now that you've implemented an MJPEG stream, do you know how I can make use of that stream externally? iSpy has an MJPEG URL tab as a vid source, but I can't get that to work with either the IP, http and IP, or cam.jpg...

No worries if not, I just thought I'd explore using this new streaming method.

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

Re: RPi Cam Web Interface

Fri Apr 17, 2015 11:51 am

jarrah31 wrote:
Now that you've implemented an MJPEG stream, do you know how I can make use of that stream externally? iSpy has an MJPEG URL tab as a vid source, but I can't get that to work with either the IP, http and IP, or cam.jpg...

No worries if not, I just thought I'd explore using this new streaming method.
viewtopic.php?f=43&t=63276&start=1867

jarrah31
Posts: 125
Joined: Wed Oct 10, 2012 10:16 am

Re: RPi Cam Web Interface

Fri Apr 17, 2015 12:00 pm

btidey wrote:
jarrah31 wrote:
Now that you've implemented an MJPEG stream, do you know how I can make use of that stream externally? iSpy has an MJPEG URL tab as a vid source, but I can't get that to work with either the IP, http and IP, or cam.jpg...

No worries if not, I just thought I'd explore using this new streaming method.
viewtopic.php?f=43&t=63276&start=1867
doh! Missed that one... :) I'll pop it on the wiki.

Thanks!

silvanmelchior
Posts: 76
Joined: Mon Nov 25, 2013 5:56 pm

Re: RPi Cam Web Interface

Fri Apr 17, 2015 12:59 pm

jarrah31 wrote:Hey Rob, having just looked at the first post, you should have a bitcoin or PayPal donate button as well what with all the work you're putting into this...

Perhaps the two could go on the wiki? Or maybe as part of your signature?

Full respect to Silvan and all the work he has put into this, but you helped revitalise this project and have been a constant presence, helping others and updating the program! Both of you should benefit! :)
Moved my infos to the wiki, so you can add yours ;)

toadleyb
Posts: 21
Joined: Sat Jan 04, 2014 11:05 pm

Re: RPi Cam Web Interface

Fri Apr 17, 2015 2:14 pm

Thanks for this awesome piece of software. I have a couple of questions.

What is the unit of measurement for the max_capture setting? Is it minutes, seconds, hours? I have tried deleting the ca 0 from the motion stop setting in the scheduler and setting the max_capture at 1 and at 30. Nothing seems to happen the video just keeps recording. The only way to stop it is to change the settings back and reboot the pi.

Also the download zip does not seem to work. The progress bar pops up but never does anything.

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

Re: RPi Cam Web Interface

Fri Apr 17, 2015 3:01 pm

toadleyb wrote:Thanks for this awesome piece of software. I have a couple of questions.

What is the unit of measurement for the max_capture setting? Is it minutes, seconds, hours? I have tried deleting the ca 0 from the motion stop setting in the scheduler and setting the max_capture at 1 and at 30. Nothing seems to happen the video just keeps recording. The only way to stop it is to change the settings back and reboot the pi.

Also the download zip does not seem to work. The progress bar pops up but never does anything.
Max_Capture is in seconds. 0 means no maximum. It is maybe a slightly misleading name as it means maximum period from a motion start trigger to a motion off trigger. It doesn't apply to any manually started captures as these are not going through the scheduler.

You can't test this by deleting ca 0 from the off as this setting is what the scheduler will send if Max_Capture is exceeded. It is done this way so you can vary the commands that are sent when motion stops and starts; so for example you could trigger time lapse on and time lapse off.

Note that if you get stuck like this then you could manually send in a stop (echo -n 'ca 0' >/var/www/FIFO) . Maybe we should make Stop camera bail out of anything. Currently the button is disabled in recording mode.

This is what I got in the log when I set a Max_Capture of 6 and set of a motion trigger that was lasting a long time.

Code: Select all

[2015/04/17 15:40:43] Start capture requested
[2015/04/17 15:40:43] Send ca 1
{2015/04/17 15:40:43} Capturing started
[2015/04/17 15:40:51] Maximum Capture reached. Sending off
[2015/04/17 15:40:51] Send ca 0
{2015/04/17 15:40:52} Capturing stopped
I have noticed the timing is not brilliantly accurate as it is accumulating counts. I should be able to improve this.

On the zipping issue, I believe there was a problem with the installer setting the execution privilege of the zipping script which I think silvan spotted and corrected a couple of days ago. You can correct this manually if you installed before this by doing a sudo chmod 755 /var/www/raspizip.sh

The zipping on the pi is also not fast doing about 1.3MB per second (Pi 1). So if say a 30MB video is first file then it could take 25 seconds for the first step in progress bar to appear (1 step per file added). I am planning to change it so the steps are as each file starts; that way the progress bar will at least update with 1/n immediately.

toadleyb
Posts: 21
Joined: Sat Jan 04, 2014 11:05 pm

Re: RPi Cam Web Interface

Fri Apr 17, 2015 3:10 pm

So if I wanted all videos to be 30 seconds long on motion capture do I need to change anything other than setting max_capture at 30?

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

Re: RPi Cam Web Interface

Fri Apr 17, 2015 3:42 pm

toadleyb wrote:So if I wanted all videos to be 30 seconds long on motion capture do I need to change anything other than setting max_capture at 30?

You can achieve that by setting motion to send just a start trigger and not a stop trigger. That way scheduler will receive the start but will never get a stop and therefore will time out on max capture.

So edit motion settings on_event_end to blank, or if you want it logged when motion sent a stop then you could change the 0 to say X You will then get a log message like Ignore FIFO char X but it won't action a stop action.

toadleyb
Posts: 21
Joined: Sat Jan 04, 2014 11:05 pm

Re: RPi Cam Web Interface

Fri Apr 17, 2015 4:29 pm

btidey thanks for the quick answers your suggestions did what I was looking for. Loving this software!

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

Re: RPi Cam Web Interface

Fri Apr 17, 2015 5:57 pm

btidey wrote:
I have noticed the timing is not brilliantly accurate as it is accumulating counts. I should be able to improve this.

On the zipping issue, I believe there was a problem with the installer setting the execution privilege of the zipping script which I think silvan spotted and corrected a couple of days ago. You can correct this manually if you installed before this by doing a sudo chmod 755 /var/www/raspizip.sh
I have improved the timing accuracy of the scheduling loops so for example a MAX_CAPTURE should be close to the value set.

The Get Zip now progress steps before each file is zipped so 1/n should appear straight away and n/n (100%) will stay up whilst last file is added.

Blairvoyach
Posts: 5
Joined: Sun Jun 24, 2012 11:00 am

Re: RPi Cam Web Interface

Fri Apr 17, 2015 6:04 pm

Can I just give a massive thank you to everyone involved in this project. This is my first time using my Raspberry Pi for anything more than getting to know Linux a little better. Once I'd worked out how to clone the git files it installed and worked first time and the quality of the whole package, camera and software just blew me away.

Outstanding work, really.

Regards to all,
Jeff.

morticiaskeeper
Posts: 101
Joined: Mon Aug 27, 2012 6:05 pm

Re: RPi Cam Web Interface

Fri Apr 17, 2015 6:22 pm

[quote="btidey"

If you want to keep trying here is a test index.php that logs the streaming mode it is going to ask for
[/quote]

Hi Robert

I can't see the index file

cormad
Posts: 27
Joined: Mon Jan 19, 2015 1:59 pm

Re: RPi Cam Web Interface

Fri Apr 17, 2015 8:03 pm

please see answers in RED I am running windows 7 and Chrome
btidey wrote:
cormad wrote:Would love to get this working :)

I followed the instructions to a T. After I reset and installed and reset again I went to my IP and just get a blank page. I can still Putty and winSCP into my pi.

Any ideas what I missed or need to configure?

Thanks
You shouldn't need to configure anything to get started. If you get a blank screen rather than a host unavailable message then that would indicate that Apache is running and browsing to your pi camera should fetch the index.php page.

What browser / platform are you using to browse from?

Few basic checks.

If you WInScp to /var/www you should see a bunch of files including index.php and js and css folders. Yes I see these files and folders

Use putty to show what is running (ps -A) The list should include some apache2 items and raspimjpeg 2004 ? 00:00:06 apache2
2038 ? 00:00:00 apache2
2039 ? 00:00:00 apache2
2040 ? 00:00:00 apache2
2041 ? 00:00:00 apache2
2042 ? 00:00:00 apache2
Do not see raspimpeg


Try browsing to http://cameraIP/Copyright.txt Replace cameraIP with real IP. That should show just a copyright piece of text and shows the basic web server side is functioning.
Not Found

The requested URL /Copyright.text was not found on this server.

Apache/2.2.22 (Debian) Server at 192.168.1.106 Port 80

cormad
Posts: 27
Joined: Mon Jan 19, 2015 1:59 pm

Re: RPi Cam Web Interface

Fri Apr 17, 2015 8:25 pm

Hey btidey,
I also receive the following error on startup
[....] Starting web server : apach2apach2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for serverName

[warn] Not starting daemon, disabled via /etc/default/motion ...(warning)
btidey wrote:
cormad wrote:Would love to get this working :)

I followed the instructions to a T. After I reset and installed and reset again I went to my IP and just get a blank page. I can still Putty and winSCP into my pi.

Any ideas what I missed or need to configure?

Thanks
You shouldn't need to configure anything to get started. If you get a blank screen rather than a host unavailable message then that would indicate that Apache is running and browsing to your pi camera should fetch the index.php page.

What browser / platform are you using to browse from?

Few basic checks.

If you WInScp to /var/www you should see a bunch of files including index.php and js and css folders.

Use putty to show what is running (ps -A) The list should include some apache2 items and raspimjpeg

Try browsing to http://cameraIP/Copyright.txt Replace cameraIP with real IP. That should show just a copyright piece of text and shows the basic web server side is functioning.

0lly
Posts: 77
Joined: Sun Mar 02, 2014 5:07 pm

Re: RPi Cam Web Interface

Fri Apr 17, 2015 8:42 pm

cormad wrote:I also receive the following error on startup
[....] Starting web server : apach2apach2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for serverName

[warn] Not starting daemon, disabled via /etc/default/motion ...(warning)
This are only warnings,no errors.
I have the same messages but RPi Cam Web Interface works perfect here.

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

Re: RPi Cam Web Interface

Fri Apr 17, 2015 8:44 pm

index.zip
index
(4.33 KiB) Downloaded 66 times
morticiaskeeper wrote:[quote="btidey"

If you want to keep trying here is a test index.php that logs the streaming mode it is going to ask for
Hi Robert

I can't see the index file[/quote]

Oops. I keep adding the file but its not getting added for some reason. Now it's gone in
Attachments
index.zip
(4.33 KiB) Downloaded 65 times

Return to “Camera board”