communicate with a lewei camera module
Project description
pylwdrone
Python package to communicate with a drone's lewei camera module. This module does not control the drone's flight yet.
Example Command-line Usage
Stream live video
$ pylwdrone stream start --out-file - | ffplay -i -
Record live video then replay later
$ pylwdrone rec start
$ pylwdrone rec stop
$ pylwdrone rec list
index start duration path
[ 0] 20200604_04:01:27 95 /mnt/Video/20200604-040126.mp4
[ 1] 20200604_04:10:40 20 /mnt/Video/20200604-041040.mp4
success
$ pylwdrone rec play 0 --out-file - | ffplay -i -
Example Module Usage
Creating the object
>>> import pylwdrone
>>> drone = pylwdrone.LWDrone()
Stream live video
>>> for frame in drone.start_video_stream():
>>> sys.stdout.buffer.write(frame.frame_bytes)
Get a file
>>> with open('video.mp4', 'wb') as fp:
>>> drone.get_file('/mnt/Video/20200604-041040.mp', fp)
Take a picture
>>> with open('picture.jpg', 'wb') as fp:
>>> fp.write(drone.take_picture())
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pylwdrone-0.5.0.zip
(27.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
pylwdrone-0.5.0-py3-none-any.whl
(24.5 kB
view details)
File details
Details for the file pylwdrone-0.5.0.zip.
File metadata
- Download URL: pylwdrone-0.5.0.zip
- Upload date:
- Size: 27.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.6.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.1 CPython/3.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
033e7b1983b70ca34dc293224132316ce32539523c4f04b377ad40fbc0978f80
|
|
| MD5 |
17cef8ccd7602705531f1e7ac4098729
|
|
| BLAKE2b-256 |
852ac4e892a79d07a6fce3183a183b2896e1f1e7645160b11ca72bfaaaca7d1b
|
File details
Details for the file pylwdrone-0.5.0-py3-none-any.whl.
File metadata
- Download URL: pylwdrone-0.5.0-py3-none-any.whl
- Upload date:
- Size: 24.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.6.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.1 CPython/3.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1fee22d208cc46f4fa165e57b2b39ee279b550bb3aeccf4cc14f3562be428043
|
|
| MD5 |
ce454a15ac84b739573604c7f54d43ba
|
|
| BLAKE2b-256 |
c7e6975725665a0e1caba439b48e90ddc19c7a9af69c8efc91d7e3e223481ad2
|