Skip to content

Commit

Permalink
fix: set language for a few code-blocks
Browse files Browse the repository at this point in the history
Fix and tag the code-blocks to cut down on parsing and attribute errors.
Also, it adds syntax highlighting and some rudimentary syntax checking
for these examples.

Signed-off-by: Randolph Sapp <[email protected]>
  • Loading branch information
StaticRocket committed Dec 15, 2024
1 parent 6095c1e commit 81635dc
Show file tree
Hide file tree
Showing 7 changed files with 104 additions and 104 deletions.
2 changes: 1 addition & 1 deletion source/buildroot/Overview.rst
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ to github repository.
Repository structure
====================

.. code-block::
.. code-block:: text
buildroot-external-TI
├── external.desc
Expand Down
24 changes: 12 additions & 12 deletions source/debian/Building_Debian_Image.rst
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,15 @@ The scripts are hosted at https://github.com/TexasInstruments/ti-bdebstrap

To clone the repository, run:

.. code-block::
.. code-block:: console
git clone https://github.com/TexasInstruments/ti-bdebstrap.git
Repository Structure
--------------------

.. code-block::
.. code-block:: text
ti-bdebstrap
├── build.sh
Expand Down Expand Up @@ -108,13 +108,13 @@ Install Pre-requisite Packages

First, ensure that your repositories are up-to-date:

.. code-block::
.. code-block:: console
sudo apt update
Then, install packages as follows:

.. code-block::
.. code-block:: console
sudo apt install -y \
pigz expect pv \
Expand All @@ -128,13 +128,13 @@ Then, install packages as follows:
Ensure that all packages were correctly installed using:

.. code-block::
.. code-block:: console
sudo apt install --fix-broken
Finally, install ``toml-cli`` and ``yamllint``:

.. code-block::
.. code-block:: console
pip3 install toml-cli
pip3 install yamllint
Expand Down Expand Up @@ -182,7 +182,7 @@ Building the Image

To build an image, you need to run the :file:`build.sh` script:

.. code-block::
.. code-block:: console
sudo ./build.sh <build-name>
Expand All @@ -192,7 +192,7 @@ After the build, the RootFS, Boot partition and bsp_sources are stored in :file:

Example: to build for ``trixie-am62pxx-evm``, run:

.. code-block::
.. code-block:: console
sudo ./build.sh trixie-am62pxx-evm
Expand All @@ -205,13 +205,13 @@ This step can be skipped if you do not want to share the generated Image with an

To generate an SD Card Image with the generated RootFS and Boot partition files, run:

.. code-block::
.. code-block:: console
./create-wic.sh <build-name>
Example: to build for ``trixie-am62pxx-evm``, run:

.. code-block::
.. code-block:: console
./create-wic.sh trixie-am62pxx-evm
Expand All @@ -222,13 +222,13 @@ Flash Image to SD Card using Script

To flash the SD card without generating a wic image, use the :file:`create-sdcard.sh` script. Run it using the below command and follow with the prompts.

.. code-block::
.. code-block:: console
sudo ./create-sdcard.sh <build-name>
For example, if the image is ``trixie-am62pxx-evm``, type:

.. code-block::
.. code-block:: console
sudo ./create-sdcard.sh trixie-am62pxx-evm
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,16 +36,16 @@ The PRU PWM Linux kernel driver depends on the PRU-ICSS kernel driver. So
the following kernel Kconfig options should be enabled to use the PRU PWM
module.

.. code::
.. code-block:: menuconfig
Device Drivers --->
SOC (System On Chip) specific Drivers --->
[*] TI SOC drivers support --->
<M> TI PRU-ICSS Subsystem Platform drivers
Device Drivers --->
SOC (System On Chip) specific Drivers --->
[*] TI SOC drivers support --->
<M> TI PRU-ICSS Subsystem Platform drivers
Device Drivers --->
Pulse-Width Modulation (PWM) Support --->
PRU-ICSS PWM support
Device Drivers --->
Pulse-Width Modulation (PWM) Support --->
PRU-ICSS PWM support
.. rubric:: PRU PWM Sysfs Usage
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,16 +42,16 @@ in PRU R30 and R31.

