-
Notifications
You must be signed in to change notification settings - Fork 40
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
227 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
.rst-content a, .rst-content a:focus { | ||
color:#13c0d7; | ||
} | ||
.rst-content a:visited, .rst-content a:active { | ||
color:#87319a; | ||
} | ||
.rst-content .highlighted { | ||
background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAJElEQVQIW2P8//9/PSMjYyMDEmAEsdElwILoEnBBZAkUQZgEABMWE4Kzp1KUAAAAAElFTkSuQmCC),rgba(246,167,4,0.2); | ||
margin:0 -6px; | ||
} | ||
.wy-side-nav-search { | ||
background:#333333; | ||
} | ||
.wy-nav-side { | ||
background:#444444; | ||
} | ||
.rst-content dl:not(.docutils) dt { | ||
background:#e7fafd; | ||
border-top:solid 3px #13c0d7; | ||
color:rgba(0,0,0,0.5); | ||
} | ||
.rst-content .viewcode-link, .rst-content .viewcode-back { | ||
color:#00b09b; | ||
} | ||
code.literal { | ||
color:#e63c2e; | ||
} | ||
.rst-content #at-a-glance { | ||
margin-bottom:24px; | ||
} | ||
.rst-content #at-a-glance dt, | ||
.rst-content #at-a-glance dd dl:not(.docutils) dt { | ||
border:none; | ||
background:#f0f0f0; | ||
} | ||
.rst-content #at-a-glance dd dl:not(.docutils) dd { | ||
display:none; | ||
} | ||
.rst-content #at-a-glance dd dl:not(.docutils) { | ||
margin-bottom:0; | ||
} |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
{% extends "!layout.html" %} | ||
{% block extrahead %} | ||
<link rel="stylesheet" href="{{ pathto("_static/custom.css", True) }}" type="text/css"> | ||
{% endblock %} | ||
{% block footer %} | ||
<script type="text/javascript"> | ||
var menuItems = $('.wy-menu-vertical').find('a'); | ||
|
||
var scrollItems = menuItems.map(function(){ | ||
var item = $($(this).attr('href')); | ||
if (item.length) { return item; } | ||
}); | ||
|
||
$(window).on('scroll',function(){ | ||
var fromTop = $(this).scrollTop() | ||
|
||
var cur = scrollItems.map(function(){ | ||
if ($(this).offset().top < fromTop+30) return this; | ||
}); | ||
|
||
cur = cur[cur.length-1]; | ||
var id = cur && cur.length ? cur[0].id : ""; | ||
|
||
var target = $('#'+id); | ||
target.attr('id',''); | ||
window.location.hash = '#'+id; | ||
target.attr('id',id); | ||
|
||
menuItems | ||
.parent().removeClass("current") | ||
.end().filter("[href='#"+id+"']").parent().addClass("current"); | ||
}); | ||
|
||
$(window).on('hashchange',function(){ | ||
|
||
var hash = window.location.hash.replace('#',''); | ||
|
||
menuItems | ||
.parent().removeClass("current") | ||
.end().filter("[href='#"+hash+"']").parent().addClass("current"); | ||
}) | ||
</script> | ||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,90 @@ | ||
============ | ||
PanTilt HAT! | ||
============ | ||
.. role:: python(code) | ||
:language: python | ||
|
||
Welcome to the PanTilt HAT documentation. | ||
Welcome | ||
------- | ||
|
||
Function Reference | ||
================== | ||
This documentation will guide you through the methods available in the Pan Tilt HAT python library. | ||
|
||
.. autoclass:: pantilthat.PanTilt | ||
Pan-Tilt HAT lets you mount and control one of our pan-tilt modules right on top of your Raspberry Pi. The HAT and its on-board microcontroller let you independently drive the two servos (pan and tilt), as well as driving up to 24 regular LED (with PWM control) or NeoPixel RGB (or RGBW) LEDs | ||
|
||
* More information - https://shop.pimoroni.com/products/pan-tilt-hat | ||
* Get the code - https://github.com/pimoroni/pantilt-hat | ||
* Get help - http://forums.pimoroni.com/c/support | ||
|
||
At A Glance | ||
----------- | ||
|
||
.. autoclassoutline:: pantilthat.PanTilt | ||
:members: | ||
|
||
Constants | ||
Set Brightness | ||
-------------- | ||
|
||
.. automethod:: pantilthat.pantilthat.brightness | ||
|
||
Clear | ||
----- | ||
|
||
.. automethod:: pantilthat.pantilthat.clear | ||
|
||
Set Light Mode | ||
-------------- | ||
|
||
.. automethod:: pantilthat.pantilthat.light_mode | ||
|
||
Pan | ||
--- | ||
|
||
.. automethod:: pantilthat.pantilthat.pan | ||
|
||
.. automethod:: pantilthat.pantilthat.servo_one | ||
|
||
Tilt | ||
---- | ||
|
||
.. automethod:: pantilthat.pantilthat.tilt | ||
|
||
.. automethod:: pantilthat.pantilthat.servo_two | ||
|
||
Servo Enable | ||
------------ | ||
|
||
.. automethod:: pantilthat.pantilthat.servo_enable | ||
|
||
Servo Pulse Min | ||
--------------- | ||
|
||
.. automethod:: pantilthat.pantilthat.servo_pulse_min | ||
|
||
Servo Pulse Max | ||
--------------- | ||
|
||
.. automethod:: pantilthat.pantilthat.servo_pulse_max | ||
|
||
Set All LEDs | ||
------------ | ||
|
||
.. automethod:: pantilthat.pantilthat.set_all | ||
|
||
Set A LED | ||
--------- | ||
|
||
WS2812 = 1 | ||
PWM = 0 | ||
.. automethod:: pantilthat.pantilthat.set_pixel | ||
|
||
Set A LED (RGBW) | ||
---------------- | ||
|
||
.. automethod:: pantilthat.pantilthat.set_pixel_rgbw | ||
|
||
Show | ||
---- | ||
|
||
Indices and tables | ||
================== | ||
.. automethod:: pantilthat.pantilthat.show | ||
|
||
Constants | ||
--------- | ||
|
||
* :ref:`genindex` | ||
* :ref:`search` | ||
* :python:`WS2812 = 1` - used with :python:`pantilthat.light_mode` to set WS2812 LEDs | ||
* :python:`PWM = 0` - used with :python:`pantilthat.light_mode` to set PWM dimmed LEDs | ||
|
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.