Skip to content

Instantly share code, notes, and snippets.

View nioto's full-sized avatar
☎️

Antonio A nioto

☎️
  • Paris, france
View GitHub Profile
@nioto
nioto / PiCameraStream
Created March 4, 2014 10:14
Simple MJpeg streamer for Raspberri Pi Camera
#!/usr/bin/python
'''
A Simple mjpg stream http server for the Raspberry Pi Camera
inspired by https://gist.github.com/n3wtron/4624820
'''
from BaseHTTPServer import BaseHTTPRequestHandler,HTTPServer
import io
import time
import picamera
@nioto
nioto / python_check
Created March 4, 2014 17:24
Some python code snippet
# 1. onliner Python script to show path of module, here picamera
python -c "import picamera; import os.path; print os.path.abspath(picamera.__file__);"
# 2. View Python path
python -c "import sys; print sys.path;"
# 3. Code for modifying path of Python modules
import sys
sys.path.insert(0, "/usr/local/lib/python2.7/dist-package")