Giter VIP home page Giter VIP logo

audio_utils's Introduction

audio_utils

ROS nodes and utilities for audio streams.

Author(s): Marc-Antoine Maheux

Setup (Ubuntu)

The following subsections explain how to use the library on Ubuntu.

Install Dependencies

sudo apt-get install cmake build-essential gfortran texinfo libasound2-dev

Setup Submodules

git submodule update --init --recursive

Nodes

alsa_capture_node

This node captures the sound from an ALSA device and publishes it to a topic.

Parameters

  • device (string): The ALSA device to capture (ex: hw:CARD=1,DEV=0).
  • format (string): The audio format (see audio_utils/AudioFrame).
  • channel_count (int): The device channel count.
  • sampling_frequency (int): The device sampling frequency.
  • frame_sample_count (int): The number of samples in each frame.
  • merge (bool): Indicate to merge the channels or not.
  • merge_gain: The gain to apply after the merge.

Published Topics

alsa_playback_node

This node captures the sound from a topic and plays it to an ALSA device.

Parameters

  • device (string): The ALSA device to capture (ex: hw:CARD=1,DEV=0).
  • format (string): The audio format (see audio_utils/AudioFrame).
  • channel_count (int): The device channel count.
  • sampling_frequency (int): The device sampling frequency.
  • frame_sample_count (int): The number of samples in each frame.

Subscribed Topics

beat_detector_node

This node estimates the song tempo and detects if the beat is in the current frame.

Subscribed Topics

  • audio_in (audio_utils/AudioFrame) The sound to analyze. The channel count must be 1, the sampling frequency must be 44100 Hz and the frame sample count must be 256.

Published Topics

  • bpm (std_msgs/Float32): The tempo in bpm (beats per minute) for each frame.
  • beat (std_msgs/Bool): Indicate if the beat is in the current frame.

format_conversion_node.py

This node converts the format of an audio topic.

Parameters

Subscribed Topics

Published Topics

resampling_node.py

This node resamples an audio topic.

Parameters

  • input_format (string): The input audio format (see audio_utils/AudioFrame).
  • output_format (string): The output audio format (see audio_utils/AudioFrame).
  • channel_count (int): The device channel count.
  • input_sampling_frequency (int): The input sampling frequency.
  • output_sampling_frequency (int): The output sampling frequency.
  • input_frame_sample_count (int): The number of samples in each frame of the input.

Subscribed Topics

Published Topics

split_channel_node.py

This node split a multichannel audio topic into several mono audio topics.

Parameters

Subscribed Topics

Published Topics

raw_file_writer_node.py

This node writes the raw sound data to a file.

Parameters

  • output_path (string): The output file path.

Subscribed Topics

audio_utils's People

Contributors

mamaheux avatar doumdi avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.