Surveillance through Arduino and Web - php

I wanted to ask if it is possible to send the video feed from a camera to an Arduino board, and through the ethernet sheild send it to an Apache web server, and then displaying it on the browser in some form. I am not trying to transmit the audio and video together, just the video. Audio is not my concern at all..
I have seen people sending JPEG images across the web but never a video. I am new to both the web and arduino, so i don't even know if it is simple enough to send live streams through a web server even without using the Arduino and using a PC instead. If it is possible, i would be much obliged if a link is provided to the possible php/html functions that might be used for this task, as these are the only web languages that i use.

It is not possible since all Arduino boards have very weak processing power to handle video streaming.
Also, data cant be transfered through the serial link fast enough and there is not enough SRAM space to buffer the frames.
Personally, i recommend trying Raspberry PI + Motion for live streaming video.
If you want to stick with Arduino, the upcoming Tre board i think will be able to do such a job, but it will be way more expensive than the PI solution.
Check these links:
Raspberry PI webcam server tutorial
Raspberry Pi remote webcam

Related

How can I stream live webcam video using Adobe flex without using Flash server or Red5?

My hosting service doesn't allow Flash server or Red5 to be used on the shared hosting account, only with a VPS account. This is something, I do not want to pay for. I have managed to create a MXML application and successfully compile it into a .SWF file that will grab the user's live cam. Now the problem I'm having is displaying that webcam to other users. So I'm assuming I need some sort of server to send that video to, so that I can connect to it, and then display the stream. Now my question is, is there a work around in which I don't need another server, such as Red5 or Flash server? Why can I not handle the live webcam myself and display the live stream using ActionScript3.0?
Go for Adobe Cirrus as Reboog711 mentioned. Its a peer-2-peer protocol.
Well to answer your questions..
is there a work around in which I don't need another server, such as
Red5 or Flash server?
Yes, you don't need any servers involved here. Just connect to the service and get a token id. Exchange that token id with your remote end user and do the vice-versa, such that both of you can able to see yourselves.
Why can I not handle the live webcam myself and display the live
stream using ActionScript3.0?
Who said you can't ;) ? You can very well control the settings including the webcam video size, aspect ratio, quality, bandwidth , etc everything using your actionscript 3.0.

Live video stream from android mobile to desktop web browser

I have to develop an application that will record video and audio on desktop browser and android smartphone and share it between them. Just like the skype video call.
The application will consist of three subapplications on these three platforms:
smartphone (android java)
web server (apache + php)
destkop web browser (html5 + javascript + css)
Could you recommend me any libraries that could help me on these platforms
(smartphone, web server, web browser)?
Will I be able to maintain all the work on web server just by
php (user logging, video streaming, ...)?
Will I be able to maintain video record and playback in web browser
just by html5 + js or do I need to use flash/silverlight?
What things will web server need to do? Just store the video stream
somewhere in memory and then send it (forward) to web browser? Could you describe how should this work in more deeply?
What should I start with? Thank you
For this, you will have to use RTSP(Real Time Streaming Protocol),try learning this and for details you can check this link

Multiple Webcam surveillance within a browser?

I want to create a web application (I am quite good with PHP) that captures webcam shots every 1 minute from different persons that open the application page and sends it via smthng to the web/ftp server.
I mean PC1, PC2 and PC3 opens the web aplication, their webcam it's opened and it captures images every 1 minute so PCSERVER should be able to see the persons behind the webcam "realtime".
I read about Flash Video Server (hope I am quite around the words) but it's purchasable solution and I want to redistribute the application freely.
Any ideas how should I do this?
EDIT:
If I am required to learn another programming language such as ActionScript, I don't mind, but if I am going to learn that, it should resolve my problem.
For video capture and video sharing, you need something like Adobe's Flash Media Server or the open source alternative Red5, that Johni mentions, but since you say you only need "shots every minute", not video, it could also be done without a streaming media server, only the Flash based client and PHP on the server.
What you could do instead of video is capture bitmap images from the web camera, using Flash/ActionScript, encode that bitmap image as JPEG or PNG and upload the image to the server by POSTing it to a PHP page.
It would require more code that fits in a SO Q&A, but you can easily find examples for the different steps of the process - access the web cam - get bitmap image - encode bitmap - POST encoded image top PHP from ActionScript.
The Red5 Media Server is a good open source alternative to the Flash Media Server:
http://red5.org/
It is programmed in Java.

