Skip to content
This repository was archived by the owner on Jul 30, 2021. It is now read-only.

Repository files navigation

Python Arlo

https://travis-ci.org/tchellomello/python-arlo.svg?branch=masterhttps://coveralls.io/repos/github/tchellomello/python-arlo/badge.svg?branch=master

RETIRED:

Please visit the awesome work by @twrecked at https://github.com/twrecked/hass-aarlo

Python Arlo is a library written in Python 2.7/3x that exposes the Netgear Arlo cameras as Python objects.

Developer Documentation: http://python-arlo.readthedocs.io/

Installation

$ pip install pyarlo
# Install latest development
$ pip install git+https://github.com/tchellomello/python-arlo

Usage

# connectingfrompyarloimportPyArloarlo=PyArlo('foo@bar', 'secret')
# listing devicesarlo.devices# listing base stationsarlo.base_stations# get base station handle# assuming only 1 base station is availablebase=arlo.base_stations[0]
# get the current base station modebase.mode# 'disarmed'# listing Arlo modesbase.available_modes# ['armed', 'disarmed', 'schedule', 'custom']# Updating the base station modebase.mode='custom'# listing all camerasarlo.cameras# showing camera preferencescam=arlo.cameras[0]
# check if camera is connected to base stationcam.is_camera_connected# True# printing camera attributescam.serial_numbercam.model_idcam.unseen_videos# get brightness value of cameracam.brightness# get signal strength of camera with base stationcam.signal_strength# get flip property from cameracam.flip_state# get mirror property from cameracam.mirror_state# get power save mode value from cameracam.powersave_mode# get current battery level of cameracam.battery_level92# get boolean result if motion detection# is enabled or notbase.is_motion_detection_enabled# True# get battery levels of all cameras# prints serial number and battery level of each camerabase.get_cameras_battery_level# {'4N71235T12345': 92, '4N71235T12345': 90}# get base station propertiesbase.properties# get camera propertiesbase.get_camera_properties# get camera rulesbase.get_camera_rules# get camera schedulebase.get_camera_schedule# get camera motion detection sensitivitycam.get_motion_detection_sensitivity# refreshing camera propertiescam.update()
# gathering live_streaming URLcam.live_streaming() # rtmps://vzwow72-z2-prod.vz.netgear.com:80/vzmodulelive?egressToken=b723a7bb_abbXX&userAgent=web&cameraId=48AAAAA# gather last recorded video URLcam.last_video.video_url

Loading Videos

# by default, all videos recorded within# the last 30 days will be pre-loadedarlo.ArloMediaLibrary.videos# Or you can load Arlo videos directlyfrompyarlo.mediaimportArloMediaLibrarylibrary=ArloMediaLibrary(arlo, days=2)
len(library.videos)
# showing a video propertiesmedia=library.videos[0]
# printing video attributesmedia.cameramedia.content_typemedia.media_duration_seconds# displaying thumbnail to stdoutmedia.download_thumbnail()
# downloading videomedia.download_video('/home/user/demo.mp4')

Ambient Sensors Data Usage (Arlo Baby Monitor)

# Get the base_station instance corresponding to the Arlo Babybase_station=arlo.base_stations[0]
# Store all ambient sensor history in self._ambient_sensor_data# All of the accessor properties will call this if values are not cached.base_station.get_ambient_sensor_data()
# Get cached sensor history (property)base_station.ambient_sensor_data# Get most recent temperature reading in degrees celsius (property)base_station.ambient_temperature# Get most recent humidity reading in relative humidity percentage (property)base_station.ambient_humidity# Get most recent air quality reading (property)# Not 100% sure on the unit of measure, but would assume it's VOC PPMbase_station.ambient_air_quality

Music Playback Usage (Arlo Baby Monitor)

# Get the current playback status and available track listbase_station.get_audio_playback_status()
# Play a track, optionally specify the track and seek time in secondsbase_station.play_track(
track_id='229dca67-7e3c-4a5f-8f43-90e1a9bffc38',
position=0)
# Pause the currently playing trackbase_station.pause_track()
# Skip to the next track in the playlistbase_station.skip_track()
# Set the music loop mode to repeat the entire playlistbase_station.set_music_loop_mode_continuous()
# Set the music loop mode to repeat the current trackbase_station.set_music_loop_mode_single()
# Sets playback to shufflebase_station.set_shuffle_on()
# Sets playback to sequentialbase_station.set_shuffle_off()
# Change the playback volumebase_station.set_volume(100)

Night Light Usage (Arlo Baby Monitor)

# Turn on the night lightbase_station.set_night_light_on()
# Turn off the night lightbase_station.set_night_light_off()
# Set the brightness of the night lightbase_station.set_night_light_brightness(200)

Supported Devices

If you have a different model, please feel free to contribute by reporting your results.

ModelTested byStatusResults/Issues
Arlo 1st Generation@tchellomelloworking/okN/A
Arlo 2st Generation@tchellomelloworking/okN/A

Contributing

See more at CONTRIBUTING.rst.

About

Python Arlo is a library written in Python 2.7/3x that exposes the Netgear Arlo cameras as Python objects.

Topics

Resources

Contributing

Stars

102 stars

Watchers

3 watching

Forks

Releases

Packages

Used by

Contributors

Languages