Utilisation d'omxplayer sur raspberry pi3 pour divers diffusions audio et/ou vidéo
https://www.macplanete.com/tutoriels/22225/monter-une-partition-linux-sur-mac
https://github.com/osxfuse/osxfuse/releases
https://doc.ubuntu-fr.org/tutoriel/comment_acceder_a_ses_partitions_d_ubuntu_sous_windows
http://www.eassos.com/blog/how-to-read-write-linux-ext4-ext3-ext2-partition-on-windows/
https://www.howtogeek.com/112888/3-ways-to-access-your-linux-partitions-from-windows/
dans un terminal
sudo nautilus
dant la fenêtre de nautilus, aller sur la partition boot de la carte sd > lancer > dossier parents > numéro-de-partition
Synchronise 2 dossiers de local vers distant en virant du distant tout ce qui n'est pas dans local : synchronisation stricte
rsync -uav --delete -e 'ssh -p 22' /home/contenu_de_ce_dossier/ user@XXX.XXX.XXX.XXX:/home/dans_ce_dossier
Le plus simple est d'utiliser Audacity https://www.audacityteam.org/download/
Une fois installer et lancer aller dans les préférences (pomme+,) > import/export puis cliquer sur Utiliser un mix personnaliser
Créer ces pistes et aller dans Fichier > Export > Wav > Enregistrer
Il est alors possible de créer un fichier audio avec le nombre de pistes nécessaires
Voilà un extrait créer avec Audacity
sudo apt install dcfldd
df -l
sudo dcfldd if=/dev/mmcblk0 of=raspi-video-sync.img
Aller dans le dossier ou se trouve l'image
cd /là-où-est-l'image\\ sudo dcfldd if=omxplayer-sync-02.img of=/dev/mmcblk0
hdmi_force_edid_audio=1\\ config_hdmi_boost=7
tvservice -a
PCM supported: Max channels: 8, Max samplerate: 192kHz, Max samplesize 24 bits.\\ AC3 supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ MPEG1 supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ MP3 supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ MPEG2 supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ AAC supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ DTS supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ ATRAC supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ DSD supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ EAC3 supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ DTS_HD supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ MLP supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ DST supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ WMAPRO supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.\\ Extended supported: Max channels: 8, Max samplerate: 192kHz, Max rate 2040 kb/s.
omxplayer --layout 5.1 -o hdmi surroundTestDTS.dts.wav
marche aussi avec ACC en aiff
nano /home/pi/player5-1.sh
#!/bin/sh \\
# pour ne pas faire apparaitre la souris\\ setterm -cursor off \\
# dossier contenant les fichiers videos/audios\\ MEDIAPATH="/home/pi/Media"\\
# you can normally leave this alone\\ SERVICE="omxplayer"\\
# la boucle qui utilise omxplayer et hifiberry via alsa\\ while true; do\\ if ps ax | grep -v grep | grep $SERVICE > /dev/null\\ then\\ sleep 1;\\ else\\ for entry in $MEDIAPATH/*\\ do\\ clear\\ omxplayer --layout 5.1 -o hdmi $entry > /dev/null\\ done\\ fi\\ done
chmod +rx player5-1.sh
https://hydrogenaud.io/index.php/topic,110364.0.html
https://gathering.tweakers.net/forum/list_messages/1661925
https://www.raspberrypi.org/forums/viewtopic.php?f=63&t=147115
https://parumi.wordpress.com/2007/12/12/how-to-create-multichannel-51-ac3-audio-and-video-in-linux/
sudo dcfldd if=raspbian-lite-hifiberry.img of=/dev/mmcblk0
sudo raspi-config
cat /sys/module/kernel/parameters/consoleblank
sudo nano /boot/cmdline.txt
et ajouter
consoleblank=20
https://www.raspberrypi.org/documentation/configuration/screensaver.md
aplay -l
ou F6 dans
alsamixer
nano /home/pi/mediaplayer.sh
y copier le texte suivant
#!/bin/sh \\
# pour ne pas faire apparaitre la souris\\ setterm -cursor off\\
# dossier contenant les fichiers videos/audios\\ MEDIAPATH="/home/pi/Media"\\
# you can normally leave this alone\\ SERVICE="omxplayer"\\
# la boucle qui utilise omxplayer et hifiberry via alsa\\ while true; do\\ if ps ax | grep -v grep | grep $SERVICE > /dev/null\\ then\\ sleep 1;\\ else\\ for entry in $MEDIAPATH/*\\ do\\ clear\\ omxplayer -o alsa $entry > /dev/null\\ done\\ fi\\ done
le rendre éxecutable
chmod +rx mediaplayer.sh
sudo nano /etc.rc.local
et placer le texte ci-dessous avant exit0
/home/pi/mediaplayer.sh
Il suffit maintenant de mettre un ou plusieurs fichiers dans le dossier Media (en montant la carte SD sur son ordinateur) pour qu'ils se lisent!
http://www.cenolan.com/2013/03/looping-video-playlist-omxplayer-raspberry-pi/
https://www.hifiberry.com/build/documentation/configuring-linux-3-18-x/
Après quelques tentatives d'installation depuis une image raspbian stretch lite et des galères de dépendances il est plus simple de partir depuis une image pré-configurée avec les versions compilées d'omxplayer/ffmpeg/omxplayer-sync.
Modifier le fichier /etc/network/interfaces en donnant à chaques pi une adresse différentes 192.168.2.10X
# interfaces(5) file used by ifup(8) and ifdown(8)\\
# Please note that this file is written to be used with dhcpcd\\ # For static IP, consult /etc/dhcpcd.conf and 'man dhcpcd.conf'\\
# Include files from /etc/network/interfaces.d:\\ source-directory /etc/network/interfaces.d\\
auto lo\\ iface lo inet loopback\\
auto lo eth0\\ iface eth0 inet static\\ address 192.168.2.102\\ netmask 255.255.255.0\\ gateway 192.168.2.1\\ broadcast 192.168.2.255\\ #dns-nameservers 192.168.2.1\\
allow-hotplug wlan0\\ iface wlan0 inet manual\\ wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf\\
allow-hotplug wlan1\\ iface wlan1 inet manual\\ wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
Dans /boot/config.txt ajouter
dtoverlay=pi3-disable-wifi
/usr/bin/omxplayer-sync -muvb /home/pi/video.mp4
/usr/bin/omxplayer-sync -luvb /home/pi/video.mp4
Si il a de la latence, il faut modifier le fichier /usr/bin/omxplayer-sync à la ligne 33
SYNC_TOLERANCE = .25\\ SYNC_GRACE_TIME = 5\\ SYNC_JUMP_AHEAD = 3
https://www.raspberrypi.org/documentation/raspbian/applications/omxplayer.md