Giter Site home page Giter Site logo

picamera-streaming's Introduction

picamera-streaming

Show images over HDMI.

  • p to take an image. Saved as img?.jpg, where ? starts at 0 and increments by one per press
  • z to toggle between 100% crop and full screen (assuming 2560x1440 screen)
  • q quit

For python module keyboard to work without being root: Add user to groups tty and input.

Remove calls to ensure_root in _nixkeyboard.py

web-streaming.py

Run python code on pi, go to :8000 in a web browser. For example fyspi-elab-microscope-nikon.local:8000.

Clicking on the stream stores and shows an image at maximum resolution. Clicking on the image takes you back to the stream. Images are stored to /home/pi/shared/img?.jpg, where ? starts at 0.

The camera will stop recording after 10 minutes. Refreshing the page will restart it.

streaming-microscope.service

fyspi-elab-microscope-nikon and -leica are configured to autostart web streaming and samba sharing of stored images. The configuration is as follows.

To autostart web streaming on start, vopy file to /etc/systemd/system.

sudo systemctl enable streaming-microscope
sudo systemctl start streaming-microscope

It is then not possible to view images over HDMI until the service is stopped

sudo systemctl stop streaming-microscope

To enable samba sharing: sudo apt install samba samba-common-bin

Edit /etc/samba/smb.conf and add:

[microscope]
path = /home/pi/shared
writeable=Yes
create mask=0777
directory mask=0777
public=yes

Enable and start

sudo systemctl start smbd
sudo systemctl enable smbd

picamera-streaming's People

Watchers

 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.