User Tools

Site Tools


informatica:linux:radio

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
informatica:linux:radio [2014/12/06 12:21] – [Varios] javiinformatica:linux:radio [2018/05/12 15:43] (current) – [Darkice] javi
Line 1: Line 1:
 ====== Airtime ====== ====== Airtime ======
 +
 +http://sourcefabric.booktype.pro/airtime-25-for-broadcasters/
  
 ===== Instalación ===== ===== Instalación =====
 +
 +==== Debian ? - Airtime 2.? ====
  
 1. Descargar easy install e intentar 1. Descargar easy install e intentar
Line 7: Line 11:
 <code> <code>
 wget http://apt.sourcefabric.org/misc/airtime-easy-setup.deb wget http://apt.sourcefabric.org/misc/airtime-easy-setup.deb
-sudo dpkg -i airtime-easy-setup.deb 
 </code> </code>
  
-2. Instalar paquete de wheezy:+2. Instalar paquetes necesarios: 
 + 
 +<code> 
 +sudo aptitude install debconf-utils icecast2 postgresql python-virtualenv ecasound flac libcamomile-ocaml-data monit multitail odbc-postgresql php5-curl php5-pgsql pwgen rabbitmq-server zendframework 
 +</code> 
 + 
 +Descargar mp3gain:
  
 https://packages.debian.org/wheezy/amd64/mp3gain/download https://packages.debian.org/wheezy/amd64/mp3gain/download
  
