Hi People,
I have a problem. This week I have installed my Raspberry and the PiFace. All software is the newest (install-date: 20-01-2014)
After installing, I tested it with: python3 /usr/share/doc/python3-pifacedigitalio/examples/blink.py
works fine.
When I test this script with Unix command: "top" to see the memory use, the %mem is stable.
When I start (from: /usr/share/doc/python3-pifacedigitalio/examples ):
python ./presslights.py &
or by
python3 ./presslights.py &
the memory use is rising.
After 5 to 8 hours the scripts runs "out of memory".
The only difference with the blink.py script is:
====
pifacedigital = pifacedigitalio.PiFaceDigital()
listener = pifacedigitalio.InputEventListener(chip=pifacedigital)
for i in range(4):
listener.register(i, pifacedigitalio.IODIR_ON, switch_pressed)
listener.register(i, pifacedigitalio.IODIR_OFF, switch_unpressed)
listener.activate()
====
An other Python-script with interrupts (and I stript it totally) gave the problem with the out of memory problem.
After this, I tested the input handling, by using polling instead of interrupts.
With polling the memory is also stable.
My questions:
- Do more people have this problem with interrupts (latest Python version)?
- How can I solve it?
Best regards from the Netherlands,
Jack.