Skip to content

Commit 70f989b

Browse files
authored
Merge pull request #1090 from MiczFlor/develop
Release 2.1.1
2 parents 04c90ec + bb7d50f commit 70f989b

8 files changed

Lines changed: 18 additions & 18 deletions

File tree

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,11 @@ A contactless jukebox for the Raspberry Pi, playing audio files, playlists, podc
1414

1515
* **Gitter Community** we got ourselves a gitter community; chat us up at https://gitter.im/phoniebox
1616

17-
* **Phoniebox [2.1](https://github.com/MiczFlor/RPi-Jukebox-RFID/milestone/3?closed=1) released (2020-10-12)**
17+
* **Phoniebox [2.1.1](https://github.com/MiczFlor/RPi-Jukebox-RFID/milestone/5?closed=1) released (2020-10-14)**
1818

19-
The 2.1 release was pushed through the doors with many contributors (some of which in alphabetical order): @andreasbrett @BerniPi @juhrmann @Luegengladiator @MarkusProchaska @MarlonKrug @patrickweigelt @princemaxwell @RalfAlbers @s-martin @themorlan @veloxidSchweiz @xn--nding-jua. [List of all contributors](https://github.com/MiczFlor/RPi-Jukebox-RFID/graphs/contributors)
19+
The [2.1](https://github.com/MiczFlor/RPi-Jukebox-RFID/milestone/3?closed=1) release was pushed through the doors with many contributors (some of which in alphabetical order): @andreasbrett @BerniPi @juhrmann @Luegengladiator @MarkusProchaska @MarlonKrug @patrickweigelt @princemaxwell @RalfAlbers @s-martin @themorlan @veloxidSchweiz @xn--nding-jua. [List of all contributors](https://github.com/MiczFlor/RPi-Jukebox-RFID/graphs/contributors)
2020

21-
## What's new in version 2.1?
21+
## What's new in version 2.1.1?
2222

2323
* Use [multiple readers](https://github.com/MiczFlor/RPi-Jukebox-RFID/pull/1012#issue-434052529) simultaneously
2424
* Improved [GPIO control](components/gpio_control/README.md) and integrated in **one-line install script**

components/gpio_control/GPIODevices/simple_button.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ def checkGpioStaysInState(holdingTime, gpioChannel, gpioHoldingState):
5858

5959
class SimpleButton:
6060
def __init__(self, pin, action=lambda *args: None, name=None, bouncetime=500, edge=GPIO.FALLING,
61-
hold_time=.1, hold_repeat=False,pull_up_down=GPIO.PUD_UP):
61+
hold_time=.1, hold_repeat=False, pull_up_down=GPIO.PUD_UP):
6262
self.edge = parse_edge_key(edge)
6363
self.hold_time = hold_time
6464
self.hold_repeat = hold_repeat
@@ -120,6 +120,7 @@ def __repr__(self):
120120
self.name, self.pin, self.hold_repeat, self.hold_time
121121
)
122122

123+
123124
if __name__ == "__main__":
124125
print('please enter pin no to test')
125126
pin = int(input())

components/gpio_control/gpio_control.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ def generate_device(config, deviceName):
5151
edge=config.get('edge', fallback='FALLING'),
5252
hold_repeat=config.getboolean('hold_repeat', False),
5353
hold_time=config.getfloat('hold_time', fallback=0.3),
54-
pull_up_down=config.get('pull_up_down', fallback='GPIO.PUD_UP'))
54+
pull_up_down=config.get('pull_up_down', fallback=GPIO.PUD_UP))
5555
elif device_type == 'LED':
5656
return LED(config.getint('Pin'),
5757
name=deviceName,
@@ -63,8 +63,7 @@ def generate_device(config, deviceName):
6363
name=deviceName
6464
)
6565
elif device_type == 'RotaryEncoder':
66-
return RotaryEncoder(
67-
config.getint('pinUp'),
66+
return RotaryEncoder(config.getint('pinUp'),
6867
config.getint('pinDown'),
6968
getFunctionCall(config.get('functionCallUp')),
7069
getFunctionCall(config.get('functionCallDown')),

scripts/Reader.py.Multi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ class Reader:
5555
sys.exit('Could not find the device %s\n. Make sure is connected' % dev.name)
5656

5757
str_devs = ','.join([str(x) for x in devs])
58-
#print("Devs: " + str_devs)
58+
# print("Devs: " + str_devs)
5959
self.devices = map(InputDevice, str_devs)
6060
self.devices = {dev.fd: dev for dev in devs}
6161

scripts/RegisterDevice.py.Multi

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,15 @@ import subprocess
55

66
JUKEBOX_HOME_DIR = os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))
77

8+
89
def runCmd(cmd, wait=True):
910
p = subprocess.Popen(cmd, stdout=subprocess.PIPE, shell=True)
1011
(output, err) = p.communicate()
1112
if wait:
1213
p.wait()
1314
return output
1415

16+
1517
def setupPN532():
1618
answer = input('Please make sure that the PN532 reader is wired up correctly '
1719
'to the GPIO ports before continuing...\n Continue?: [Y/n]')
@@ -53,6 +55,7 @@ from Reader import get_devices, EDevices
5355
list_dev_ids = list()
5456
devices = get_devices()
5557

58+
5659
def addDevice():
5760
i = 0
5861
print("Choose the reader from list")
@@ -98,6 +101,3 @@ runCmd("sudo chown pi:www-data {}/scripts/deviceName.txt".format(JUKEBOX_HOME_DI
98101
runCmd("sudo chmod 644 {}/scripts/deviceName.txt".format(JUKEBOX_HOME_DIR))
99102

100103
print("Register Device(s) Done!")
101-
102-
103-

scripts/daemon_rfid_reader.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
file_path = os.path.dirname(__file__)
2727
if file_path != "":
2828
os.chdir(file_path)
29-
29+
3030
# vars for ensuring delay between same-card-swipes
3131
ssp = open('../settings/Second_Swipe_Pause', 'r')
3232
same_id_delay = ssp.read().strip()
@@ -35,7 +35,7 @@
3535
previous_id = ""
3636
previous_time = time.time()
3737

38-
#create array for control card ids
38+
# create array for control card ids
3939
cards = []
4040

4141
# open file and read the content in a list
@@ -74,7 +74,7 @@
7474
logger.info('Trigger Play Cardid={cardid}'.format(cardid=cardid))
7575
subprocess.call([dir_path + '/rfid_trigger_play.sh --cardid=' + cardid], shell=True)
7676
previous_id = cardid
77-
77+
7878
else:
7979
logger.debug('Ignoring Card id {cardid} due to same-card-delay, delay: {same_id_delay}'.format(
8080
cardid=cardid,

scripts/rfid_trigger_play.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ if [ "$CARDID" ]; then
266266
$PATHDATA/playout_controls.sh -c=recordstop
267267
;;
268268
$RECORDPLAYBACKLATEST)
269-
$PATHDATA/playout_controls.sh -c=recordplaybacklatest
269+
$PATHDATA/playout_controls.sh -c=recordplaylatest
270270
;;
271271
$CMDREADWIFIIP)
272272
$PATHDATA/playout_controls.sh -c=readwifiipoverspeaker
@@ -400,7 +400,7 @@ if [ ! -z "$FOLDER" -a ! -z ${FOLDER+x} -a -d "${AUDIOFOLDERSPATH}/${FOLDER}" ];
400400
if [ "${DEBUG_rfid_trigger_play_sh}" == "TRUE" ]; then echo " Completed: toggle pause/play" >> $PATHDATA/../logs/debug.log; fi
401401
elif [ "$SECONDSWIPE" == "PLAY" -a $PLLENGTH -gt 0 ]
402402
then
403-
# The following involves NOT playing the playlist, so we set:
403+
# The following involves NOT playing the playlist, so we set:
404404
PLAYPLAYLIST=no
405405
sudo $PATHDATA/playout_controls.sh -c=playerplay &>/dev/null
406406
if [ "${DEBUG_rfid_trigger_play_sh}" == "TRUE" ]; then echo " Completed: Resume playback" >> $PATHDATA/../logs/debug.log; fi
@@ -409,7 +409,7 @@ if [ ! -z "$FOLDER" -a ! -z ${FOLDER+x} -a -d "${AUDIOFOLDERSPATH}/${FOLDER}" ];
409409
# The following involves NOT playing the playlist, so we set:
410410
PLAYPLAYLIST=no
411411
# following needs testing (see https://github.com/MiczFlor/RPi-Jukebox-RFID/issues/914)
412-
# Special case for NOAUDIOPLAY because once the playlist has finished,
412+
# Special case for NOAUDIOPLAY because once the playlist has finished,
413413
# it needs to be noted by the system that the second swipe is like a *first* swipe.
414414
currentSong=`mpc current`
415415
if [[ -z "$currentSong" ]]; then

settings/version-number

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.1
1+
2.1.1

0 commit comments

Comments
 (0)