For details please refer to the kernel device tree binding doc:

.. code::
.. code-block:: text
Documentation/devicetree/bindings/serial/pru-suart.txt
Documentation/devicetree/bindings/serial/pru-suart.txt
The Processor SDK Linux kernel also provides an device tree example for
Beaglebone Black:

.. code::
.. code-block:: text
arch/arm/boot/dts/am335x-boneblack-prusuart.dts
arch/arm/boot/dts/am335x-boneblack-prusuart.dts
This example defines the 3 UARTs on PRU0 without hardware flow control and 3
UARTs on PRU1 with hardware flow control. All the UART pins are available on
Expand All @@ -64,16 +64,16 @@ The PRU Soft UART Linux kernel driver depends on the PRU-ICSS kernel driver. So
the following kernel Kconfig options should be enabled to use the PRU Soft UART
module.

.. code::
.. code-block:: menuconfig
Device Drivers --->
SOC (System On Chip) specific Drivers --->
[*] TI SOC drivers support --->
<M> TI PRU-ICSS Subsystem Platform drivers
Device Drivers --->
SOC (System On Chip) specific Drivers --->
[*] TI SOC drivers support --->
<M> TI PRU-ICSS Subsystem Platform drivers
Device Drivers --->
Character devices --->
Serial drivers --->
<M> TI PRU Software UART suppor
Device Drivers --->
Character devices --->
Serial drivers --->
<M> TI PRU Software UART suppor
Original file line number Diff line number Diff line change
Expand Up @@ -30,45 +30,45 @@ The PRUSS UART Linux kernel driver depends on the PRU-ICSS kernel drivers. So
the following kernel Kconfig options should be enabled to use the PRUSS UART
module.

.. code::
.. code-block:: menuconfig
Device Drivers --->
SOC (System On Chip) specific Drivers --->
[*] TI SOC drivers support --->
<M> TI PRU-ICSS Subsystem Platform drivers
Device Drivers --->
SOC (System On Chip) specific Drivers --->
[*] TI SOC drivers support --->
<M> TI PRU-ICSS Subsystem Platform drivers
Device Drivers --->
IRQ chip support --->
<M> TI PRU-ICSS Interrupt Controller
Device Drivers --->
IRQ chip support --->
<M> TI PRU-ICSS Interrupt Controller
Device Drivers --->
Character devices --->
Serial drivers --->
<M> TI PRU-ICSS UART support
Device Drivers --->
Character devices --->
Serial drivers --->
<M> TI PRU-ICSS UART support
.. rubric:: Example DT configuration

From am335x-evmsk.dts

.. code::
.. code-block:: dts
&pruss_uart {
prus = <&pru0>;
ti,pru-interrupt-map = <0 6 2 2>;
pinctrl-names = "default";
pinctrl-0 = <&prussuart_pins>;
status = "okay";
};
&pruss_uart {
prus = <&pru0>;
ti,pru-interrupt-map = <0 6 2 2>;
pinctrl-names = "default";
pinctrl-0 = <&prussuart_pins>;
status = "okay";
};
.. rubric:: Driver Usage

Once the driver is probed, kernel log shows the following message.

.. code::
.. code-block:: dmesg
[ 28.617700] 4a328000.serial: ttyS1 at MMIO 0x4a328000 (irq = 77, base_baud = 12000000) is a 16550A
[ 28.617700] 4a328000.serial: ttyS1 at MMIO 0x4a328000 (irq = 77, base_baud = 12000000) is a 16550A
Therefore the device node /dev/ttyS1 is associated to the PRUSS UART, user
space application can read/write this serial port. For detalls please refer
Expand Down
Loading

0 comments on commit 81635dc

Please sign in to comment.