Box stoppt Wiedergabe wenn Karte weg.

Danke für den Tip! Damit funktioniert das “Pause when Card Away” Feature wieder. Ich habe die Änderungen, die Du im Sketch gemacht hast, damit das Feature standardmäßig aktiviert ist, bei mir auch nachgezogen. Danke dafür!

Ich habe einen kleinen Bug entdeckt. Nach einem Kartenlesefehler nimmt der Tonuino keine weiteren Kartenbefehle mehr an.

Die Konsole gibt folgendes aus:

ReadCardSerial finishedCard UID: 56 27 50 42
PICC type: MIFARE 1KB
Authenticating Classic using key A…
Reading data from block 4 …
MIFARE_Read() failed: The CRC_A does not match.

Ich nutze die aktuelle McGreg Dev Version mit dem “Stop when Card Away” Feature. @Thorsten hatte einen ähnlichen(?) Bug bereits Ende Januar in seiner offiziellen Dev Version gefixt (siehe auf Github commit vom 31. Januar 2019 "Fix falls die Karte nicht gelesen wird). Ob der Bug mit dem Stop When Card Away Feature zusammenhängt oder allgemeiner Natur ist kann ich nur mutmaßen. Ich habe leider keine ausreichenden Programmierkenntnisse, um das Problem in der Software nachzuvollziehen. Falls sich jemand daran versuchen möchte, gerne. Es hat aber wohl nicht die höchste Prio, da sich (zumindest bei mir) Kartenlesefehler auch mutwillig nur mit viel Geduld herbeiführen lassen.

Dann muss es auch in dieser Version gefixt werden, falls dies überhaupt möglich ist (bin da nicht so tief drin, nutze das nicht). Diese Lesefehler können immer mal vorkommen, wenn man mit der Karten zu schnell/langsam oder in ungünstigem Winkel zum Leser kommt etc. Ich halte das bei „Funk“ für normal.
In Master/DEV/meiner Version ist das in der Regel kein Problem weil dann einfach nochmal gelesen wird. Der lockup muss also was mit @mcgreg‘s Mechanik zur Realisierung der „stop wenn Karte weg“ Funktion zu tun haben.

Hallo @Anton-V,

ich habe schon eine Vermutung woran es liegt. Bin aber z.Zt. nicht in der Lage den Fehler nachzuvollziehen & meinen Fix zu testen.

Ich habe mal “auf Verdacht” diese Änderungen soeben in meine DEV Version übernommen. Vielleicht magst du es testen und mir Feedback geben.

2 „Gefällt mir“

Da teste ich natürlich gerne!! Und kann auch schon Erfolg vermelden!!

Ich konnte zwei unterschiedliche Fehler erzeugen: MIFARE_Read() failed und PCD_Authenticate() failed. Beide führen nun nicht mehr zu Problemen. Hier ein Auszug aus der Konsole, bei dem beide Fehler unmittelbar nacheinander aufgetreten sind und die Karte anschließend trotzdem erkannt wurde:

Karte ist weg!
=== setstandbyTimer()
334979
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
MIFARE_Read() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()

Vielen Dank an @mcgreg für das schnelle zur Verfügung stellen eines Fixes!!!

Der vollständigkeithalber hier noch die gesamte Konsole meines Tests:

TonUINO Version 2.1 + mods by McGreg
created by Thorsten Voß and licensed under GNU/GPL.
Information and contribution at https://tonuino.de.

=== loadSettingsFromFlash()
Version: 2
Maximal Volume: 25
Minimal Volume: 1
Initial Volume: 15
EQ: 1
Locked: 0
Sleep Timer: 1
Inverted Volume Buttons: 1
Admin Menu locked: 0
Admin Menu Pin: 1111
=== setstandbyTimer()
60039
Firmware Version: 0x91 = v1.0
=== playShortCut()
3
== playFolder()
=== disablestandby()
8 Dateien in Ordner 1
Einzel Modus -> eine Datei aus dem Odrdner abspielen
=== disablestandby()
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Neue Karte== playFolder()
=== disablestandby()
9 Dateien in Ordner 4
Einzel Modus -> eine Datei aus dem Odrdner abspielen
=== volumeUp()
16
=== volumeUp()
17
=== volumeUp()
18
=== volumeDown()
17
=== volumeDown()
16
=== volumeDown()
15
=== volumeDown()
14
=== volumeDown()
13
=== volumeDown()
12
=== volumeDown()
11
=== volumeDown()
10
=== volumeDown()
9
=== volumeDown()
8
=== volumeDown()
7
=== volumeDown()
6
=== volumeDown()
5
=== volumeDown()
4
=== volumeDown()
3
=== volumeDown()
2
=== volumeDown()
1
=== volumeDown()
1
Karte ist weg!
=== setstandbyTimer()
92547
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
99521
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
104776
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
106190
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
114679
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
124581
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
128321
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
130241
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
131150
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
132363
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
133171
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
136001
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
137618
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
139436
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
142873
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
153179
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
165913
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
168641
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
173390
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
174098
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
174501
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
177533
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
183698
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
187739
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
195621
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
196733
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
198755
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
200675
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
201887
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
211587
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
218056
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
227959
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
230787
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
380
=== nextTrack()
Einzel Modus aktiv -> Strom sparen
=== setstandbyTimer()
246449
380
Karte ist weg!
=== setstandbyTimer()
249691
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
258585
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
265859
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
266568
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
276673
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
280513
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
286576
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
291225
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
293245
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
297591
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
298499
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
302542
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
304765
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
305876
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
306483
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
307595
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
308302
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
309010
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
310121
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
311131
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
MIFARE_Read() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
313355
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
314971
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
316588
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
MIFARE_Read() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
MIFARE_Read() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
317498
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
318711
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
MIFARE_Read() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
MIFARE_Read() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
321035
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
323056
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
MIFARE_Read() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
MIFARE_Read() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
324067
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
324571
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
325481
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
327805
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
328411
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
329321
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
330130
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
332050
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
332756
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
MIFARE_Read() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
334979
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
MIFARE_Read() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
336899
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
PCD_Authenticate() failed: Error in communication.
Karte konnte nicht gelesen werdenReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
339528
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
339931
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
349633
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
350239
ReadCardSerial finishedCard UID: 36 E8 4C 42
PICC type: MIFARE 1KB
Authenticating Classic using key A...
Reading data from block 4 ...
Data on Card :
 13 37 B3 47 02 04 04 01 B6 00 00 00 00 00 00 00

4
4
Gleiche Karte=== disablestandby()
Karte ist weg!
=== setstandbyTimer()
353978
=== power off!

Freut mich, dass es geklappt hat und meine Version einen Tester hat

:wink:

1 „Gefällt mir“

Hallo Thorsten,
wo finde ich diesen Pull-Request? Hab in der Requestliste geschaut, aber nichts finden können (oder bin zu blöd dafür :wink: -> Pull Requests TonUINO).
Oder ist die Funktion schon im DEV? Wenn ja, wie aktiviere ich sie? Meine Zwei-Tasten-Box ist kurz vor der Fertigstellung und ich würde wenn möglich diese Variante nutzen wollen. Für die Adminfunktionen habe ich ein kleines Papa-Admin-Panel mit drei Tasten gebastelt. Stelle ich in den nächsten Tagen kurz vor.

Schon mal vielen Dank im Voraus für die Hilfe.

Ist aber nicht mergeable im Moment. Wenn du das nutzen willst musst du zur Zeit @mcgreg‘s Fork einsetzen.

1 „Gefällt mir“

Hallo @Gulpman, nimm lieber meine aktuelle DEV version, da sind noch diverse bugfixes drin und Unterstützung für die modifier karten.

Hallo zusammen, vielen Dank für die vielen Hinweise!
@mcgreg fusst Deine Version auf der aktuellen V2.1 (dev) oder V2.0 (master)?

Viele Grüße
Sascha

Sie basiert auf DEV.

Ich habe Thorstens master ebenfalls um diese Funktionalität erweitert. Den Code findet ihr hier: https://github.com/uluzox/TonUINO

Gerne erstelle ich dafür einen Pullrequest. Falls @ mcgreg Version nicht bereits übernommen wird.

Viele Grüße

Thorsten

Hallo zusammen,

ich bin ganz neu hier und dank der vielen tollen Tips und Anleitungen nun auch stolzer Besitzer eines TonUINOs.
Ich habe mir auch die Software von @mcgreg wegen dem tollen Karte-weg-Wiedergabe-stoppt-Feature (Danke dafür!) geschnappt und aufgespielt, habe nun allerdings ein kleines Problem festgestellt:

Karte liegt auf und alles fängt schön an zu spielen.
Ich nehme die Karte runter. Es hört auf zu spielen.
Ich lege die Karte wieder drauf. Es geht weiter, dort wo es aufgehört hat.
Soweit perfekt.
Nun ist es allerdings so, dass ich den StandbyTimer eingestellt habe und die Kiste nach 15 Minuten ausgehen soll. Das funktioniert aber leider nicht, wenn die Karte noch aufliegt und der Ordner auf der SD (es liegt nur 1 Lied darin) bis zum Ende abgespielt worden ist.

Der Monitor sagt folgendes:

1 Dateien in Ordner 1
Album Modus → kompletten Ordner wiedergeben
Karte ist weg!
=== setstandbyTimer()
1937943
ReadCardSerial finishedCard UID: 87 7D 72 1C
PICC type: MIFARE 1KB
Authenticating Classic using key A…
Reading data from block 4 …
Data on Card :
13 37 B3 47 02 01 02 17 54 00 00 00 00 00 00 00

1
1
Gleiche Karte=== disablestandby()

Es fehlt ja am Ende, dass der Standby-Timer wieder gesetzt wird. Habt ihr das bei Euch auch? Ist das ein Bug?

Danke und Gruß,
Michael

Hallo @xploderpro,

freut mich, dass du meine FW nutzt. Leider habe ich die Funktion Standby nie benutzt, deswegen kann es schon sein, dass es ein Bug ist.
Wie sollte es denn eigentliche Funktionieren? Falls die Box einfach ausgehen soll, wenn der Timer abgelaufen ist (egal ob gespielt wird oder nicht) würde ich einfach in der Zeile 1117 den Aufruf disablestandbyTimer() auskommentieren:

//disablestandbyTimer(); 

/mcgreg

Danke für die schnelle Antwort @mcgreg . Das auskommentieren würde mir jedoch eine wichtige Funktion nehmen. Die Grundfunktionen ist, dass der Standby Timer bei Inaktivität getriggert wird. Also z.B. dann, wenn „Lied zu Ende gespielt“, „Pause taste gedrückt“ oder eben in deiner FW „Karte weg“ startet der Timer und läuft eine Zeit x. Nach erreichen der Zeit gibt es ein Signal auf den Pin 7. Wenn in der Standby Zeit jedoch ein Lied gespielt wird, wird der Timer unterbrochen und bei der nächsten Inaktivität neu gestartet und eben wieder für die Zeit x. Kommentiere ich die Zeile aus, geht die Box meinem Verständnis nach einfach immer nach einer bestimmten Zeit aus, egal ob wieder gespielt wird oder nicht.

Verstehe. Ich schau es mir mal an, evtl. schaff ich es auch vor meinem Urlaub.

Ok, um möglichst wenig zu ändern (da ich es sowieso nicht testen kann, weil standby bei meiner Box nicht funktioniert), würde ich die besagte Stelle (Zeile 1117) in folgendes ändern:

if (isPlaying()) {
    disablestandbyTimer(); 
}
else {
    setstandbyTimer();
}

Falls du es also testest, wäre es schön wenn du das Ergebnis hier mitteilst. Dann kann ich den Code auch in meinem GitHub ändern.

Grüße,
mcgreg

Vielen Dank. Ich habe es versucht, aber erhalte beim Kompilieren folgende Meldung:

exit status 1
'isplaying' was not declared in this scope

Sorry, es muss isPlaying heißen, hab den oberen Post v we verbessert.