Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions cloudinit/config/schemas/schema-cloud-config-v1.json
Original file line number Diff line number Diff line change
Expand Up @@ -2680,12 +2680,12 @@
"properties": {
"console": {
"type": "boolean",
"description": "Enable serial console. Default: ``false``.",
"description": "Enable login shell to be accessible over serial. Default: ``false``.",
"default": false
},
"hardware": {
"type": "boolean",
"description": "Enable UART hardware. Default: ``false``.",
"description": "Enable serial port hardware. Default: ``false``.",
"default": false
}
}
Expand Down
9 changes: 6 additions & 3 deletions doc/module-docs/cc_raspberry_pi/data.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,16 @@ cc_raspberry_pi:
This example will enable the SPI and I2C interfaces on Raspberry Pi.
file: cc_raspberry_pi/example1.yaml
- comment: >
This example will enable the serial interface on Raspberry Pi.
This example will enable the serial console (login shell) on Raspberry Pi.
On models prior to Pi 5, enabling the console also enables the UART hardware.
file: cc_raspberry_pi/example2.yaml
- comment: >
This example will enable the serial interface on Raspberry Pi 5 and disable the UART hardware while enabling the console.
This example will enable the serial console on Raspberry Pi 5
while disabling the UART hardware (only Pi 5 allows this combination).
Comment on lines +18 to +19
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps it's worth mentioning that (IIRC) this is because Pi 5 runs the serial console on a separate UART? (the one between the microHDMI ports)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hrm the example3 provided has the hardware: false and console: true yet the runtime code automatically resets enable_hw = True. Am I misreading the docs or the runtime behavior?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@blackboxsw You're right but it should only automatically enable hw if the platform is not a Pi 5 as the comment and the docs state:

if not is_pifive() and enable_console:

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops ok I inverted the logic and missed the not. Looks good thank you.

file: cc_raspberry_pi/example3.yaml
- comment: >
This example will enable ssh and the UART hardware without binding it to the console.
This example will enable the UART hardware without binding it
to the serial console, allowing applications to use the port directly.
file: cc_raspberry_pi/example4.yaml
- comment: >
This example will enable the Raspberry Pi Connect service.
Expand Down