Having Fun on ViewSurf
The raison d'être of ViewSurf is to give surfers access to up-to-date on-line weather reports. Classic weather report information is provided, such as temperature and wave status, but the bonus is an up-to-date video that gives the surfer a current picture of what is happening at his favourite beach.
I met the creator of ViewSurf (Nicolas Saubade) during the summer of 1996. Nicolas works for COM1 in Cestas near Bordeaux, France. COM1 is a very famous company in France because it's the foremost modem manufacturer in Europe even though most COM1 modems are not distributed under its own label. Additionally, COM1 develops and distributes the ViewCOM, a high performance video compressing system used in many security applications (see Figure 1).
The ViewCOM uses a standard video input, such as a video camera or any PAL/SECAM/NTSC source, and converts this source to a proprietary format based on the JPEG compression algorithm. This format is called VCR, and the conversion can be achieved in real-time. The ViewCOM includes a V34 PC-Card modem, so it is typically installed on a foreign site and called by specialized software running under Microsoft Windows (ViewCOM Manager) via a simple phone line.
ViewCOM firmware includes a recording function to create a compressed video sequence and send it to the caller via modem. The size of each sequence is 100KB to 400KB and running time is 1 or 2 minutes of video.
The basic configuration of the ViewSurf service is quite simple (see Figure 2). Each site has a video camera connected to a ViewCOM. The ViewCOM is directly accessible via modem. The caller records a short film segment and uploads it to a web server. For the Beach Report, this operation occurs about three times a day. The browser on the client side must download a plug-in from the COM1 web site in order to display VCR sequences. This plug-in originally existed only for Microsoft Windows and Macintosh, so I wrote a UNIX/Linux version which is now on the COM1 site (available for Linux ELF, Solaris and SunOS).
Nicolas wanted to install several sites, but it was quite difficult to manage because the ViewCOM Manager, a nice graphical program, is not really programmable—the problem with most Windows applications. He had to manually call four sites, three times a day, seven days a week—not an acceptable situation.
I proposed to him that Linux be used to automate the process. I wrote some simple shell scripts to call each site, create and download the film and copy it to the main web server (an SGI Indy) using the rcp command. Most of these scripts are based on the chat program. The download portion was written in C to keep up with the high speed on the serial line (57,600 or 115,200Kbps).
I know rcp is not the best solution; Linux is a very good web server system in its own right, but the SGI was already in place. Film is integrated in ViewSurf pages with HTML code such as:
<EMBED SRC="http://your_linux_server/films/film.vcr" WIDTH=320 HEIGHT=40>
Actually, using rcp requires no HTML modification in the existing pages, which is an advantage, so we opted to stay with it.
The main shell scripts, including dial up to a group of sites, are simply activated by a crontab entry. Additionally, these scripts give some statistics about ViewCOM access in order to detect any problems.
This project was not an official COM1 project, so the software was installed on a very old DX2/66 running Slackware 3.0. We had to buy a new 16550A-based ISA card for the serial line.
The ViewCOM Manager was no longer needed for ViewSurf. Nicolas was surprised by the power of Linux—all I had to do to solve a problem was write some shell scripts using standard Linux commands, which would have been very difficult and costly to implement in Windows. Some months later, Nicolas created a Snow Report, which is a service for skiing information comparable to the Beach Report. Last winter, 3 ViewCOMs were installed in the French Pyrénées mountains.
Nicolas has written some additional HTML pages in order to make the service more attractive, and ViewSurf now includes interesting links to fun sites and tourist WebCAMs all around the world. A specific domain now exists for ViewSurf (viewsurf.com), and the service is available (in French) at http://www.viewsurf.com/. Figure 3 is an example of a ViewSurf page. Don't forget to download the VCR plug-in.
Actually, the Linux PC is very efficient and robust. The last time I had to reboot it was to install a new kernel version.
|September 2015 Issue of Linux Journal: HOW-TOs||Sep 01, 2015|
|September 2015 Video Preview||Sep 01, 2015|
|Using tshark to Watch and Inspect Network Traffic||Aug 31, 2015|
|Where's That Pesky Hidden Word?||Aug 28, 2015|
|A Project to Guarantee Better Security for Open-Source Projects||Aug 27, 2015|
|Concerning Containers' Connections: on Docker Networking||Aug 26, 2015|
- Optimization in GCC
- Using tshark to Watch and Inspect Network Traffic
- September 2015 Issue of Linux Journal: HOW-TOs
- Problems with Ubuntu's Software Center and How Canonical Plans to Fix Them
- Concerning Containers' Connections: on Docker Networking
- A Project to Guarantee Better Security for Open-Source Projects
- Firefox Security Exploit Targets Linux Users and Web Developers
- Where's That Pesky Hidden Word?
- My Network Go-Bag
- Doing Astronomy with Python