WA Brand Logo
Published: June 11, 2022

Videotestimony for Condominiums - Tutorial #3

Installation of the recorder box

After the camera, it is the recorder box, also called NVR (Network Video Recorder), which must be mounted and configured, in order to have a functional videotestimony system.


Components of the recorder box

For the recording and encryption of videos from the camera, everything relies on a minicomputer called Raspberry Pi.

You can use a Raspberry Pi 3B, 3B+, or 4 ; the main thing is that it has an Ethernet port, and at least 1 GB of RAM (Random Access Memory).

For the E-Paper display (also called E-ink), we recommend the Waveshare 2.7 inch E-Paper Display Hat (black&white), which has the same format as the Raspberry Pi 3/4, and has 4 programmable buttons.

Finally, for the RTC RTC (Real Time Clock) card - which will maintain the current time in case of system shutdown - we recommend an "RTC PiZero addon", in PHAT format, which is easier to insert in the case than an RTC mini-card in another format. Some E-Paper screens or additional extension cards (battery backup...) sometimes contain an RTC module. In any case, it is preferable to use an RTC compatible with the i2c-rtc/ds1307 system modules (or overlays) of the Raspberry Pi.

The above hardware is officially supported by the system image we provide. But it is possible to use a quite different hardware environment, if you can adapt the software configuration accordingly. For example, a different clock card (e.g., a high precision ds3231) will just require a different configuration of the Raspberry Pi operating system, but a different E-Paper display will require coding a new extension for our Witness Angel NVR recording software.

To assemble the case, simply stack the Raspberry Pi, the clock card, and finally the digital paper screen.

For storing encrypted video containers, you should avoid using the MicroSD card containing the operating system, since it does not like to be written to too much - it wears out prematurely; it is better to plug in a USB key with a large memory capacity, or an external SSD disk, preferably self-powered (as you should not ask too much power from the Raspberry Pi). Beware, small USB sticks can get very hot under continuous use, so it is better to use a long stick with good heat dissipation.

Finally, to power the Raspberry Pi, prefer a high quality USB charger to avoid any under-voltage that could, in the long run, harm the reliability of the system.


Installation of the operating system

Like a PC, the Raspberry Pi needs an operating system to run; usually the "Raspberry Pi OS" distribution based on Debian Linux is used, although many others are possible. And you need to add all the software components to run the clock card, the digital paper screen, and the Witness Angel NVR recording software.

Two possibilities for this step of the preparation of the recorder box:

  • Either you install the whole system from scratch, using the steps in our Ansible configuration recipes
  • Or, if all your hardware is compatible, you simply use a system image that we provide. That is, a complete copy of the memory card, containing both the preconfigured operating system and the recording software.

It is the second solution that we will focus on here.

For that, it is necessary to download and burn the system image by following the instructions from the page of the Recorder application.

When the memory card is ready:

  • Insert the memory card into the Raspberry Pi
  • Connect the box to the camera via the Ethernet cable
  • Connect the box to a monitor/keyboard/mouse kit (this may require microHDMI/miniHDMI/HDMI adapters)
  • Connect the box to electricity to start it.


Software configuration

Once started, the Raspberry Pi should display the Raspberry Pi OS desktop interface.


Initial verification of the system

First of all, it is interesting to check that everything is operational in the system.

  • Open a terminal (or "shell"), and type in the command "ifconfig" (then press "enter"). If the network cable is well connected to the camera, the fixed IP address of the Raspberry Pi should appear in the text displayed.
  • Type in the web browser of the Raspberry PI, the address of the web interface of the camera, based on the fixed IP you had given it; you must have access to this interface.
  • Test the network stream with the VLC video player included in the Raspberry Pi system; to do this, go to the VLC menu, section "Media > Open network stream", and enter the complete url "rtsp://...". The video from the camera should be displayed. And the time/date displayed on it must be correct (otherwise, there is a problem with the NTP system).