How to record voice files using PHP, FLASH

I am developing an application where I need to record voice(for those who does not have a webcam so they can use only microphone to record voice) or video(those who have a a webcam - like laptop or external) files and save them on server, thereafter save the file name and logged in users id on database for later access.
I know I need to use some sort of flash app for this. But is there any free one which could server this purpose or even if there are paid ones which could serve this purpose that would be great. I tried google but may be I was not being able to go after the proper term or something, I could not succeed finding a proper solution for this.
Please, help me out!
You can do that simply using jRecorder, a jQuery plugin. You don't even need a Flash Media Server or RED server. JRecorder is same as jPlayer, you can use jQuery and HTML to design your recorder and you don't even need Flash or Action script knowledge for this.
jRecorder uses 1 pix hidden swf file which manages all the recording / previewing and sending the file data (wav file) to a URL you defined (Where you can write code in PHP or Java to receive a POST file)
It is quite simple and tidy.
You can download this Plugin from:
http://www.sajithmr.me/jrecorder-jquery
I have same feature in our latest project, the client want to have video recording from webcam and the video appear in the user's profile page.
For the server, we implement the RED5 server. It need a Java virtual machine in your hosting. You can read the detail requirement and installation instruction in the website.
To handle recording, we develop our own flash application, because the client request a custom interface to match with the overall website interface. I don't know the detail, since we outsource it to a fellow flash developer. Maybe you can see follow this thread, the development of flash recording by JeroenW.
To play recorded video, you can use any flash video player that support playing rtmp video source. You cannot play the recorded flv file in RED5 directly, since the file lack of metadata required by the player. Serving the recorded file as rtmp is done by RED5.
In addition to red5 there is Adobe's own Flash Media server that allows you to record audio/video straight to the server.
Or if you feel geeky you might be able to put together your own solution for this using a socket connection to the server and decoding the stream yourself on the server side. You should be able capture the audio/video locally into memory and then feed the byte stream up to your own server application.
There are Open Source solutions but you will need an own server to run them.
There is no way to run these things from shared hosting except if your provider is really nice, and ready to install the necessary software.
I asked the same question a few weeks back, check out the answers.
This question when googling "How to record audio php" comes up first so here for anyone from the future.
A simple way to record audio with flash and save it with PHP:
https://github.com/clouddueling/SimpleRecorder
Record audio, post audio data to your choice of url.
You could try recordmp3online.com which has an SDK. The nice thing about this one, is that it doesn't need a third party server(ala Red5), and supports mobile devices that don't have flash installed.

Live Video Streaming with PHP

