Phillipp

Phillipp

Is the Raspberry Pi Zero W powerful enough for Nerves + Membrane + video streaming

Hey,

as the title states, I would like to know if the Raspberry Pi Zero W is powerful enough to run the Membrane framework on Nerves and use it to stream the video (720p, 24fps) from the Raspberry Pi camera module to an online service. I also want to use Phoenix for a web control panel.

The specs of the RPi Zero W are not that great but maybe it is enough.

  • 1GHz, single-core CPU
  • 512MB RAM

My alternative would be the Raspberry Pi 3 Model B. One important factor is energy consumption and the RPi Zero W uses much less power than the RPi 3B.

Most Liked

mspanc

mspanc

Membrane Core Team

According to the camera docs the encoding happens on the Raspberry Pi’s GPU, not on the camera module, so you need to ensure that the GPU is sufficent.

According to the specs published on wikipedia RPi Zero W has built-in 1080p30 or 1080p60 encoder (depending on the SoC).

We as the Membrane Team have never tested the RPi Zero W but it seems that it should work.

mspanc

mspanc

Membrane Core Team

I can’t say for sure when RTMP will be implemented.

Membrane is project-driven to avoid implementing unnecessary or badly designed stuff so we prioritise features required by the projects that we develop as Software Mansion (a company behind Membrane).

We do have a project that requires RTMP in the backlog that is supposed to start very soon, but it is not 100% confirmed yet.

You can rely on ffmpeg for RTMP, and it’s a common practice to fill the gaps in membrane by doing so. Even we do this in some projects :wink: and later we replace ffmpeg parts with Membrane elements once they’re ready.

RPi camera module has quite specific programming interface. In order to call it from Elixir directly we would have needed to port GitHub - waveform80/picamera: A pure Python interface to the Raspberry Pi camera module · GitHub to Elixir.

Unless you strive for 100%-Elixir code or need to process the streams in sophisticated manner it might be easier to just call command-line raspivid that ships with the camera, then pick up the H.264 file that is being recorded and pass it to the ffmpeg.

It is a bit rough approach and won’t allow to do any advanced processing but should do the basic job and be good enough to validate the idea. Hopefully in the meantime we release the missing elements.

lucaong

lucaong

The Rpi Zero W is absolutely powerful enough for Nerves :slight_smile:

As for video streaming, in my experiments I had to limit the size of the video to 640x480 to keep latency low and the video fluid, but I was using WebRTC and running a full (headless) Chromium browser, so not the most efficient option out there…

I suspect that with a more efficient setup you could achieve better results. I never tried Membrane, it sounds great.

Where Next?

Popular in Questions Top

senggen
Erlang/OTP 25 [erts-13.2.2] [source] [64-bit] [smp:8:8] [ds:8:8:10] [async-threads:1] 15:22:35.803 [error] gen_event {lager_file_backend...
New
qwerescape
Is there a way to get the call stack or stack trace at any point in the code? Not from exceptions, but an expression that returns how the...
New
shahryarjb
Hello, I get Persian date from my client and convert it to normal calendar like this: def jalali_string_to_miladi_english_number(persi...
New
ovidiubadita
Hey all, I discovered Elixir and I love it. I always wanted to learn a functional programming and I intended to go for Haskell, but afte...
New
Lily
In templates/appointment/index.html.eex: <%= for appointment <- @appointments do %> <tr> <td><%= appoi...
New
jay1
Why is it that the mnesia database isn’t the most preferred database for use in Elixir/Phoenix?
New
joeerl
Hello again - after a longish gap I’ve decided I really must dig into Elixir and see what’s been happening here - so I have a few questio...
New
SoCreat
i’m a new one to elixir which editor can i use vs code? or atom? Thanks! :smiley:
New
lucidguppy
I have a super simple question about elixir - how would I take a file like this foo bar baz and output a new file that enumerates th...
New
yawaramin
In the Dialyzer docs ( dialyzer — OTP 29.0.2 (dialyzer 6.0.1) ), there is a way to turn off a specific warning for a function: -dialyzer...
New

Other popular topics Top

malloryerik
Hi, this is for people who, like me, have had some friction using .html.heex templates in VSCode. The solution seems to be, in a hyphena...
New
Nvim
Anybody knows a comprehensive comparison of Django and Phoenix, thanks for the help. Where are they similar? Where do they differ the m...
New
ovidiubadita
Hey all, I discovered Elixir and I love it. I always wanted to learn a functional programming and I intended to go for Haskell, but afte...
New
fireproofsocks
Forgive me if this is obvious, but how does one delete a database record WITHOUT selecting it first? Ecto.Repo — Ecto v3.14.0 has exampl...
New
gausby
I asked this very same question on twitter and got some interesting feedback, but I thought it would be a good question to ask here as we...
1207 39467 209
New
grych
Hi folks, Few months ago I have announced the proof-of-concept of the library to manipulate the browsers DOM objects directly from Elixi...
639 52673 488
New
romenigld
I am trying to run a deploy with docker and I successfully runned with this command: docker build -t romenigld/blog-prod . but when I t...
New
shijith.k
I am trying to start a new phoenix project with elixir 1.9, but mix phx.new does not work. It says that ** (Mix) The task "phx.new" could...
New
hariharasudhan94
Lets say I have map like this fetching from my database %{"_id" => #BSON.ObjectId<58eb1a7a9ad169198c3dXXXX>, "email" => ...
New
lanycrost
Hi everyone! I need implement if…else if…else condition from my elixir code, and anymore of this control flow structures not work proper...
New

Latest on Elixir Forum

Elixir Forum

We're in Beta

About us Mission Statement