Skip to main content

No project description provided

Project description

PCM Player

PCM Player is a Python-based commandline application for playing and testing PCM audio files that are used for creating MSU packs to be used with various emulated games and randomizers, such as A Link to the Past.

Installation

Pre-requisites

  • Python 3.9 or above
  • PortAudio
    • Ubuntu/Debian: apt-get install libportaudio2
    • RHEL: dnf install portaudio
    • Arch: pacman -S portaudio

Installation Option 1: pipx (recommended)

pipx is recommended it installs PCM Player into an isolated environment to avoid dependency conflicts with other Python applications, and it also creates it standalone application which can be ran directly via commandline.

First, you will want to install pipx.

$ pipx install pcm_player

$ pcm_player test.pcm

Installation Option 2: pip

First, make sure you have pip installed and running: https://packaging.python.org/en/latest/tutorials/installing-packages/

$ pip install pcm_player

$ python3 -m pcm_player test.pcm

Usage

Depending on your environment and how you installed, you may be able to run it either directly or as a Python module:

# Run directly
$ pcm_player test.pcm

# Run as Python module
$ python3 -m pcm_player test.pcm

The application has two main modes:

  • Play the full file, then loop and play around 15 seconds
  • Test the loop by playing the last 5 seconds of the file, then loop and play 5 seconds after the loop point
    • If a longer loop is desired, it can be specified in the -s argument

You can run them like below:

# Play the full PCM file, loop, then play 15 seconds
$ pcm_player test.pcm

# Play the last 5 seconds of the PCM file, loop, then play 5 seconds
$ pcm_player -l test.pcm

# Play the last 8 seconds of the PCM file, loop, then play 8 seconds
$ pcm_player -l -s 8 test.pcm

Credits

  • Hazem Nabil (arkrow) for the PyMusicLooper application, which I used as inspiration for how to play sound files and to use Poetry for making/distributing Python applications.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pcm_player-0.3.1.tar.gz (3.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pcm_player-0.3.1-py3-none-any.whl (5.0 kB view details)

Uploaded Python 3

File details

Details for the file pcm_player-0.3.1.tar.gz.

File metadata

  • Download URL: pcm_player-0.3.1.tar.gz
  • Upload date:
  • Size: 3.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.7.1 CPython/3.11.2 Linux/6.5.0-0.deb12.4-amd64

File hashes

Hashes for pcm_player-0.3.1.tar.gz
Algorithm Hash digest
SHA256 2bbbb3f828c5f98abd8c32ca641e2e475d1345664a71693996889e3d836fe0ed
MD5 3a6fcc2c6c2fb246cebded408622e986
BLAKE2b-256 16df1751a6ed76db97820763a3016d03cab0747a7d18a50e656de61701a6700e

See more details on using hashes here.

File details

Details for the file pcm_player-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: pcm_player-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 5.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.7.1 CPython/3.11.2 Linux/6.5.0-0.deb12.4-amd64

File hashes

Hashes for pcm_player-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e8b18a435ceeb2bb8766fcb4e5035ec5ea59bd5527a055f388262b39f596ae01
MD5 04b34d2e0c906abc52c157a6056c7201
BLAKE2b-256 c79e7382b2cc7439e715996b3e56052a70ed97c12a085cc5e9ade7064a3c81b8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page