Skip to content

Commit 63025bb

Browse files
author
Thomas Preston
committed
fixed for pi2 device tree
1 parent a319522 commit 63025bb

File tree

4 files changed

+14
-6
lines changed

4 files changed

+14
-6
lines changed

CHANGELOG

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,24 @@
11
Change Log
22
==========
3+
4+
v4.1.1
5+
------
6+
- Fixed bug with new Device Tree (Pi2) by changing GPIO_INTERRUPT_DEVICE
7+
from `/sys/devices/virtual/gpio/` to `/sys/class/gpio/` and changing udev
8+
rule.
9+
10+
311
v4.1.0
412
------
513
- Added deregister to interrupts
614

715

8-
916
v4.0.1
1017
------
1118
- Fixed SPI file descriptor bug when closing.
1219
- Fixed issue #14.
1320

21+
1422
v4.0.0
1523
------
1624
- Ignored "Interrupted system call" error in `watch_port_events`.

pifacecommon/interrupts.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
# IN_EVENT_DIR_BOTH = INPUT_DIRECTION_BOTH = None
1616

1717
GPIO_INTERRUPT_PIN = 25
18-
GPIO_INTERRUPT_DEVICE = "/sys/devices/virtual/gpio/gpio%d" % GPIO_INTERRUPT_PIN
18+
GPIO_INTERRUPT_DEVICE = "/sys/class/gpio/gpio%d" % GPIO_INTERRUPT_PIN
1919
GPIO_INTERRUPT_DEVICE_EDGE = '%s/edge' % GPIO_INTERRUPT_DEVICE
2020
GPIO_INTERRUPT_DEVICE_VALUE = '%s/value' % GPIO_INTERRUPT_DEVICE
2121
GPIO_EXPORT_FILE = "/sys/class/gpio/export"

pifacecommon/spi.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,9 @@ def __init__(self, bus=0, chip_select=0, spi_callback=None):
3131
spi_device = "%s%d.%d" % (SPIDEV, self.bus, self.chip_select)
3232
self.open_fd(spi_device)
3333

34-
def __del__(self):
35-
if self.fd is not None:
36-
self.close_fd()
34+
# def __del__(self):
35+
# if self.fd is not None:
36+
# self.close_fd()
3737

3838
def open_fd(self, spi_device):
3939
try:

pifacecommon/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = '4.1.0'
1+
__version__ = '4.1.1'

0 commit comments

Comments
 (0)