Skip to content
This repository has been archived by the owner on Apr 1, 2023. It is now read-only.
/ stream Public archive

Stream from Raspberry Pi to Django website with WebSockets

License

Notifications You must be signed in to change notification settings

MAKENTNU/stream

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

42 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

[This repo has been discontinued; streaming on our printers is instead done through OctoPrint, which is set up through the octopi-setup repo]

stream

Stream from Raspberry Pi to Django website with WebSockets.

Setup

  1. Enter the home folder if you are not already there: cd /home/pi/
  2. Clone this repository: git clone https://github.com/MAKENTNU/stream.git
  3. Enter the newly created stream folder: cd stream/

The rest of the steps can be completed by running the setup script ./setup.sh. It will ask for the stream name, which can only consist of english letters, numbers, hyphens or underscores. The secret can be found on locally on the MAKE NTNU server in local_settings.py and is called stream_key.

The RPi will reboot once the script is done and the stream should now be visible on the website.

The STREAM_NAME and KEY can be edited manually if needed:

  1. Enter stream folder cd stream
  2. Edit file nano local_settings.py
  3. reboot

The steps that the script does, is described below.

  1. Create a virtual environment sudo virtualenv -p python3 env_stream
  2. Source environment source env_stream/bin/activate
  3. Install system libraries sudo apt install libopenjp2-7 libtiff5 libjpeg-dev python3-dev
  4. Install requirements pip install -r requirements.txt
  5. Deactivate environment deactivate
  6. Copy service to systemd sudo cp stream.service /etc/systemd/system/stream.service
  7. Enable service sudo systemctl enable stream
  8. Start service sudo systemctl start stream

Detailed guide of the hardware setup is available on MAKE NTNU's Google Drive.

About

Stream from Raspberry Pi to Django website with WebSockets

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published