X ERROR - unsupported types for __and__: 'function', 'int'
-
I keep receiving "X ERROR - unsupported types for _ and _: 'function', 'int' " on my M5Fire for the following code. Sometimes it happens right away, other times it works flawlessly for a little while and then I get the error. Can anyone help with this?

from m5stack import *
from m5ui import *
from uiflow import *
import unitsetScreenColor(0x222222)
relay0 = unit.get(unit.RELAY, unit.PORTB)
rfid2 = unit.get(unit.RFID, unit.PORTA)label1 = M5TextBox(253, 42, "ID:", lcd.FONT_DejaVu24,0xFFFFFF, rotate=90)
label2 = M5TextBox(297, 42, "-", lcd.FONT_DejaVu24,0xFFFFFF, rotate=90)
title = M5Title(title="Workshop", x=7 , fgcolor=0x000000, bgcolor=0xfefefe)
label4 = M5TextBox(253, 83, "-", lcd.FONT_DejaVu24,0xFFFFFF, rotate=90)while True:
relay0.off()
label4.setText(str(rfid2.readUid()))
label2.setColor(0xcccccc)
label2.setText('Place ID Card')
while rfid2.isCardOn():
label4.setText(str(rfid2.readUid()))
if (rfid2.readUid()) == '8848f1f1c':
label2.setColor(0x33ff33)
label2.setText('Proceed')
relay0.on()
else:
label2.setColor(0xff0000)
label2.setText('Access Denied!')
break
wait_ms(2)
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login