Skip to main content

A Python library to generate EAS SAME Audio using Raw Data

Project description

EASGen

PyPI GitHub Workflow Status PyPI - Downloads GitHub language count GitHub

A Fast Python EAS Generation Library

Features

  • [x] EAS Generation
  • [x] Individual Header, Attention Tone, and EOM Generation
  • [x] Class and Inline Generation Scripts
  • [x] Fast
  • [x] PyDub AudioSegment Output for Easy Integration
  • [x] Audio File Imput for Audio Injection

Installation

This package should be installable through Pip.

On a Debian Based Linux OS:

sudo apt update
sudo apt install python3 python3-pip
pip3 install EASGen

On Windows:

Install Python

In CMD:

python -m pip install EASGen

Usage

To generate a simple SAME Required Weekly Test:

from EASGen import EASGen
from pydub.playback import play

AlertManager = EASGen.EASGen()
header = "ZCZC-EAS-RWT-005007+0015-0010000-WACNTECH-" ## EAS Header to send
Alert = AlertManager.generateEASAudio(header=header, attentionTone=False, endOfMessage=True) ## Generate an EAS SAME message with no ATTN signal, and with EOMs.
play(Alert) ## Play the EAS Message

To use Inline Generation (Slower):

from EASGen import EASGen
from pydub.playback import play

header = "ZCZC-EAS-RWT-005007+0015-0010000-WACNTECH-" ## EAS Header to send
Alert = EASGen.genEAS(header=header, attentionTone=False, endOfMessage=True) ## Generate an EAS SAME message with no ATTN signal, and with EOMs.
play(Alert) ## Play the EAS Message

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

EASGen-0.1.0.tar.gz (11.7 kB view hashes)

Uploaded Source

Built Distribution

EASGen-0.1.0-py3-none-any.whl (12.0 kB view hashes)

Uploaded Python 3

Supported by

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