Audio

Audio support for linux.

Simple audio driver for linux.

class mauzr.platform.linux.audio.driver.Driver(core, cfgbase='audio', **kwargs)

Bases: object

Simple audio driver for linux.

Parameters:
  • core (object) – Core instance.
  • cfgbase (str) – Configuration entry for this unit.
  • kwargs (dict) – Keyword arguments that will be merged into the config.

Required core units:

  • mqtt

Configuration:

  • base (str) - Base for topics.

Input topics:

  • /say (str) - Say a given text.
  • /play (str) - Play a file under the given path.
mauzr.platform.linux.audio.driver.main()

Entry point for audio driver.

Controller for linux audio drivers.

class mauzr.platform.linux.audio.controller.Controller(core, cfgbase='audio', **kwargs)

Bases: object

Manage mauzr.linux.audio.linker.Linker over the network.

Parameters:
  • core (object) – Core instance.
  • cfgbase (str) – Configuration entry for this unit.
  • kwargs (dict) – Keyword arguments that will be merged into the config.

Required core units:

  • mqtt

Configuration:

  • base (str) - Base for topics.

Output topics:

  • /say (str) - Say a given text on target device.
  • /play (str) - Play a file under the given path
    on target device.
play(path)

Play a file on the driver device.

Parameters:path (str) – File path on the host.
say(text)

Dispatch a text to the speech dispatcher.

Parameters:text (str) – Text to speak.