Skip to content

Raspberry Pi Geocache Update

First of all, sorry for the long absence. I’m involved in many projects and I couldn’t get to this earlier.

Here are the updates:

I’ve bought an extender for the RP pins from Jola Engineering and soldered the shim onto it. Now I can put everything together nicely.

Această prezentare necesită JavaScript.

After that I’ve started playing with the PiFace using the pifacecad library.

The initial test was just to show stuff on the screen, and then I wanted to use the buttons to do something with them, but…. apparently, I couldn’t. It seems that the Linux kernel 4.1.6-v7+ on the latest Rasbian, has a bug with the epoll system call that causes it not to react to hardware interrupts on GPIO25 (RP pin 22).

More info and explanation can be found in this bug report.

Here’s the sample code I’ve used from the pifacecad documentation:

>>> import pifacecad
>>> def update_pin_text(event):
...     event.chip.lcd.set_cursor(13, 0)
...     event.chip.lcd.write(str(event.pin_num))
...
>>> cad = pifacecad.PiFaceCAD()
>>> cad.lcd.backlight_on()
>>> cad.lcd.write("You pressed: ")
>>> listener = pifacecad.SwitchEventListener(chip=cad)
>>> for i in range(8):
...     listener.register(i, pifacecad.IODIR_FALLING_EDGE, update_pin_text)
>>> listener.activate()

Because of this, I’ll put the piface on the side for now and continue to play with the GPS module.

I’ve yet to find a good battery that I can use, to make the RP portable.

Published inHardwareProjectsSoftware

Be First to Comment

Lasă un răspuns