Skip to content

drivers: nhs_ser: do not force CRTSCTS (breaks CDC-ACM and 3-wire ser…#3511

Open
jpastoreli wants to merge 1 commit into
networkupstools:masterfrom
jpastoreli:patch-1
Open

drivers: nhs_ser: do not force CRTSCTS (breaks CDC-ACM and 3-wire ser…#3511
jpastoreli wants to merge 1 commit into
networkupstools:masterfrom
jpastoreli:patch-1

Conversation

@jpastoreli

Copy link
Copy Markdown

Disables the hardcoded CRTSCTS in nhs_ser openfd(), which blocks
communication on NHS UPSes with no RTS/CTS lines (USB/CDC-ACM and the
official 3-wire serial cable).

Full diagnosis, raw packet captures and device details: Refs #3510

@github-actions

github-actions Bot commented Jun 28, 2026

Copy link
Copy Markdown

A ZIP file with standard source tarball and another tarball with pre-built docs for commit 58af3b7 is temporarily available: NUT-tarballs-PR-3511.zip.

…ial)

Forcing CRTSCTS in openfd() blocks communication on NHS UPSes whose port
     has no hardware flow-control lines: USB/CDC-ACM virtual ports (e.g.
     /dev/ttyACM0) and the official NHS 3-wire RS-232 cable (DB9 pins 2/3/5
     only, no RTS/CTS). The driver opens the port but never assembles a packet.
     Disabling CRTSCTS restores communication.

Signed-off-by: Jonas Pastoreli <100150319+jpastoreli@users.noreply.github.com>
@AppVeyorBot

Copy link
Copy Markdown

Build nut 2.8.5.4900-master completed (commit 24cb2b67bf by @jpastoreli)

@AppVeyorBot

Copy link
Copy Markdown

Build nut 2.8.5.4901-master completed (commit d41946991b by @jpastoreli)

@jimklimov jimklimov added bug serial port Connection stability issues Issues about driver<->device and/or networked connections (upsd<->upsmon...) going AWOL over time impacts-release-2.8.5 Issues reported against NUT release 2.8.5 (maybe vanilla or with minor packaging tweaks) labels Jun 29, 2026
@jimklimov jimklimov added this to the 2.8.6 milestone Jun 29, 2026
@jimklimov

Copy link
Copy Markdown
Member

Generally looks reasonable; deferring to @Challado as original author per #2692 to make sure it works with the model it was originally posted for too.

The PR would benefit from also a note in NEWS.adoc about the driver update, and a DRIVER_VERSION number bump.

@Challado

Copy link
Copy Markdown

Generally looks reasonable; deferring to @Challado as original author per #2692 to make sure it works with the model it was originally posted for too.

The PR would benefit from also a note in NEWS.adoc about the driver update, and a DRIVER_VERSION number bump.

As expected, testing on 3 units that I know the problem appears fail on communication.

@Challado

Challado commented Jul 2, 2026

Copy link
Copy Markdown

Re-tested with other 2 units, same problem @jimklimov. I'll see that I can make something about these code and commit a more elegant solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Connection stability issues Issues about driver<->device and/or networked connections (upsd<->upsmon...) going AWOL over time impacts-release-2.8.5 Issues reported against NUT release 2.8.5 (maybe vanilla or with minor packaging tweaks) serial port

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants