MMM-voice

by fewieden

master7db59d7  created June 3rd 2017

other versions

3
Modules
20
Functions

module:MMM-voice

Kind
module

Frontend for the module to display data.

fx
MMM-voiceappendHelp
  • appendTo

Kind
function
Scope
inner

Creates the UI for the voice command SHOW HELP.

Arguments:

  1. appendTo

    DOM Element where the UI gets appended as child.

MMM-voicedefaults

Kind
member
Type
Scope
inner

Defines the default config values.

Properties:

  1. timeout

    Seconds to active listen for commands.

  2. keyword

    Keyword to activate active listening.

  3. debug

    Flag to enable debug information.

fx
MMM-voicegetDom

    Kind
    function
    Scope
    inner

    Creates the UI as DOM for displaying in MagicMirror application.

    Returns:

    fx
    MMM-voicegetStyles

      Kind
      function
      Scope
      inner

      Style dependencies for this module.

      Returns:

      1. List of the style dependency filepaths.

      fx
      MMM-voicegetTranslations

        Kind
        function
        Scope
        inner

        Translations for this module.

        Returns:

        1. Available translations for this module (key: language code, value: filepath).

        fx
        MMM-voicenotificationReceived
        • notification
        • payload

        Kind
        function
        Scope
        inner

        Handles incoming broadcasts from other modules or the MagicMirror core.

        Arguments:

        1. notification

          Notification name

        2. payload

          Detailed payload of the notification.

        fx
        MMM-voicesocketNotificationReceived
        • notification
        • payload

        Kind
        function
        Scope
        inner

        Handles incoming messages from node_helper.

        Arguments:

        1. notification

          Notification name

        2. payload

          Detailed payload of the notification.

        fx
        MMM-voicestart

          Kind
          function
          Scope
          inner

          Sets mode to initialising.

          MMM-voicevoice

          Kind
          member
          Type
          Scope
          inner

          Defines the default mode and commands of this module.

          Properties:

          1. mode

            Voice mode of this module.

          2. sentences

            List of voice commands of this module.

          module:node_helper

          Kind
          module
          Scope
          inner

          Backend for the module to query data from the API providers.

          fx
          node_helpercheckCommands
          • data

          Kind
          function
          Scope
          inner

          Checks for commands of voice module

          Arguments:

          1. data

            Recognized data

          fx
          node_helpercheckFiles

            Kind
            function
            Scope
            inner

            Checks if words.json exists or has different entries as this.word.

            fx
            node_helpercleanData
            • data

            Kind
            function
            Scope
            inner

            Removes prefix/keyword and multiple spaces.

            Arguments:

            1. data

              Recognized data to clean.

            Returns:

            1. Cleaned data

            fx
            node_helperfillwords

              Kind
              function
              Scope
              inner

              Sets node_helper.words with all needed words for the registered commands by the modules. This list has unique items and is sorted by alphabet.

              fx
              node_helpergenerateDicLM

                Kind
                function
                Scope
                inner

                Generates new Dictionairy and Language Model.

                fx
                node_helperhandleData
                • data

                Kind
                function
                Scope
                inner

                Helper method to handle recognized data.

                Arguments:

                1. data

                  Recognized data

                fx
                node_helperlogDebug
                • data

                Kind
                function
                Scope
                inner

                Logs debug information into debug log file.

                Arguments:

                1. data

                  Debug information

                fx
                node_helperlogError
                • data

                Kind
                function
                Scope
                inner

                Logs error information into error log file.

                Arguments:

                1. data

                  Error information

                node_helpermodules

                Kind
                member
                Type
                Scope
                inner

                List of modules with their modes and commands.

                fx
                node_helpersocketNotificationReceived
                • notification
                • payload

                Kind
                function
                Scope
                inner

                Receives socket notifications from the module.

                Arguments:

                1. notification

                  Notification name

                2. payload

                  Detailed payload of the notification.

                fx
                node_helperstart

                  Kind
                  function
                  Scope
                  inner

                  Logs a start message to the console.

                  fx
                  node_helperstartPocketsphinx

                    Kind
                    function
                    Scope
                    inner

                    Starts Pocketsphinx binary.