ich bastel gerade an einer grafischen Ein-/Ausgabe für ein Konsolenprogramm via Tkinter. Die grafische Ausgabe habe ich soweit ohne größere Probleme fertig bekommen, die Übergabe der Eingaben aus dem Programm heraus bekomme ich aber nicht auf die Reihe.
Im späteren Quellcode heißt es
Code: Alles auswählen
#Beenden
if (input(12) == True):
WORK = False
Code: Alles auswählen
def pushbutton(buttonid):
if buttonid == 25:
input(25)==True
if buttonid == 12:
input(12)==True
if buttonid == 17:
input(17)==True
if buttonid == 27:
input(27)==True
print ("Taste " + str(buttonid) + " wurde betaetigt.")
steuerfenster.configure(text=("Taste " + str(buttonid) + " wurde betaetigt."))
# pass;
# Schaltknöpfe
button1 = Button(text="Press", command=lambda: pushbutton(25))
button1.pack()
button1.place(x=190, y=70)
button2 = Button(text="Press", command=lambda: pushbutton(12))
button2.pack()
button2.place(x=115, y=160)
Vielen Dank für Eure Unterstützung schon einmal.