Skip to content

[BUG] RN2483 hangs on read #17273

@bskdany

Description

@bskdany

Description / Steps to reproduce the issue

The RN2483 with the rn2xx3 driver hangs on read

The following is the problematic part, situated in rn2xx3_read()

ret = file_read(&priv->uart, &hex_byte, 2);
      if (ret < 2)
        {
          goto early_ret;
        }

The device seems to always return 1 byte of data instead of 2, thus hanging the system

Switching to a double single byte read fixed the issue

ret = file_read(&priv->uart, &hex_byte, 1);
      if (ret < 1)
        {
          goto early_ret;
        }
ret = file_read(&priv->uart, &hex_byte[1], 1);
      if (ret < 1)
        {
          goto early_ret;
        }

I do not find this to be an elegant solution, is there a different read function that could wait until the buffer is full?

On which OS does this issue occur?

[OS: Mac]

What is the version of your OS?

MacOS 15.6.1

NuttX Version

releases/12.12

Issue Architecture

[Arch: arm64]

Issue Area

[Area: Drivers]

Host information

No response

Verification

  • I have verified before submitting the report.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Arch: arm64Issues related to ARM64 (64-bit) architectureArea: DriversDrivers issuesOS: MacIssues related to MacOS (building system, etc)Type: BugSomething isn't working

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions