[pulseaudio] register audio sources in openhab (#12376)
* [pulseaudio] register audio sources in openha * [pulseaudio] fix audio source reconnection * [pulseaudio] audio source check record property and customize SOTimeout * [pulseaudio] use pipe streams * [pulseaudio] synchronize commands and update after module load Signed-off-by: Miguel Álvarez Díez <miguelwork92@gmail.com>
This commit is contained in:
@@ -20,7 +20,7 @@
|
||||
<parameter name="source" type="boolean">
|
||||
<label>Import Sources</label>
|
||||
<description>Activate the import of source elements.</description>
|
||||
<default>false</default>
|
||||
<default>true</default>
|
||||
</parameter>
|
||||
<parameter name="sourceOutput" type="boolean">
|
||||
<label>Import Source Outputs</label>
|
||||
|
||||
@@ -43,14 +43,37 @@ thing-type.config.pulseaudio.sink.activateSimpleProtocolSink.label = Create an A
|
||||
thing-type.config.pulseaudio.sink.activateSimpleProtocolSink.description = Activation of a corresponding sink in OpenHAB (module-simple-protocol-tcp must be available on the pulseaudio server)
|
||||
thing-type.config.pulseaudio.sink.name.label = Name
|
||||
thing-type.config.pulseaudio.sink.name.description = The name of one specific device.
|
||||
thing-type.config.pulseaudio.sink.simpleProtocolSOTimeout.label = Simple Protocol SO Timeout
|
||||
thing-type.config.pulseaudio.sink.simpleProtocolSOTimeout.description = Socket SO timeout when connecting to pulseaudio server though module-simple-protocol-tcp. You can tune this option if the socket disconnect frequently.
|
||||
thing-type.config.pulseaudio.sink.simpleProtocolSinkIdleTimeout.label = Idle Timeout
|
||||
thing-type.config.pulseaudio.sink.simpleProtocolSinkIdleTimeout.description = Timeout in ms after which the connection will be closed when no stream is running. This ensures that your speaker is not on all the time and the pulseaudio sink can go to idle mode. -1 for no disconnection.
|
||||
thing-type.config.pulseaudio.sink.simpleProtocolSinkPort.label = Simple Protocol Port
|
||||
thing-type.config.pulseaudio.sink.simpleProtocolSinkPort.description = Default Port to allocate for use by module-simple-protocol-tcp on the pulseaudio server
|
||||
thing-type.config.pulseaudio.sinkInput.name.label = Name
|
||||
thing-type.config.pulseaudio.sinkInput.name.description = The name of one specific device.
|
||||
thing-type.config.pulseaudio.source.activateSimpleProtocolSource.label = Create an Audio Source with simple-protocol-tcp
|
||||
thing-type.config.pulseaudio.source.activateSimpleProtocolSource.description = Activation of a corresponding source in OpenHAB (module-simple-protocol-tcp must be available on the pulseaudio server)
|
||||
thing-type.config.pulseaudio.source.name.label = Name
|
||||
thing-type.config.pulseaudio.source.name.description = The name of one specific device.
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSOTimeout.label = Simple Protocol SO Timeout
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSOTimeout.description = Socket SO timeout when connecting to pulseaudio server though module-simple-protocol-tcp. You can tune this option if the socket disconnect frequently.
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceChannels.label = Simple Protocol Channels
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceChannels.description = The audio channel number to be used by module-simple-protocol-tcp on the pulseaudio server
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceFormat.label = Simple Protocol Format
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceFormat.description = The audio format to be used by module-simple-protocol-tcp on the pulseaudio server
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceFormat.option.u8 = PCM signed 8-bit
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceFormat.option.s16le = PCM signed 16-bit little-endian
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceFormat.option.s16be = PCM signed 16-bit big-endian
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceFormat.option.s24le = PCM unsigned 24-bit little-endian
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceFormat.option.s24be = PCM unsigned 24-bit big-endian
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceFormat.option.s32le = PCM signed 32-bit little-endian
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceFormat.option.s32be = PCM signed 32-bit big-endian
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceIdleTimeout.label = Idle Timeout
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceIdleTimeout.description = Timeout in ms after which the connection will be closed when no stream is running. This ensures that your speaker is not on all the time and the pulseaudio source can go to idle mode. -1 for no disconnection.
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourcePort.label = Simple Protocol Port
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourcePort.description = Default Port to allocate to be used by module-simple-protocol-tcp on the pulseaudio server
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceRate.label = Simple Protocol Rate
|
||||
thing-type.config.pulseaudio.source.simpleProtocolSourceRate.description = The audio sample rate to be used by module-simple-protocol-tcp on the pulseaudio server
|
||||
thing-type.config.pulseaudio.sourceOutput.name.label = Name
|
||||
thing-type.config.pulseaudio.sourceOutput.name.description = The name of one specific device.
|
||||
|
||||
|
||||
@@ -40,6 +40,13 @@
|
||||
</description>
|
||||
<default>30000</default>
|
||||
</parameter>
|
||||
<parameter name="simpleProtocolSOTimeout" type="integer" min="250" max="2000">
|
||||
<label>Simple Protocol SO Timeout</label>
|
||||
<description>Socket SO timeout when connecting to pulseaudio server though module-simple-protocol-tcp. You can tune
|
||||
this option if the socket disconnect frequently.</description>
|
||||
<default>500</default>
|
||||
<advanced>true</advanced>
|
||||
</parameter>
|
||||
</config-description>
|
||||
</thing-type>
|
||||
|
||||
|
||||
@@ -21,6 +21,58 @@
|
||||
<label>Name</label>
|
||||
<description>The name of one specific device.</description>
|
||||
</parameter>
|
||||
<parameter name="activateSimpleProtocolSource" type="boolean" required="false">
|
||||
<label>Create an Audio Source with simple-protocol-tcp</label>
|
||||
<description>Activation of a corresponding source in OpenHAB (module-simple-protocol-tcp must be available on the
|
||||
pulseaudio server)</description>
|
||||
<default>false</default>
|
||||
</parameter>
|
||||
<parameter name="simpleProtocolSourcePort" type="integer" required="false">
|
||||
<label>Simple Protocol Port</label>
|
||||
<description>Default Port to allocate to be used by module-simple-protocol-tcp on the pulseaudio server</description>
|
||||
<default>4710</default>
|
||||
</parameter>
|
||||
<parameter name="simpleProtocolSourceIdleTimeout" type="integer" required="false">
|
||||
<label>Idle Timeout</label>
|
||||
<description>Timeout in ms after which the connection will be closed when no stream is running. This ensures that
|
||||
your speaker is not on all the time and the pulseaudio source can go to idle mode. -1 for no disconnection.
|
||||
</description>
|
||||
<default>30000</default>
|
||||
</parameter>
|
||||
<parameter name="simpleProtocolSourceFormat" type="text">
|
||||
<label>Simple Protocol Format</label>
|
||||
<description>The audio format to be used by module-simple-protocol-tcp on the pulseaudio server</description>
|
||||
<default>s16le</default>
|
||||
<advanced>true</advanced>
|
||||
<options>
|
||||
<option value="u8">PCM signed 8-bit</option>
|
||||
<option value="s16le">PCM signed 16-bit little-endian</option>
|
||||
<option value="s16be">PCM signed 16-bit big-endian</option>
|
||||
<option value="s24le">PCM unsigned 24-bit little-endian</option>
|
||||
<option value="s24be">PCM unsigned 24-bit big-endian</option>
|
||||
<option value="s32le">PCM signed 32-bit little-endian</option>
|
||||
<option value="s32be">PCM signed 32-bit big-endian</option>
|
||||
</options>
|
||||
</parameter>
|
||||
<parameter name="simpleProtocolSourceRate" type="integer" min="0">
|
||||
<label>Simple Protocol Rate</label>
|
||||
<description>The audio sample rate to be used by module-simple-protocol-tcp on the pulseaudio server</description>
|
||||
<default>16000</default>
|
||||
<advanced>true</advanced>
|
||||
</parameter>
|
||||
<parameter name="simpleProtocolSourceChannels" type="integer" min="1">
|
||||
<label>Simple Protocol Channels</label>
|
||||
<description>The audio channel number to be used by module-simple-protocol-tcp on the pulseaudio server</description>
|
||||
<default>1</default>
|
||||
<advanced>true</advanced>
|
||||
</parameter>
|
||||
<parameter name="simpleProtocolSOTimeout" type="integer" min="250" max="2000">
|
||||
<label>Simple Protocol SO Timeout</label>
|
||||
<description>Socket SO timeout when connecting to pulseaudio server though module-simple-protocol-tcp. You can tune
|
||||
this option if the socket disconnect frequently.</description>
|
||||
<default>500</default>
|
||||
<advanced>true</advanced>
|
||||
</parameter>
|
||||
</config-description>
|
||||
</thing-type>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user