Skip to content

Conversation

@kartben
Copy link
Contributor

@kartben kartben commented Oct 17, 2024

https://builds.zephyrproject.io/zephyr/pr/79994/docs/boards/seeed/wio_terminal/doc/index.html
https://builds.zephyrproject.io/zephyr/pr/79994/docs/contribute/documentation/guidelines.html#boards

A new zephyr:board:: Sphinx directive allows to flag a documentation page as being the documentation for a specific board, allowing to auto-populate some of the contents, ex. by adding a board overview à la Wikipedia, and later things like supported HW features, a ready-to-copy-paste example of how to build Hello World, etc.

image

A corresponding :zephyr:board: role allows to link to a board doc page.

@kartben kartben force-pushed the board_directive branch 2 times, most recently from c641d80 to b5c0361 Compare October 17, 2024 13:27
@kartben kartben changed the title doc: boards: extensions: store board_catalog in Sphinx domain doc: boards: extensions: introduce zephyr:board role and directive Oct 17, 2024
@kartben kartben force-pushed the board_directive branch 8 times, most recently from b8b4780 to db19547 Compare October 17, 2024 14:36
@kartben kartben marked this pull request as ready for review October 17, 2024 15:06
@kartben kartben requested a review from carlescufi as a code owner October 17, 2024 15:06
@kartben kartben requested review from erwango, fabiobaltieri and pdgendt and removed request for carlescufi October 17, 2024 15:06
@kartben kartben force-pushed the board_directive branch 3 times, most recently from 622c478 to c446be7 Compare October 17, 2024 15:24
@kartben kartben requested a review from sylvioalves October 17, 2024 15:26
Copy link
Member

Choose a reason for hiding this comment

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

cool stuff, should the small image be linked to the full size image? we don't really do high res but looking at the page it's tempting to click (not even sure this is the right place to be honest, I'm talking about the board overview card in the board page https://builds.zephyrproject.io/zephyr/pr/79994/docs/boards/seeed/wio_terminal/doc/index.html)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ya it's the right place :) and yes, great suggestion

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done!
Also fixed the styling of the <aside> on narrow screens (which I think might actually be a bug in RTD theme, btw, so I'll try to submit a fix upstream as well)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

which I think might actually be a bug in RTD theme, btw, so I'll try to submit a fix upstream as well

readthedocs/sphinx_rtd_theme#1622

@kartben
Copy link
Contributor Author

kartben commented Oct 18, 2024

Just pushed a fix for a nasty bug that was causing Sphinx logs to be silenced - whoopsie.

fabiobaltieri
fabiobaltieri previously approved these changes Oct 18, 2024
Copy link
Member

@fabiobaltieri fabiobaltieri left a comment

Choose a reason for hiding this comment

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

Great stuff can't wait to see how this renders in the pdf.

sylvioalves
sylvioalves previously approved these changes Oct 18, 2024
Fixes typos in Sphinx roles

Signed-off-by: Benjamin Cabé <[email protected]>
Load the board catalog only once at build-inited time so that
it's cached and enabled things like boards, vendors, and socs
to eventually become first class Sphinx objects.

Signed-off-by: Benjamin Cabé <[email protected]>
@kartben
Copy link
Contributor Author

kartben commented Oct 18, 2024

Great stuff can't wait to see how this renders in the pdf.

We don't include boards in the PDF 😝

@kartben
Copy link
Contributor Author

kartben commented Oct 18, 2024

Had to push one more commit to clean up 3.7 release notes re: Sphinx lint.
Just like code samples, boards are now referenced using a dedicated role and not the generic :ref: anymore so this requires updates tree-wide, and I deliberately hadn't made a pass on past release notes regarding Sphinx linting as I didn't want to "touch" them unnecessarily (but since the lint errors were actual bugs causing bad rendering, I probably should have...)

A new zephyr:board:: Sphinx directive allows  to flag a documentation
page as being the documentation for a specific board, allowing to
auto-populate some of the contents, ex. by adding a board overview a la
Wikipedia, and later things like supported HW features, etc.

A corresponding :zephyr:board: role allows to link to a board doc page.

Signed-off-by: Benjamin Cabé <[email protected]>
This updates the documentation of all the Seeed Studio boards to use
the new `zephyr:board::` directive.

Signed-off-by: Benjamin Cabé <[email protected]>
Copy link
Member

@gmarull gmarull left a comment

Choose a reason for hiding this comment

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

LGTM. It would be nice to start a mass cleanup of board pages. They contain tons of redundant information that just increases doc build time.

@kartben
Copy link
Contributor Author

kartben commented Oct 21, 2024

LGTM. It would be nice to start a mass cleanup of board pages. They contain tons of redundant information that just increases doc build time.

@gmarull this will be incremental and take a lot of time but... yes, definitely -- e.g. #80048

* Added support for Ambiq Apollo3 series.
* Added support for multiple instances of the SPI NOR driver (spi_nor.c).
* Added preliminary support for non-erase devices with introduction of
device capabilities to c:struct:`flash_parameters` and the utility function
Copy link
Member

Choose a reason for hiding this comment

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

Kind of weird to be modifying release notes of an already finalized release.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

See #79994 (comment) for some context

@aescolar aescolar merged commit b58b896 into zephyrproject-rtos:main Oct 22, 2024
16 checks passed
@kartben kartben deleted the board_directive branch October 22, 2024 12:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants