doc + facke test
This commit is contained in:
parent
95f2b8c7c9
commit
8089e60838
6
gfxlcd/tests/dummy_test.py
Normal file
6
gfxlcd/tests/dummy_test.py
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
from nose.tools import assert_equal
|
||||||
|
|
||||||
|
|
||||||
|
class DummyTest(object):
|
||||||
|
def test_init(self):
|
||||||
|
assert_equal(1, 1)
|
24
readme.md
24
readme.md
@ -16,7 +16,7 @@ Wiring is below
|
|||||||
|
|
||||||
Initialization
|
Initialization
|
||||||
===
|
===
|
||||||
##SSD1306
|
## SSD1306
|
||||||
### SPI
|
### SPI
|
||||||
|
|
||||||
from driver.ssd1306.spi import SPI
|
from driver.ssd1306.spi import SPI
|
||||||
@ -35,7 +35,7 @@ If you want to set your own pins:
|
|||||||
o = SSD1306(128, 64, drv)
|
o = SSD1306(128, 64, drv)
|
||||||
o.init()
|
o.init()
|
||||||
|
|
||||||
##NJU6450
|
## NJU6450
|
||||||
### GPIO
|
### GPIO
|
||||||
|
|
||||||
from gfxlcd.driver.nju6450.gpio import GPIO
|
from gfxlcd.driver.nju6450.gpio import GPIO
|
||||||
@ -66,7 +66,7 @@ Custom wiring:
|
|||||||
o = NJU6450(122, 32, drv)
|
o = NJU6450(122, 32, drv)
|
||||||
o.init()
|
o.init()
|
||||||
|
|
||||||
##ILI9325
|
## ILI9325
|
||||||
### GPIO
|
### GPIO
|
||||||
|
|
||||||
from gfxlcd.driver.ili9325.gpio import GPIO
|
from gfxlcd.driver.ili9325.gpio import GPIO
|
||||||
@ -99,17 +99,17 @@ Custom pins:
|
|||||||
|
|
||||||
Drawing functions
|
Drawing functions
|
||||||
===
|
===
|
||||||
draw_pixel
|
draw_pixel(x, y)
|
||||||
|
|
||||||
draw_line
|
draw_line(from_x, from_y, to_x, to_y)
|
||||||
|
|
||||||
draw_rect
|
draw_rect(x1, y1, x2, y2)
|
||||||
|
|
||||||
draw_circle
|
draw_circle(x1, y1, radius)
|
||||||
|
|
||||||
draw_arc
|
draw_arc(x1, y1, radius, from_angle, to_angle
|
||||||
|
|
||||||
fill_rect
|
fill_rect(x1, y1, x2, y2)
|
||||||
|
|
||||||
|
|
||||||
Colours
|
Colours
|
||||||
@ -121,7 +121,7 @@ lcd.background_color = (r, g ,b)
|
|||||||
Wiring
|
Wiring
|
||||||
===
|
===
|
||||||
|
|
||||||
##SSD1306
|
## SSD1306
|
||||||
### SPI
|
### SPI
|
||||||
SPI wiring + 2 additional pins. Defaults:
|
SPI wiring + 2 additional pins. Defaults:
|
||||||
|
|
||||||
@ -134,7 +134,7 @@ SPI wiring + 2 additional pins. Defaults:
|
|||||||
D/C ----------- G6
|
D/C ----------- G6
|
||||||
|
|
||||||
|
|
||||||
##NJU6450
|
## NJU6450
|
||||||
### GPIO
|
### GPIO
|
||||||
Default wiring:
|
Default wiring:
|
||||||
|
|
||||||
@ -159,7 +159,7 @@ Default wiring:
|
|||||||
17 (A) ------- +5V
|
17 (A) ------- +5V
|
||||||
18 (K) ------- GND
|
18 (K) ------- GND
|
||||||
|
|
||||||
##ILI9325
|
## ILI9325
|
||||||
### GPIO
|
### GPIO
|
||||||
Default:
|
Default:
|
||||||
|
|
||||||
|
2
tox.ini
2
tox.ini
@ -10,7 +10,7 @@ deps=
|
|||||||
flake8
|
flake8
|
||||||
pylint
|
pylint
|
||||||
whitelist_externals = /bin/bash
|
whitelist_externals = /bin/bash
|
||||||
commands= nosetests --with-xunit --xunit-file=junit-{envname}.xml charlcd/tests
|
commands= nosetests --with-xunit --xunit-file=junit-{envname}.xml gfxlcd/tests
|
||||||
rm flake8-{envname}.log
|
rm flake8-{envname}.log
|
||||||
/bin/bash -c "flake8 --output-file=flake8-{envname}.log gfxlcd || :"
|
/bin/bash -c "flake8 --output-file=flake8-{envname}.log gfxlcd || :"
|
||||||
/bin/bash -c "pylint gfxlcd > pylint-{envname}.log || :"
|
/bin/bash -c "pylint gfxlcd > pylint-{envname}.log || :"
|
||||||
|
Loading…
Reference in New Issue
Block a user