mirror of
https://github.com/dbarzin/pandora-box.git
synced 2025-07-19 05:19:40 +02:00
work in progress
This commit is contained in:
parent
248102325f
commit
d9cc0b1ef2
2 changed files with 27 additions and 0 deletions
13
tests/README.md
Normal file
13
tests/README.md
Normal file
|
@ -0,0 +1,13 @@
|
|||
Pandora-box Tests
|
||||
-----------------
|
||||
|
||||
This folder contains pandora-box basic function tests :
|
||||
|
||||
- scan.py : scan a file with pandora API
|
||||
- detect-usb.py : detect the insertion and removal of USB key
|
||||
- images.py : display an image on the console
|
||||
- loop.py : a loop between two images waiting for mouse click
|
||||
- slideshow.py : an other loop between two images waiting for mouse click
|
||||
- mouse-click.py : detect mouse click
|
||||
- screen.py : print pandora-box logo using curses
|
||||
- progress-bar.py : progres bar using curses
|
14
tests/slideshow.py
Executable file
14
tests/slideshow.py
Executable file
|
@ -0,0 +1,14 @@
|
|||
#!/usr/bin/python3
|
||||
import os;
|
||||
|
||||
def waitMouseClick():
|
||||
mouse = open( "/dev/input/mice", "rb" )
|
||||
while True:
|
||||
buf = mouse.read(3)
|
||||
if ((buf[0] & 0x1)==1):
|
||||
break;
|
||||
mouse.close()
|
||||
|
||||
os.system("fim *.png -qa -c 'while(1){display;sleep 1;next;}' </dev/null 2>/dev/null &")
|
||||
waitMouseClick()
|
||||
os.system("killall fim")
|
Loading…
Add table
Add a link
Reference in a new issue