Getting Foscam IP Cameras to work from Linux (Ubuntu)

As with most hardware manufacturers of hardware Foscam utility software is Windows or Mac only. The actual unit tested with the below is a FI9805E Outdoor POE camera.

Foscam Outdoor Cam

Installation

The installation is relatively painless as the unit is set up to get the IP assignment via DHCP (check your routers DHCP assignment list).

https://IP.ADDRESS.OF.CAM

should get you to the web-admin interface. The default user is ‘admin’ with no (empty) password.

Taking snapshots

http://IP.ADDRESS.OF.CAM:PORT/cgi-bin/CGIProxy.fcgi?cmd=snapPicture&usr=username&pwd=password

I had some issues with the color of the images in daylight (which for an outdoor camera is not really a good thing. A Firmware update (V2.14.1.5) improved this (you can disable the IR LEDs during daylight hours). Thanks for FOSCAM UK support via Twitter I found the download URL as the main site seems to have been down for a while.

Firmware URL: http://foscamuk.co.uk/downloads/

Streaming in H.264 video

The easiest way to get the stream appears to be the RTSP connection (using VLC or any network video player). MXPlayer on Android works very well too.

rtsp://username:password@IP.ADDRESS.OF.CAM:PORT/videoMain
rtsp://username:password@IP.ADDRESS.OF.CAM:PORT/videoSub
rtsp://username:password@IP.ADDRESS.OF.CAM:PORT/audio

Streaming in MPEG mode

The be able to use the MPEG streaming the stream format needs to be set first.

http://IP.ADDRESS.OF.CAM:PORT/cgi-bin/CGIProxy.fcgi?&usr=username&pwd=password&cmd=setSubStreamFormat&format=1
http://IP.ADDRESS.OF.CAM:PORT/cgi-bin/CGIStream.cgi?cmd=GetMJStream&usr=username&pwd=password

Resetting back to H264:

http://IP.ADDRESS.OF.CAM:PORT/cgi-bin/CGIProxy.fcgi?&usr=username&pwd=password&cmd=setSubStreamFormat&format=0

Next steps will be to make this work from a headless device with an Amazon S3 storage backend. This Github project https://github.com/phil-lavin/Foscam-FI8908W-Recorder is looking promising.

Watch this space.

17 thoughts on “Getting Foscam IP Cameras to work from Linux (Ubuntu)

  1. Pingback: March 24, 2015

  2. The camera’s webinterface is telling me to install a plugin (exe file). I’ve read that it works without the plugin on some browsers. What browser did you use or how did you get past that?

  3. The problem now is that you cannot even login to the admin interface for at least some Foscam cameras without a browser plugin.

    I just bought a new Foscam FI9831P camera. The web admin interface on port 80 has been disabled, now it is on port 88, which is fine. When I go to http://:88, I do get the login screen, but when I try admin and blank password, it tells me I need a plugin. Just to login!

    The plugin it tries to download is IPCWebComponents.exe. That runs on Windows, but not on Linux. Apparently, there is a respective plugin that works on OSX. Plus, Foscam now has apps which run on Android and iOS.

    But why in the world would Foscam move “backwards” and now require a browser plugin just to configure their cameras??? Sure, the camera interfaces do a lot more now like merge multiple camera video streams into one interface, which is cool. But why not move away from plugins in favor of a universal HTML5 interface? Even Windows 10’s new Edge browser does not support plugins.

    Come on, Foscam. It’s 2015, not 2000!

  4. Nice article, many thanks. Works well with the FI9853EP, except the Installation wants to install an *.exe file and for Installation I had to run IE in Windows

  5. Neither rtsp or Webstreaming works :(
    rtsp can’t login, Webstreaming reloads. Browser ist telling me, device is busy. Any Ideas?

  6. I just bought the new nvr FN3109H running well with my FI8918W cameras, but indeed when I want to login on the web interface I need to install a windows plugin! The whole reason I bought this nvr was because they said it should be compatible with other browsers then Explorer like Safari for which they have a plugin.

    If anyone has a solution i would love to hear it!

  7. YES !!!

    I have just installed the newest Crossover version 15.0.1 and on it Firefox and with that I was able to install the needed plugin!
    It al works!!!

    And for some additional info, Foscam says that their web interfaces only works on 32 bit browser versions a bit old fasion of course, but I am running currently a 64 bits OS and all works just great.

    So for those who need camera to work maybe this works also, it works for the nvr.

  8. Thanks Gaggl,
    Using Linux Mint here. And a fi9900p camera. Want to record on a Qnap Nas using “Surveillance Station”. To view it asks to install a Windows exe-file. No dice.
    Your method worked directly for me. Taking a snapshot works in Opera. Snapshot and live streaming works in Mozilla Firefox using VLC. When asked the program is /usr/bin/vlc.
    ***
    Hopefully the Surveillance station will get better…
    It is a little bit ridiculous. The plugins in Firefox are
    * “OpenH264 Video Codec”
    * “Shockwave Flash”
    * “DivX Web Player”
    * “QuickTime Plug-in”
    * VLC Multimedia Plugin”
    * “Windows Media Player Plug-in”
    Thanks, Martin

  9. Simple and… “just what I needed”! :)
    Thanks Leo Gaggl for the tutorial, and thanks to Martin for the extra infos too!

  10. With the new interface on the FI9800P I found the easiest way to log in was to use VirtualBox with a WinXP guest, download Firefox within that (Chrome won’t accept the plugin) and use that. Too bad there isn’t a better Linux solution.

  11. Why not wine?
    With a windows virtual machine you allways have to get the os license to use it.
    My problem, now solved: I was not able to login to the gui of my fi9831.
    I used the following procedure to get it work: I run ubuntu 16.04, install wine program (it can execute .exe emulating a windows environment), get Firefox v.34 32bit for windows (the newest firefox version are not supported by wine, it miss a dll). After this, Install Firefox.exe with wine, download the exe plugin and install it in the same way.
    Now I can access to the gui in linux through Firefox 4 windows browser. Streaming video and cruise still not working (I use an android app to do this) but now I can access to the advanced configuration of the cam.
    Have a go
    Marco

  12. Not a fan of WINE – if I really need to run windows I rather fire up a Win7 VPS in VirtualBox. But can’t remember the last time I had to do this. Also running outdated browser versions is not really something I want to do

  13. I suspect success on this depends on how recent the firmware is that is on the camera. Not sure if the snapshot works, but the rest didn’t for me. Really disappointing for a company to take advantage of a linux base to operate the camera, an open source spec. for the stream (H264), then turn around and require a windows dll (plugin my buttocks, it’s not a plugin if it installs to c:/windows/system32) to connect to the open source web server’s interface. Just seems rude to me.

  14. I have the same problems with my Foscam camera’s and this is for me the reason that my next camera is not a Foscam.

Leave a Reply