-3. Configurar+Instalarlo: 
 + 
 +  sudo dpkg -i /path/to/mp3gain_1.5.2-r2-2+deb7u1_amd64.deb  
 + 
 +3. Configurar
 + 
 +<code> 
 +sudo dpkg -i airtime-easy-setup.deb 
 +sudo airtime-easy-setup 
 +</code> 
 + 
 +==== Ubuntu 14.04.3 - Airtime 2.5.1-1 ==== 
 + 
 +1. Descargar easy install e intentar 
 + 
 +<code> 
 +wget http://apt.sourcefabric.org/misc/airtime-easy-setup.deb 
 +</code> 
 + 
 +2. Instalar paquetes necesarios: 
 + 
 +<code> 
 +sudo aptitude install debconf-utils icecast2 postgresql python-virtualenv ecasound flac libcamomile-ocaml-data monit multitail odbc-postgresql php5-curl php5-pgsql pwgen rabbitmq-server zend-framework libportaudio2 php5-gd php-pear unzip 
 +</code> 
 + 
 +3. Configurar: 
 + 
 +<code> 
 +sudo dpkg -i airtime-easy-setup.deb 
 +sudo airtime-easy-setup 
 +</code> 
 + 
 +===== Configuración ===== 
 + 
 +Asumo que airtime esta instalado en un servidor. En este ejemplo el servidor esta en la DMZ y tiene como nombre DNS "airtime.example.com" 
 + 
 +1. Editar archivo de config: 
 + 
 +<code> 
 +sudo cp /etc/airtime/airtime.conf /etc/airtime/airtime.conf.old 
 +sudo vim /etc/airtime/airtime.conf 
 +</code> 
 + 
 +Y ajustar la variable: 
 + 
 +  base_url = airtime.example.com 
 +   
 +2. Tras cambiar una configuracion, actualizar base de datos: 
 + 
 +  sudo airtime-update-db-settings 
 + 
 +3. Editar el virtualhost: 
 + 
 +<code> 
 +sudo cp /etc/apache2/sites-available/airtime-vhost.conf /etc/apache2/sites-available/airtime-vhost.conf.old  
 +sudo vim /etc/apache2/sites-available/airtime-vhost.conf  
 +</code> 
 + 
 +Y dejarlo tal que asi: 
 + 
 +<code> 
 +<VirtualHost *:443> 
 +      SSLEngine on 
 +      SSLProtocol all -SSLv2 
 +      SSLCertificateFile /etc/ssl/certs/ssl-cert-snakeoil.pem 
 +      SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key 
 +      Header always set Strict-Transport-Security "max-age=31536000" 
 + 
 +      ServerName airtime.example.com 
 + 
 +      ServerAdmin root@localhost 
 + 
 +      DocumentRoot /usr/share/airtime/public 
 +      DirectoryIndex index.php 
 + 
 +      <Directory /usr/share/airtime/public> 
 +              AllowOverride all 
 +              Require all granted 
 +      </Directory> 
 +</VirtualHost> 
 + 
 +<VirtualHost *:80> 
 +      ServerName airtime.example.com 
 +      ServerAdmin root@localhost 
 + 
 +      DocumentRoot /usr/share/airtime/public 
 +      DirectoryIndex index.php 
 +      Redirect permanent /login https://airtime.example.com/login 
 + 
 +      SetEnv APPLICATION_ENV "production" 
 + 
 +      <Directory /usr/share/airtime/public> 
 +              AllowOverride All 
 +              Require all granted 
 +      </Directory> 
 +</VirtualHost> 
 +</code> 
 + 
 +4. Recargar la config de apache: 
 + 
 +  sudo apachectl -k graceful 
 + 
 +5. Ya se deberia poder entrar en: 
 + 
 +  http://airtime.example.com 
 +===== ID3 ===== 
 + 
 +[[http://en.wikipedia.org/wiki/ID3#ID3v2_frame_specification_.28Version_2.3.29|Listado de etiquetas ID3]] 
 + 
 +Para asignar etiquetas: 
 + 
 +  sudo aptitude install id3v2 
 +   
 +Asignar una etiqueta:
  
-  sudo airtime-easy-setup+  sudo id3v2 --TBPM "128" file.mp3
  
 ===== Varios ===== ===== Varios =====
Line 84: Line 206:
 </code> </code>
  
 +====== Icecast2 ======
 +
 +  sudo aptitude install icecast2
 +  
 +  /etc/icecast2/icecast.xml
 +  
 +Just the mountpoint:
 +
 +<code>
 +        <mount type="normal">
 +            <mount-name>/broadcast01</mount-name>
 +            <password>secret</password>
 +            <max-listeners>10</max-listeners>
 +            <max-listener-duration>3600</max-listener-duration>
 +            <stream-name>Stream name</stream-name>
 +            <stream-description>My audio description</stream-description>
 +            <stream-url>http://some.place.com</stream-url>
 +            <genre>classical</genre>
 +            <bitrate>32</bitrate>
 +            <on-connect>/home/icecast/bin/source-start</on-connect>
 +            <on-disconnect>/home/icecast/bin/source-end</on-disconnect>
 +        </mount>
 +</code>
 +
 +====== Darkice ======
 +
 +  /etc/darkice.cfg
 +  
 +<code>
 +[general]
 +duration = 0 # duration of encoding, in seconds.
 +# 0 means forever
 +bufferSecs = 60 # size of internal slip buffer, in seconds
 +
 +# this section describes the audio input that will be streamed
 +[input]
 +device = default
 +sampleRate = 22050 # sample rate in Hz. try 11025, 22050 or 44100
 +bitsPerSample = 16 # bits per sample. try 16
 +channel = 1 # channels. 1 = mono, 2 = stereo
 +
 +[icecast2-0]
 +bitrateMode = cbr # average bit rate
 +format = mp3 # format of the stream: ogg vorbis
 +quality = 0 # encoding quality
 +bitrate = 32 # bitrate of the stream sent to the server
 +server = icecast.example.com
 +port = 8000
 +mountPoint = broadcast01
 +password = secret
 +localDumpFile = 
 +name = Name
 +description = Description 
 +url = http://example.com
 +genre = music # genre of the stream
 +</code>
 +
 +Arrancar:
 +
 +  sudo darkice -v5 -c /etc/darkice.cfg 
 +
 +===== Errores =====
 +
 +  * DarkIce: AlsaDspSource.cpp:173: can't set channels [2]
 +
 +La causa es que en el archivo de configuración se especifica que el dispositivo puede grabar en stereo:
 +
 +  channel = 2
  
 +Y el dispositivo solo soporta mono. Solución:
  
 +  channel = 1
  
informatica/linux/radio.1417868502.txt.gz · Last modified: 2015/04/13 20:19 (external edit)