1
# ckgpio - a Python3 wrapper library for Raspberry Pi GPIO
2
# Copyright (C) 2016 Łukasz "Cyber Killer" Korpalski
4
# This program is free software: you can redistribute it and/or modify
5
# it under the terms of the GNU General Public License as published by
6
# the Free Software Foundation, either version 3 of the License, or
7
# (at your option) any later version.
9
# This program is distributed in the hope that it will be useful,
10
# but WITHOUT ANY WARRANTY; without even the implied warranty of
11
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
# GNU General Public License for more details.
14
# You should have received a copy of the GNU General Public License
15
# along with this program. If not, see <http://www.gnu.org/licenses/>.
17
from gpiozero import LED
20
def __init__(self,sega,segb,segc,segd,sege,segf,segg,segdot,active_high=True):
21
self.sega = LED(sega,active_high=active_high)
22
self.segb = LED(segb,active_high=active_high)
23
self.segc = LED(segc,active_high=active_high)
24
self.segd = LED(segd,active_high=active_high)
25
self.sege = LED(sege,active_high=active_high)
26
self.segf = LED(segf,active_high=active_high)
27
self.segg = LED(segg,active_high=active_high)
28
self.segdot = LED(segdot,active_high=active_high)