Warning: It is possible that the video displayed by VLC may be altered/grayed/scaled if it is too high quality for the power of the Raspberry Pi, in which case it will show up in the stream statistics ("Tools > Current Media Information > Statistics"), but the recording should still work, as it doesn't need to unpack and display the video

Now launch the WitnessAngel-NVR application from the desktop icon. This will open a black console with debugging information (just in case), and the graphical interface of the application.

Before you can start recording, thanks to the big button on this main page, you have to set up the software, in two main steps:

  • Provide the "key guardians" to be used to secure the records
  • Configure the different addresses and options of the software


Configuration of the key guardians

For the first step, you have to go to the menu of the application, and choose the heading "Key Guardians". The list is initially empty.

For this tutorial, we will use an import by USB key: insert in the Raspberry Pi the USB keys containing the "authenticators" (digital identities) of your key guardians, and click on the "Import from USB" button.

It is then necessary to choose between importing only the public keys of the authenticators - those necessary to encrypt the records - and also importing the private keys - which allows the software to be used later as a decryption station, in case of an incident in the condominium. By default, even if the private keys are protected by "secret phrases", it is better to import only the public keys, for security reasons. There will always be time to complete the import of keys later, and a more powerful procedure for decryption via the Internet is under development, mid-2022.

The imported key guardians should appear in the list. Make sure they are checked, so that the system will take them into account for future registrations.


Configuration of the options of the box

For the second step, you have to go to the "Settings" (gear icon on the main page), in order to:

  • Enter the url of the RTSP stream of your camera (the same URL as the one tested with VLC)
  • Choose the minimum number of key guardians that will be needed to decrypt a video. It is recommended to set a threshold of at least 3 out of at least 4 key guardians to be imported in the previous step. This way, the data is well protected, but still decryptable if one of the guardians is unavailable or has lost his secret phrase.
  • Choose the folder for storing your videos (typically the high capacity USB key dedicated to this)
  • Potentially change the retention period of the videos (legally 30 days maximum in France)
  • Potentially change the maximum duration of a video clip, each encrypted container containing only one


Launch of the recording

Once these configurations have been made, all checks should be marked "OK" on the main page of the software, and the start/stop button should be clickable.

How do I know if the registration is working, once the button is clicked?

  • This button remains activated, instead of going back to "unclicked".
  • Information about the video stream scrolls in the black console.
  • Files appear in the output folder you set up, and their size increases steadily.
  • The video clip start thumbnail at the bottom of the software window updates after a while.
  • After a sufficient time, finalized containers appear in the "Container management" menu item.

You can then close the graphical software, which is only an administration interface. A "service process", in the background, takes care of the real registration operations.

This process is automatically restarted if the Raspberry Pi restarts, and it will then resume the recording if it was running.


The digital paper screen

To have more precise information on the current recording, especially when the box is no longer connected to an HDMI screen, it is at the level of the digital paper that everything happens.

This screen is managed directly by the service process, so it is supposed to be always operational.

If you click on the first button on the screen (top left), it stops or starts the recording.

Clicking the second button (below the first one) will refresh the digital paper screen.

It will then display:

  • A thumbnail of the image captured at the beginning of the last video clip
  • Whether the recording is on or off
  • The status of the network interfaces
  • The time of the box (NOT the camera!)
  • Information about the last recording
  • Statistics on available resources

If the thumbnail is recent and correct, and the last finalized video clip is recent and of good size, this is a strong indicator that everything is working properly.

Note: the green LED on the Ethernet connector of the Raspberry Pi should also blink continuously, indicating the correct transfer of data from the camera.

But it will be useful to check punctually that the camera is on time and delivers a good quality image (e.g. by connecting to it directly with VLC), and that there are no interruptions in the recordings (by reviewing the list of stored container files).


The other buttons on the screen are not used at the moment.


Publications of this series

Witness Angel Motif