Skip to content

long-lived UART buffer still not working right #1126

Closed
@dhalbert

Description

@dhalbert

Following on #1056 and #1080, it appears that PR #1080 still has issues, depending on whether or not the code is imported from a file:

Tested on commit 2e80f37 on an M0 Adalogger:

REPL:

Adafruit CircuitPython 3.0.0-4-g2e80f37 on 2018-08-08; Adafruit Feather M0 Adalogger with samd21g18
>>> import board,busio
>>> uart = busio.UART(board.TX, board.RX)
>>> uart.write(b'\xbb')
1

But in a file:
file test_uart.py:

import board, busio
uart = busio.UART(board.TX, board.RX)

Now in REPL

Adafruit CircuitPython 3.0.0-4-g2e80f37 on 2018-08-08; Adafruit Feather M0 Adalogger with samd21g18
>>> import test_uart
>>> test_uart.uart.write(b'\xbb')
0

Nothing is written (see the 0 return above). Was originally testing with a Saleae, and confirmed that nothing gets written.

tagging @jepler

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions