Valiceemo
(Richard)
September 29, 2017, 2:25pm
1
Ive recently bought a camera module for my Pi3.
Got it working to take stills and videos etc, but wondering if anyone has integrated one into their HAS setup?
Im actually struggling to find a definitive means of using a Pi camera to live stream, so I can add it to my HAS instance
cxlwill
(Cxlwill)
September 29, 2017, 2:42pm
2
I’m using pi camera module v2. What I did is that building up a http live stream by vlc:
sudo raspivid -o - -t 0 -w 640 -h 360 -n -fps 25|cvlc -vvv stream:///dev/stdin --sout '#standard{access=http,mux=ts,dst=:8090}' :demux=h264
then use ffmpeg
component to add it into HA. I think you cannot get smooth stream at the frontend, but after click the component and enter into detailed card, you can get that. Or you can choose to use HADashboard for smooth stream. Also you can get the live stream in another devices inside your network by safari the ip: Your_PI_IP:8090
Since Debian or Raspbian Stretch officially add ffmpeg
into apt-get source, I personally think it is better than Generic Approach.
The PI-camera component in HA use raspistill
to fetch still picture every second, but we all know that natural video is definitely more smooth than combination of pictures. So I don’t recommend you use this component.
Valiceemo
(Richard)
September 29, 2017, 5:32pm
3
Thanks for this.
I’d been trying to get a stream with VLC to no avail, and this seems to partially work.
I say partially because, I can get the stream in a media player such as VLC or Mx player on android.
But.
If I try to open in chrome it just seems to endlessly download.
And I can’t get our to load in has fronted.
The ffmpeg component loads but gives me an error with loading the steam.
My configuration.yaml
has the following within it
camera:
- platform: ffmpeg
input: http://192.168.0.50:8090
cxlwill
(Cxlwill)
September 29, 2017, 5:36pm
4
I assume you have installed ffmpeg in Pi by apt-get install ffmpeg. Then you need to add ffmpeg component (different from camera platform) first to indicate where the ffmpeg is. After these two steps, I think the component would work well.
Valiceemo
(Richard)
September 29, 2017, 5:48pm
5
Hmmmm
When I try to install ffmpeg I get the following…
pi@media-pi:~ $ sudo apt-get install ffmpeg
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package ffmpeg is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'ffmpeg' has no installation candidate
Valiceemo
(Richard)
September 29, 2017, 6:13pm
6
I can’t even get the rpi camera component to work
cxlwill
(Cxlwill)
September 29, 2017, 11:56pm
7
That’s strange. Could you attach the error log? As for ffmpeg
, only Stretch has it in source. If you are using Debian Jessie(Raspbian Jessie or Hassbian 1.23), then you need to add the source first. You can find the solution at ffmpeg
component page.
Valiceemo
(Richard)
September 30, 2017, 2:31pm
8
cxlwill:
That’s strange. Could you attach the error log? As for ffmpeg
, only Stretch has it in source. If you are using Debian Jessie(Raspbian Jessie or Hassbian 1.23), then you need to add the source first. You can find the solution at ffmpeg
component page.
Here is the output when I run the command you provided.
pi@media-pi:~ $ sudo raspivid -o - -t 0 -w 640 -h 360 -n -fps 25|cvlc -vvv stream:///dev/stdin --sout '#standard{access=http,mux=ts,dst=:8090}' :demux=h264
VLC media player 2.2.6 Umbrella (revision 2.2.6-0-g1aae78981c)
[00ea58f8] core libvlc debug: VLC media player - 2.2.6 Umbrella
[00ea58f8] core libvlc debug: Copyright © 1996-2017 the VideoLAN team
[00ea58f8] core libvlc debug: revision 2.2.6-0-g1aae78981c
[00ea58f8] core libvlc debug: configured with ./configure '--includedir=${prefix}/include' '--mandir=${prefix}/share/man' '--infodir=${prefix}/share/info' '--localstatedir=/var' '--libdir=${prefix}/lib/arm-linux-gnueabihf' '--libexecdir=${prefix}/lib/arm-linux-gnueabihf' '--disable-dependency-tracking' '--build=arm-linux-gnueabihf' 'CPPFLAGS=-D_FORTIFY_SOURCE=2' 'LDFLAGS=-Wl,-z,relro' '--config-cache' '--disable-maintainer-mode' '--disable-silent-rules' '--disable-update-check' '--enable-fast-install' '--prefix=/usr' '--docdir=/usr/share/doc/vlc-nox' '--libdir=/usr/lib' '--sysconfdir=/etc' '--with-binary-version=1~deb8u1' '--enable-a52' '--enable-aa' '--enable-bluray' '--enable-bonjour' '--enable-caca' '--enable-chromaprint' '--enable-dbus' '--enable-dca' '--enable-directfb' '--enable-dvbpsi' '--enable-dvdnav' '--enable-faad' '--enable-flac' '--enable-fluidsynth' '--enable-freerdp' '--enable-freetype' '--enable-fribidi' '--enable-gles1' '--enable-gles2' '--enable-gnutls' '--enable-jack' '--enable-kate' '--enable-libass' '--enable-libmpeg2' '--enable-libxml2' '--enable-lirc' '--enable-live555' '--enable-mad' '--enable-mkv' '--enable-mod' '--enable-mpc' '--enable-mtp' '--enable-mux_ogg' '--enable-ncurses' '--enable-notify' '--enable-ogg' '--enable-opus' '--enable-pulse' '--enable-qt' '--enable-realrtsp' '--enable-samplerate' '--enable-schroedinger' '--enable-sdl' '--enable-sftp' '--enable-shine' '--enable-shout' '--enable-skins2' '--enable-smbclient' '--enable-speex' '--enable-svg' '--enable-taglib' '--enable-theora' '--enable-twolame' '--enable-upnp' '--enable-vcdx' '--enable-vdpau' '--enable-vnc' '--enable-vorbis' '--enable-x264' '--enable-zvbi' '--with-kde-solid=/usr/share/kde4/apps/solid/actions/' '--disable-decklink' '--disable-dxva2' '--disable-fdkaac' '--disable-gnomevfs' '--disable-goom' '--disable-libtar' '--disable-mfx' '--disable-opencv' '--disable-projectm' '--disable-sndio' '--disable-svgdec' '--disable-telx' '--disable-vpx' '--disable-vsxu' '--disable-wasapi' '--enable-alsa' '--enable-atmo' '--enable-dc1394' '--enable-dv1394' '--enable-linsys' '--enable-omxil' '--enable-udev' '--enable-v4l2' '--enable-libva' '--enable-vcd' '--disable-oss' '--disable-crystalhd' '--disable-mmx' '--disable-sse' '--disable-neon' '--disable-altivec' 'CFLAGS=-g -O2 -fstack-protector-strong -Wformat -Werror=format-security' 'CXXFLAGS=-g -O2 -fstack-protector-strong -Wformat -Werror=format-security' 'build_alias=arm-linux-gnueabihf' 'OBJCFLAGS=-g -O2 -fstack-protector-strong -Wformat -Werror=format-security'
[00ea58f8] core libvlc debug: searching plug-in modules
[00ea58f8] core libvlc debug: loading plugins cache file /usr/lib/vlc/plugins/plugins.dat
[00ea58f8] core libvlc debug: recursively browsing `/usr/lib/vlc/plugins'
[00ea58f8] core libvlc debug: saving plugins cache /usr/lib/vlc/plugins/plugins.dat
[00ea58f8] core libvlc debug: plug-ins loaded: 450 modules
[00ea58f8] core libvlc debug: opening config file (/home/pi/.config/vlc/vlcrc)
[00ea58f8] core libvlc debug: translation test: code is "en_GB"
[00ea58f8] core libvlc debug: CPU has capabilities ARM_NEON FPU
[00f3dc78] core input debug: Creating an input for 'Media Library'
[00f3dc78] core input debug: Input is a meta file: disabling unneeded options
[00f3dc78] core input debug: using timeshift granularity of 50 MiB, in path '/tmp'
[00f3dc78] core input debug: `file/xspf-open:///home/pi/.local/share/vlc/ml.xspf' gives access `file' demux `xspf-open' path `/home/pi/.local/share/vlc/ml.xspf'
[00f3dc78] core input debug: creating demux: access='file' demux='xspf-open' location='/home/pi/.local/share/vlc/ml.xspf' file='/home/pi/.local/share/vlc/ml.xspf'
[00eb8948] core demux debug: looking for access_demux module matching "file": 20 candidates
[00eb8948] core demux debug: no access_demux modules matched
[00f3dc78] core input debug: creating access 'file' location='/home/pi/.local/share/vlc/ml.xspf', path='/home/pi/.local/share/vlc/ml.xspf'
[00eba338] core access debug: looking for access module matching "file": 25 candidates
[00eba338] filesystem access debug: opening file `/home/pi/.local/share/vlc/ml.xspf'
[00eba338] core access debug: using access module "filesystem"
[00ebaed0] core stream debug: Using stream method for AStream*
[00ebaed0] core stream debug: starting pre-buffering
[00ebaed0] core stream debug: received first data after 0 ms
[00ebaed0] core stream debug: pre-buffering done 296 bytes in 0s - 7050 KiB/s
[00ebaf90] core stream debug: looking for stream_filter module matching "any": 9 candidates
[00ebaf90] core stream debug: no stream_filter modules matched
[00ebaf90] core stream debug: looking for stream_filter module matching "record": 9 candidates
[00ebaf90] core stream debug: using stream_filter module "record"
[00f3dc78] core input debug: creating demux: access='file' demux='xspf-open' location='/home/pi/.local/share/vlc/ml.xspf' file='/home/pi/.local/share/vlc/ml.xspf'
[01013f98] core demux debug: looking for demux module matching "xspf-open": 65 candidates
[01013f98] xspf demux debug: using XSPF playlist reader
[01013f98] core demux debug: using demux module "playlist"
[01014508] core demux meta debug: looking for meta reader module matching "any": 2 candidates
[01014508] lua demux meta debug: Trying Lua scripts in /home/pi/.local/share/vlc/lua/meta/reader
[01014508] lua demux meta debug: Trying Lua scripts in /usr/lib/vlc/lua/meta/reader
[01014508] lua demux meta debug: Trying Lua playlist script /usr/lib/vlc/lua/meta/reader/filename.luac
[01014508] lua demux meta debug: Trying Lua scripts in /usr/share/vlc/lua/meta/reader
[01014508] core demux meta debug: no meta reader modules matched
[00f3dc78] core input debug: `file/xspf-open:///home/pi/.local/share/vlc/ml.xspf' successfully opened
[00f32638] core xml reader debug: looking for xml reader module matching "any": 1 candidates
[00f32638] core xml reader debug: using xml reader module "xml"
[01013f98] xspf demux debug: parsed 0 tracks successfully
[00f3dc78] core input debug: EOF reached
[01013f98] core demux debug: removing module "playlist"
[00ebaf90] core stream debug: removing module "record"
[00eba338] core access debug: removing module "filesystem"
[00f30118] core playlist debug: creating audio output
[00f321b0] core audio output debug: looking for audio output module matching "any": 5 candidates
[00f321b0] pulse audio output debug: using library version 5.0.0
[00f321b0] pulse audio output debug: (compiled with version 5.0.0, protocol 29)
[00f321b0] pulse audio output error: PulseAudio server connection failure: Connection refused
[00f321b0] alsa audio output debug: Available ALSA PCM devices:
[00f321b0] alsa audio output debug: Discard all samples (playback) or generate zero samples (capture) (null)
[00f321b0] alsa audio output debug: bcm2835 ALSA, bcm2835 ALSA Default Audio Device (default:CARD=ALSA)
[00f321b0] alsa audio output debug: bcm2835 ALSA, bcm2835 ALSA Default Audio Device (sysdefault:CARD=ALSA)
[00f321b0] alsa audio output debug: bcm2835 ALSA, bcm2835 ALSA Direct sample mixing device (dmix:CARD=ALSA,DEV=0)
[00f321b0] alsa audio output debug: bcm2835 ALSA, bcm2835 IEC958/HDMI Direct sample mixing device (dmix:CARD=ALSA,DEV=1)
[00f321b0] alsa audio output debug: bcm2835 ALSA, bcm2835 ALSA Direct sample snooping device (dsnoop:CARD=ALSA,DEV=0)
[00f321b0] alsa audio output debug: bcm2835 ALSA, bcm2835 IEC958/HDMI Direct sample snooping device (dsnoop:CARD=ALSA,DEV=1)
[00f321b0] alsa audio output debug: bcm2835 ALSA, bcm2835 ALSA Direct hardware device without any conversions (hw:CARD=ALSA,DEV=0)
[00f321b0] alsa audio output debug: bcm2835 ALSA, bcm2835 IEC958/HDMI Direct hardware device without any conversions (hw:CARD=ALSA,DEV=1)
[00f321b0] alsa audio output debug: bcm2835 ALSA, bcm2835 ALSA Hardware device with all software conversions (plughw:CARD=ALSA,DEV=0)
[00f321b0] alsa audio output debug: bcm2835 ALSA, bcm2835 IEC958/HDMI Hardware device with all software conversions (plughw:CARD=ALSA,DEV=1)
[00f321b0] core audio output debug: using audio output module "alsa"
[00f30118] core playlist debug: keeping audio output
[00f30118] core playlist debug: adding item `stdin' ( stream:///dev/stdin )
[74000520] core input debug: Creating an input for 'stdin'
[00eb8178] core interface debug: looking for interface module matching "hotkeys,none": 19 candidates
[00f30118] core playlist debug: meta ok for (null), need to fetch art
[74002be0] core art finder debug: looking for meta fetcher module matching "any": 1 candidates
[00eb8178] core interface debug: using interface module "hotkeys"
[00ece8f0] core interface debug: looking for interface module matching "globalhotkeys,none": 19 candidates
[00ece8f0] core interface debug: no interface modules matched
[00ece8f0] core interface error: no suitable interface module
[00ea58f8] core libvlc error: interface "globalhotkeys,none" initialization failed
[00ece8f0] core interface debug: looking for interface module matching "dbus,none": 19 candidates
[00ece8f0] dbus interface error: Failed to connect to the D-Bus session daemon: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11
[00ece8f0] core interface debug: no interface modules matched
[00ece8f0] core interface error: no suitable interface module
[00ea58f8] core libvlc error: interface "dbus,none" initialization failed
[00ece8f0] core interface debug: looking for interface module matching "dummy": 19 candidates
[00ece8f0] dummy interface: using the dummy interface module...
[00ece8f0] core interface debug: using interface module "dummy"
[00f30118] core playlist debug: processing request item: null, node: Playlist, skip: 0
[00f30118] core playlist debug: rebuilding array of current - root Playlist
[00f30118] core playlist debug: rebuild done - 1 items, index -1
[00f30118] core playlist debug: starting playback of the new playlist item
[00f30118] core playlist debug: resyncing on stdin
[00f30118] core playlist debug: stdin is at 0
[00f30118] core playlist debug: creating new input thread
[73d00508] core input debug: Creating an input for 'stdin'
[00f30118] core playlist debug: requesting art for stdin
[73c006f8] core stream output debug: using sout chain=`standard{access=http,mux=ts,dst=:8090}'
[73c006f8] core stream output debug: stream=`standard'
[73c00960] core stream out debug: looking for sout stream module matching "standard": 22 candidates
[73c00960] core stream out debug: set config option: sout-standard-access to http
[73c00960] core stream out debug: set config option: sout-standard-mux to ts
[73c00960] core stream out debug: set config option: sout-standard-dst to :8090
[73c015f0] core access out debug: looking for sout access module matching "http": 8 candidates
[74002be0] lua art finder debug: Trying Lua scripts in /home/pi/.local/share/vlc/lua/meta/fetcher
[74002be0] lua art finder debug: Trying Lua scripts in /usr/lib/vlc/lua/meta/fetcher
[74002be0] lua art finder debug: Trying Lua playlist script /usr/lib/vlc/lua/meta/fetcher/tvrage.luac
[73c015f0] core access out debug: net: listening to * port 8090
[73b004d8] core art finder debug: looking for meta fetcher module matching "any": 1 candidates
[73c015f0] core access out debug: using sout access module "access_output_http"
[73c02668] core mux debug: looking for sout mux module matching "ts": 10 candidates
[74002be0] lua art finder debug: skipping script (unmatched scope) /usr/lib/vlc/lua/meta/fetcher/tvrage.luac
[74002be0] lua art finder debug: Trying Lua scripts in /usr/share/vlc/lua/meta/fetcher
[74002be0] core art finder debug: no meta fetcher modules matched
[00f30118] core playlist debug: searching art for stdin
[74002be0] core art finder debug: looking for art finder module matching "any": 2 candidates
[73c02668] mux_ts mux debug: shaping=200000 pcr=70000 dts_delay=400000
[73c02668] core mux debug: using sout mux module "mux_ts"
[73c006f8] core stream output debug: muxer support adding stream at any time
[73c006f8] core stream output debug: muxer prefers to wait for all ES before starting to mux
[73c00960] stream_out_standard stream out debug: using `http/ts://:8090'
[73c00960] core stream out debug: using sout stream module "stream_out_standard"
[73d00508] core input debug: using timeshift granularity of 50 MiB, in path '/tmp'
[73d00508] core input debug: `stream:///dev/stdin' gives access `stream' demux `' path `/dev/stdin'
[73d00508] core input debug: specified demux `h264'
[73d00508] core input debug: creating demux: access='stream' demux='h264' location='/dev/stdin' file='/dev/stdin'
[73c06198] core demux debug: looking for access_demux module matching "stream": 20 candidates
[73c06198] core demux debug: no access_demux modules matched
[73d00508] core input debug: creating access 'stream' location='/dev/stdin', path='/dev/stdin'
[73b004d8] lua art finder debug: Trying Lua scripts in /home/pi/.local/share/vlc/lua/meta/fetcher
[73c06198] core access debug: looking for access module matching "stream": 25 candidates
[73c06198] filesystem access debug: opening file `/dev/stdin'
[73b004d8] lua art finder debug: Trying Lua scripts in /usr/lib/vlc/lua/meta/fetcher
[73c06198] core access debug: using access module "filesystem"
[73b004d8] lua art finder debug: Trying Lua playlist script /usr/lib/vlc/lua/meta/fetcher/tvrage.luac
[73c06268] core stream debug: Using stream method for AStream*
[73c06268] core stream debug: starting pre-buffering
[73c06268] core stream debug: received first data after 0 ms
[73c06268] core stream debug: pre-buffering done 1024 bytes in 0s - 10416 KiB/s
[73c06428] core stream debug: looking for stream_filter module matching "any": 9 candidates
[73c06428] core stream debug: no stream_filter modules matched
[73c06428] core stream debug: looking for stream_filter module matching "record": 9 candidates
[73c06428] core stream debug: using stream_filter module "record"
[73d00508] core input debug: creating demux: access='stream' demux='h264' location='/dev/stdin' file='/dev/stdin'
[73c064e8] core demux debug: looking for demux module matching "h264": 65 candidates
[73c064e8] h264 demux debug: using 25.00 fps
[73c069c0] core demux packetizer debug: looking for packetizer module matching "any": 23 candidates
[74002be0] lua art finder debug: Trying Lua scripts in /home/pi/.local/share/vlc/lua/meta/art
[74002be0] lua art finder debug: Trying Lua scripts in /usr/lib/vlc/lua/meta/art
[74002be0] lua art finder debug: Trying Lua playlist script /usr/lib/vlc/lua/meta/art/00_musicbrainz.luac
[73c069c0] core demux packetizer debug: using packetizer module "packetizer_h264"
[73c064e8] core demux debug: using demux module "h264"
[73d00508] core input debug: starting in async mode
[73c0bbc8] core demux meta debug: looking for meta reader module matching "any": 2 candidates
[73b004d8] lua art finder debug: skipping script (unmatched scope) /usr/lib/vlc/lua/meta/fetcher/tvrage.luac
[73b004d8] lua art finder debug: Trying Lua scripts in /usr/share/vlc/lua/meta/fetcher
[73b004d8] core art finder debug: no meta fetcher modules matched
[00ea58f8] core libvlc debug: searching art for stdin
[73b004d8] core art finder debug: looking for art finder module matching "any": 2 candidates
[74002be0] lua art finder debug: skipping script (unmatched scope) /usr/lib/vlc/lua/meta/art/00_musicbrainz.luac
[74002be0] lua art finder debug: Trying Lua playlist script /usr/lib/vlc/lua/meta/art/01_googleimage.luac
[73c0bbc8] lua demux meta debug: Trying Lua scripts in /home/pi/.local/share/vlc/lua/meta/reader
[73c0bbc8] lua demux meta debug: Trying Lua scripts in /usr/lib/vlc/lua/meta/reader
[73c0bbc8] lua demux meta debug: Trying Lua playlist script /usr/lib/vlc/lua/meta/reader/filename.luac
[73b004d8] lua art finder debug: Trying Lua scripts in /home/pi/.local/share/vlc/lua/meta/art
[73b004d8] lua art finder debug: Trying Lua scripts in /usr/lib/vlc/lua/meta/art
[73b004d8] lua art finder debug: Trying Lua playlist script /usr/lib/vlc/lua/meta/art/00_musicbrainz.luac
[74002be0] lua art finder debug: skipping script (unmatched scope) /usr/lib/vlc/lua/meta/art/01_googleimage.luac
[73c0bbc8] lua demux meta debug: Trying Lua scripts in /usr/share/vlc/lua/meta/reader
[74002be0] lua art finder debug: Trying Lua playlist script /usr/lib/vlc/lua/meta/art/02_frenchtv.luac
[73c0bbc8] core demux meta debug: no meta reader modules matched
[73d00508] core input debug: `stream:///dev/stdin' successfully opened
[73c069c0] packetizer_h264 demux packetizer debug: found NAL_SPS (sps_id=0)
[73c069c0] packetizer_h264 demux packetizer debug: found NAL_PPS (pps_id=0 sps_id=0)
[73d00508] core input debug: selecting program id=0
[73c0be50] core decoder debug: looking for packetizer module matching "any": 23 candidates
[73c0be50] core decoder debug: using packetizer module "packetizer_h264"
[73d00508] core input error: Invalid PCR value in ES_OUT_SET_(GROUP_)PCR !
[73d00508] core input debug: switching to sync mode
[73c0be50] packetizer_h264 decoder debug: found NAL_SPS (sps_id=0)
[73c0be50] packetizer_h264 decoder debug: found NAL_PPS (pps_id=0 sps_id=0)
[73d00508] core input debug: Buffering 0%
[73d00508] core input debug: Buffering 13%
[73c006f8] core stream output debug: adding a new sout input (sout_input:0x72700520)
[73c02668] core mux debug: adding a new input
[73c02668] mux_ts mux debug: adding input codec=h264 pid=68
[73c02668] mux_ts mux debug: new PCR PID is 68
[73d00508] core input debug: Buffering 26%
[73d00508] core input debug: Buffering 40%
[73d00508] core input debug: Buffering 53%
[73b004d8] lua art finder debug: skipping script (unmatched scope) /usr/lib/vlc/lua/meta/art/00_musicbrainz.luac
[73b004d8] lua art finder debug: Trying Lua playlist script /usr/lib/vlc/lua/meta/art/01_googleimage.luac
[74002be0] lua art finder debug: skipping script (unmatched scope) /usr/lib/vlc/lua/meta/art/02_frenchtv.luac
[74002be0] lua art finder debug: Trying Lua playlist script /usr/lib/vlc/lua/meta/art/03_lastfm.luac
[74002be0] lua art finder debug: skipping script (unmatched scope) /usr/lib/vlc/lua/meta/art/03_lastfm.luac
[74002be0] lua art finder debug: Trying Lua scripts in /usr/share/vlc/lua/meta/art
[74002be0] core art finder debug: no art finder modules matched
[00f30118] core playlist debug: art not found for stdin
[73b004d8] lua art finder debug: skipping script (unmatched scope) /usr/lib/vlc/lua/meta/art/01_googleimage.luac
[73b004d8] lua art finder debug: Trying Lua playlist script /usr/lib/vlc/lua/meta/art/02_frenchtv.luac
[73d00508] core input debug: Buffering 66%
[73b004d8] lua art finder debug: skipping script (unmatched scope) /usr/lib/vlc/lua/meta/art/02_frenchtv.luac
[73b004d8] lua art finder debug: Trying Lua playlist script /usr/lib/vlc/lua/meta/art/03_lastfm.luac
[73b004d8] lua art finder debug: skipping script (unmatched scope) /usr/lib/vlc/lua/meta/art/03_lastfm.luac
[73b004d8] lua art finder debug: Trying Lua scripts in /usr/share/vlc/lua/meta/art
[73b004d8] core art finder debug: no art finder modules matched
[00ea58f8] core libvlc debug: art not found for stdin
[73d00508] core input debug: Buffering 80%
[73d00508] core input debug: Buffering 93%
[73d00508] core input debug: Stream buffering done (320 ms in 138 ms)
[73d00508] core input debug: Decoder wait done in 0 ms
[73c02668] core mux warning: late buffer for mux input (30032)
cxlwill
(Cxlwill)
October 1, 2017, 1:59am
9
The log seems OK to me. When you launch this http
stream, can you watch it by using VLC at other devices in local network? Again if you can use raspistill
at the terminal and catch images, then there is low possibility that you cannot use pi-camera component .
I’m using Rpi Cam Control from here and then have this in my camera.yaml file. Works very well without issues if you are happy to just view it through HA.
- platform: generic
still_image_url: http://192.168.1.111:5004/cam.jpg
username: redacted
password: redacted
Valiceemo
(Richard)
October 2, 2017, 10:08am
11
cxlwill:
The log seems OK to me. When you launch this http
stream, can you watch it by using VLC at other devices in local network? Again if you can use raspistill
at the terminal and catch images, then there is low possibility that you cannot use pi-camera component .
Yeah, I can watch the stream from inside VLC or MX Player, but not on chrome.
I can also use raspistill
to capture images from CL
Any way, I installed ffmpeg as per the guidelines on the ffmpeg component page. Some of the steps did not work, but I managed to get it installed. (It installed a lot of other libraries, is it normal?)
Now I can see the stream in HAS front end.
I added 2 components to my configuration.yaml
…
ffmpeg camera and ffmpeg
But only one element is added to frontend?
config looks as follows
camera:
- platform: ffmpeg
input: http://192.168.0.50:8090
ffmpeg:
ffmpeg_bin: /usr/bin/ffmpeg
Is it necessary to have both?
I think I may be a bit confused!?
cxlwill
(Cxlwill)
October 2, 2017, 10:30am
12
Well, first congratulations on successful stream~ Then yes, it is necessary to have two components. Actually ffmpeg
is a transcode tool and that is why it installed so many libraries, they are code-basic and trans rule. HA could not recognize rtsp
or http
stream itself. So we need to indicate ffmpeg
location first to transcode your stream, then introduce it in HA as a camera. That’s whyffmpeg
does not show at the frontend. It is just a background working tool.
Valiceemo
(Richard)
October 2, 2017, 10:46am
13
cxlwill:
Well, first congratulations on successful stream~ Then yes, it is necessary to have two components. Actually ffmpeg
is a transcode tool and that is why it installed so many libraries, they are code-basic and trans rule. HA could not recognize rtsp
or http
stream itself. So we need to indicate ffmpeg
location first to transcode your stream, then introduce it in HA as a camera. That’s whyffmpeg
does not show at the frontend. It is just a background working tool.
ahh ok, makes sense.
Thanks a lot for your help
One more question concern…
Is running the VLC stream from my Pi3 going to cause any extra load, work on the Pi?
So far I have not noticed an increase in temp or cpu load.
But I am concerned about the SD card, does it continuously write to the card in any form (buffer / cache)?
Valiceemo
(Richard)
October 3, 2017, 7:49pm
14
any tips on how to have this auto run at boot for example?