0
为什么一个简单的time.sleep(1)
声明引起:类型错误:“浮动对象不可调用的”
Type error : 'float' object not callable?
代码如下:
try:
while True
time.sleep(10)
current_state = GPIO.input(pir_sensor)
if current_state ==1:
print "PIR Activated"
except KeyboardInterrupt:
GPIO.cleanup()
请在这里添加完整的引用! – Arman
回溯(最近的通话最后): –
不是这样,完整的错误追溯到你的问题并编辑它。 – Arman