Skip to content

The monitor command does not recognize port specified in the sketch.yaml file. #2280

Closed
@woolseyj

Description

@woolseyj

Describe the problem

I can use the arduino-cli board attach command to specify the default FQBN and serial port attached to a sketch. However, if I then try to run the arduino-cli monitor command (without any other options) I get the following error.

required flag(s) "port" not set

I expected the monitor command would pick up the default port set in the sketch.yaml file, but that does not appear to be the case.

To reproduce

Create a sketch that includes serial output.

Attach a board to the sketch.
$ arduino-cli board attach --fqbn arduino:renesas_uno:unor4wifi --port /dev/cu.usbmodemDC5475C3BE142

Compile and upload the sketch to the board.
$ arduino-cli compile --upload

Display the board's serial output.
$ arduino-cli monitor

Expected behavior

I expected the
$ arduino-cli monitor
command to display the board's serial output. Instead, I received the required flag(s) "port" not set error. Adding the port specification to the command
$ arduino-cli monitor --port /dev/cu.usbmodemDC5475C3BE142
shows the expected serial output.

Arduino CLI version

arduino-cli Version: nightly-20230827 Commit: f5a9b7c Date: 2023-08-27T01:27:51Z

Operating system

macOS

Operating system version

13.5.1

Additional context

No response

Issue checklist

  • I searched for previous reports in the issue tracker
    I verified the problem still occurs when using the nightly build
    My report contains all necessary details

Activity

added this to the Arduino CLI 0.35.0 milestone on Sep 1, 2023
woolseyj

woolseyj commented on Oct 25, 2023

@woolseyj
Author

Confirmed that the update works in the latest nightly build (Version: nightly-20231025 Commit: b7ce9c8 Date: 2023-10-25T01:27:05Z).

Thank you.

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

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Relationships

None yet

    Participants

    @cmaglie@woolseyj@per1234@MatteoPologruto

    Issue actions

      The monitor command does not recognize port specified in the sketch.yaml file. · Issue #2280 · arduino/arduino-cli