Application to cast streams to chromecast
Note: Designed to work with Rpi 4. Any installation process works for the Rpi4.
Production installation
Using pip (Windows/Linux/osX)
This requires to have python3 installed and pip installed. Optionally also venv.
- (Optional) Create virtual environment to avoid dependency issues.
- Example using venv:
- Create:
python3 -m venv <DIR> - Start: linux -
source <DIR>/bin/activate- windows -<DIR>/Scripts/activate - Stop:
deactivate - To clear delete the directory and create again
rm -r <DIR>
- Create:
- Example using venv:
- Install package from pip:
- Linux/osX:
python3 -m pip install audio_cast - Windows:
py -m pip install audio_cast
- Linux/osX:
- Install required applications:
- Install vlc:
- Linux/osX has 2 alternatives:
- Install required libraries:
sudo apt install vlc-binsudo apt install vlc-plugin-base
- Install VLC
sudo apt install vlc
- Install required libraries:
- Windows: Install vlc from their website.
- Linux/osX has 2 alternatives:
- (Only Linux/osX) Install
libportaudio2:sudo apt install libportaudio2
- Install vlc:
- Install a WSGI server.
- Waitress:
pip install waitress
- Waitress:
- Run WSGI server.
- Example:
waitress-serve --call --host=localhost --port=5000 'audio_cast:create_app'
- Example:
Using apt (Linux)
Dev Usage
- When using VS Code, just run the debugger.
- Optional: Use a virtual environment.
- When starting from termimal.
- Set environment variable for
FLASK_APPtoaudio_cast.- Linux/osX:
export set FLASK_APP=audio_cast - Windows cmd:
set FLASK_APP=audio_cast - Windows powershell:
$Env:FLASK_APP = "audio_cast"
- Linux/osX:
- Launch the server with
python -m flask run.
- Set environment variable for
Cheatsheet
- To upload to pypi:
- Build:
py -m build - Deploy:
py -m twine upload dist/*
- Build:
- To run locally:
- Set environment variable
FLASK_APP=audio_cast
- Set environment variable
- To run after installation from package:
- Install waitress
python3 -m pip install waitress - Run waitress
waitress-serve --call --host=localhost --port=5000 'audio_cast:create_app'
- Install waitress
- Virtual environment:
- Create:
python3 -m venv <DIR> - Start: linux -
source <DIR>/bin/activate- windows -<DIR>/Scripts/activate - Stop:
deactivate - To clear delete the directory and create again
rm -r <DIR>
- Create:
- Install packages from
requirements.txtpip install -r requirements.txt.
Rpi steps
- Install pip using apt
sudo apt install python3-pip - Install venv using apt
sudo apt install python3-venv. - Create virtual environment and activate it.
- Install waitress.
- Run waitress, run it without host so it is exposed.
- Install vlc
sudo apt install vlc- Hopefully this can be changed to either incorporating the libvlc libraries or installing a part of vlc. Right now it's around 1 gb, which seems too much for the use needed.
- Or install vlc-bin and vlc-plugin-base.
sudo apt install vlc-binandsudo apt install vlc-plugin-base. It's smaller but still big. Aroung 700MB. - Still there might be a better way.
- Install PortAudio using apt
sudo apt install libportaudio2.
Metadata
Release files for audio-cast 0.0.16
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| audio-cast-0.0.16.tar.gz | 18.3 kB | Without provenance | Details for audio-cast-0.0.16.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| audio_cast-0.0.16-py3-none-any.whl | Python 3 | none | any | Details for audio_cast-0.0.16-py3-none-any.whl |
Total release size: 37.8 kB
Release files / audio-cast-0.0.16.tar.gz
| Download URL | audio-cast-0.0.16.tar.gz |
|---|---|
| Size | 18.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a86c70219b7fb9bdb20ac5932174d13fdb9926e26f41ac57bb7ac447eee6ffd3
|
|
BLAKE2b-256 checksum How to use checksums |
0800c788a8cd4dc73b36bc08118704b4aa5d9f8a7e6c0678d6d87f360e099a9b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
|
Release files / audio_cast-0.0.16-py3-none-any.whl
| Download URL | audio_cast-0.0.16-py3-none-any.whl |
|---|---|
| Size | 19.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7ef8760e1f12a816791d90c1de2ffd54ef20af03ee97048d022581999b438843
|
|
BLAKE2b-256 checksum How to use checksums |
2efb7e9ceea7a1ef8b715bd605b29db0e88d528c6cf84fd60694d85d9e24bd7b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
|
Security for audio-cast 0.0.16
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.