UART handler error
-
Hello,
When I call uart irq like this:
uart.irq(trigger = UART.RX_ANY, handler = hand)
and hand function looks like this:
def hand():
returnI've got this error:
Uncaught exception in callback handler
TypeError:And another thing is that when I write: bytes = UART.read() I've got this error:
argument num/types mismatchWhat can cause those problems?
-
Where do you found uart.irq docs?
and what do you pass as argument of UART.write() ?
It can not be empty - and it must by bytes() -
@livius Sorry, it was UART.read() and it is solved
And I found UART.irq doc here: http://docs.micropython.org/en/latest/wipy/library/machine.UART.html#machine.UART.irq -
@michalt38
Do you have Wipy1 or Wipy2.0?And I found UART.irq doc here: http://docs.micropython.org/en/latest/wipy/library/machine.UART.html#machine.UART.irq
This doc is for Wipy1.
For Wipy2.0 doc are here
https://docs.pycom.io/pycom_esp32/index.html
uart is here
https://docs.pycom.io/pycom_esp32/library/machine.UART.html -
@livius I've got WiPy 1
-
@michalt38 said in UART handler error:
I've got WiPy 1
I can not help more because i have only Wipy2.0.
Maybe someone else... -
This post is deleted!
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