I have a PHP/AJAX/MYSQL chat application. I want to add video chatting to my application. How can I create live video streaming to be used for live video conferences/chatting in a PHP application. What are the key-terms I need to know if I wanted to build such a system? Is it a good idea in the first place to use PHP? Is there something I'm not thinking about? What other languages can I use, perhaps in conjunction with PHP?
I am not saying that you have to abandon PHP, but you need different technologies here.
Let's start off simple (without Akamai :-)) and think about the implications here. Video, chat, etc. - it's all client-side in the beginning. The user has a webcam, you want to grab the signal somehow and send it to the server. There is no PHP so far.
I know that Flash supports this though (check this tutorial on webcams and flash) so you could use Flash to transport the content to the server. I think if you'll stay with Flash, then Flex (flex and webcam tutorial) is probably a good idea to look into.
So those are just the basics, maybe it gives you an idea of where you need to research because obviously this won't give you a full video chat inside your app yet. For starters, you will need some sort of way to record the streams and re-publish them so others see other people from the chat, etc..
I'm also not sure how much traffic and bandwidth this is gonna consume though and generally, you will need way more than a Stackoverflow question to solve this issue. Best would be to do a full spec of your app and then hire some people to help you build it.
HTH!
Please note that the below described service is no longer available as
it was based on FLV media (Flash)
This project which utilizes the Red5, Flex and PHP for Live Video Streaming and Recording has many features
Stream Live video to the viewers
Record the streams from your cam or other video input devices to the server
Preview the recorded streams and files and thumbnail the frame which you would like to display for the video.
Upload the videos from your computer and convert them to FLV which can be streamed using Red5 .
Choose from any resolutions
Can be plugged to any script
Each website user can have a separate Directory for storing their videos and thumbnails use this link
http://code.google.com/p/red5-flex-streamer/
PHP will let you build the pages of your site that make up your video conferencing and chat applications, but it won't deliver or stream video for you - PHP runs on the server only and renders out HTML to a client browser.
For the video, the first thing you'll need is a live streaming account with someone like akamai or the numerous others in the field. Using this account gives you an ingress point for your video - ie: the server that you will stream your live video up to.
Next, you want to get your video out to the browsers - windows media player, flash or silverlight will let you achieve this - embedding the appropriate control for your chosen technology into your page (using PHP or whatever) and given the address of your live video feed.
PHP (or other scripting language) would be used to build the chat part of the application and bring the whole thing together (the chat and the embedded video player).
Hope this helps.
PHP/AJAX/MySQL will not be enough for creating the live video streaming application There is a similar thread here. It primarily suggests using Flex or Silverlight.
For live video conferencing you can't ignore the need of a streaming server.
Yes, flash will let you display video from a webcam within the local flash control, but that won't let you then send that video over the network - for that you need a streaming server to send it to.
If you're going to build something like this it's prudent to think about how you're going to host the video from a very early stage as it will influence how you build the application. Flash/Flex/Silverlight/Windows Media....etc....
There are a lot of "off-the-shelf" 'servers' that will run in your environment.
Most of these utilize the aforementioned Flex or Silverlight to implement the actual video itself but I'm pretty sure all will run under LAMP/PHP.
The challenges will picking the best software from everything that's available and getting your hosting-provider to let you stream video (it goes without saying that streaming is heavy on bandwidth).
You can easily build a website as per the requirements. PHP will be there to handle the website development part. All the hosting and normal website development will work just as it is. However, for the streaming part, you will have to choose a good streaming service. Whether it is Red5 or Adobe, you can choose from plenty of services.
Choose a service that provides a dedicated storage to get something done right. If you do not know how to configure the server properly, you can just choose a streaming service. Good services often give a CDN that helps broadcast the stream efficiently. Simply launch your website in PHP and embed the YouTube player in the said web page to get it working.
Same problem/answer here, quoted below
I'm assuming you mean that you want to run your own private video
calls, not simply link to Skype calls or similar. You really have 2
options here: host it yourself, or use a hosted solution and integrate
it into your product.
Self-Hosted
----------------- This is messy. This can all be accomplished with PHP, but that is probably not the most advisable solution, as it is
not the best tool for the job on all sides. Flash is much more
efficient at a/v capture and transport on the user end. You can try to
do this without flash, but you will have headaches. HTML5 may make
your life easier, but if you're shooting for maximum compatibility,
flash is the simplest way to go for creating the client. Then, as far
as the actual server side that will relay the audio/video, you could
write a chat server in php, but you're better off using an open source
project, like
janenz00's mention
of red5, that's already built and
interfacing with it through your client (if it doesn't already have
one). Or you could homebrew a flash client as mentioned before and
hook it up to a flash streaming server on both sides...either way it
gets complicated fast, and is beyond my expertise to help you with at
all.
Hosted Service
----------------- All in, my recommendation, unless you want to administer a ridiculous setup of many complex servers and failure
points is to use a hosted service like
UserPlane or similar and offload all the
processing and technical work to people who are good at that, and then
worry about interfacing with their api and getting their client well
integrated into your site. You will be a happier developer if you do.

Categories