diff --git a/boards/capes/cape-interface-spec.rst b/boards/capes/cape-interface-spec.rst index beb41b18707d31cdedc1bca21ea9a0e2f33b36a7..2d168cddba9541bb503bbfd207aa864e8b5be06e 100644 --- a/boards/capes/cape-interface-spec.rst +++ b/boards/capes/cape-interface-spec.rst @@ -20,7 +20,7 @@ Background and overview * See `elinux.org Cape Expansion Headers for BeagleBone page <https://elinux.org/Beagleboard:Cape_Expansion_Headers>`_ * See :ref:`BeagleBone Black System Reference Manual Connectors section <beagleboneblack-connectors>` * See :ref:`BeagleBone AI System Reference Manual Connectors section <beaglebone-ai-connectors>` - * See :ref:`BeagleBone AI-64 System Reference Manual Connectors section <cape-board-support-1>` + * See :ref:`BeagleBone AI-64 System Reference Manual Connectors section <bbai64-cape-board-support-1>` .. note:: Below, when mentioning "Black", this is true for all AM3358-based BeagleBone boards. "AI" is AM5729-based. "AI-64" is TDA4VM-based. @@ -584,7 +584,7 @@ SPI bone bus nodes allow creating compatible overlays for Black, AI and AI-64. Some boards may implement CS using a GPIO. -.. code-block:: +.. code-block:: devicetree :linenos: :caption: Example device tree overlay to enable SPI driver :name: bone_cape_spec_spi_example diff --git a/books/beaglebone-cookbook/02sensors/sensors.rst b/books/beaglebone-cookbook/02sensors/sensors.rst index 521f9bd147ed4e8c34eafda14df666993d9a05f9..627627e47378ecae531743743da617f2dfb9145b 100644 --- a/books/beaglebone-cookbook/02sensors/sensors.rst +++ b/books/beaglebone-cookbook/02sensors/sensors.rst @@ -474,6 +474,7 @@ HC-SR04 to the Bone's 5 V power supply. .. _sensors_hc-sr04_code: .. literalinclude:: ../code/02sensors/hc-sr04-ultraSonic.js + :language: JavaScript :caption: Driving a HC-SR04 ultrasound sensor (hc-sr04-ultraSonic.js) :linenos: @@ -656,6 +657,7 @@ will print the current location every time the GPS outputs it. .. _digital_GPS_code: .. literalinclude:: ../code/02sensors/GPS.js + :language: JavaScript :caption: Talking to a GPS with UART 4 (GPS.js) :linenos: @@ -883,6 +885,7 @@ using the kernel driver. First you need to install the i2c module. .. _js_i2ctmp101_code: .. literalinclude:: ../code/02sensors/i2ctmp101.py + :language: Python :caption: Reading an |I2C| device (i2cTemp.py) :linenos: diff --git a/books/beaglebone-cookbook/03displays/displays.rst b/books/beaglebone-cookbook/03displays/displays.rst index 5fe497ff4e40ec7170276a36ae8848b4a3fc792c..fa160c28589071df7ce0d317dd7ebb7976da03ec 100644 --- a/books/beaglebone-cookbook/03displays/displays.rst +++ b/books/beaglebone-cookbook/03displays/displays.rst @@ -382,6 +382,7 @@ LED matrix display (matrixLEDi2c.py) ===================================== .. literalinclude:: ../code/03displays/matrixLEDi2c.py + :language: Python :caption: LED matrix display (matrixLEDi2c.py) :linenos: diff --git a/books/beaglebone-cookbook/04motors/motors.rst b/books/beaglebone-cookbook/04motors/motors.rst index d28b0465c69566ceac13ec0e62edcacefb51ca27..37da5e48227c89be0da92e30500c117c00e34ff8 100644 --- a/books/beaglebone-cookbook/04motors/motors.rst +++ b/books/beaglebone-cookbook/04motors/motors.rst @@ -264,6 +264,7 @@ motor with a transistor (:ref:`motors_dcMotor_code`). The additional code specif .. _motors_h-bridge_code: .. literalinclude:: ../code/04motors/h-bridgeMotor.js + :language: JavaScript :caption: Code for driving a DC motor with an H-bridge (h-bridgeMotor.js) :linenos: @@ -304,6 +305,7 @@ Use the code in :ref:`motors_stepperMotor_code_py` to drive the motor. .. _motors_stepperMotor_code_py: .. literalinclude:: ../code/04motors/bipolarStepperMotor.py + :language: Python :caption: Driving a bipolar stepper motor (bipolarStepperMotor.py) :linenos: diff --git a/books/beaglebone-cookbook/06iot/iot.rst b/books/beaglebone-cookbook/06iot/iot.rst index 3044fd247492093c8ae3876b454cec2bad58c810..734316c753326c3f7c339f9db689f04e3a2a6adf 100644 --- a/books/beaglebone-cookbook/06iot/iot.rst +++ b/books/beaglebone-cookbook/06iot/iot.rst @@ -207,6 +207,7 @@ function. Now, let’s create a new Python script. We will name it app1.py: .. _flask_app1: .. literalinclude:: ../code/06iot/flask/app1.py + :language: Python :caption: app1.py :linenos: @@ -271,6 +272,7 @@ Let’s use a new Python script named *app2.py*. .. _flask_app2: .. literalinclude:: ../code/06iot/flask/app2.py + :language: Python :caption: A simple Flask-based web server to read a GPIO (app2.py) :linenos: @@ -333,6 +335,7 @@ Create a new Python script and name it *app3.py*. .. _flask_app3: .. literalinclude:: ../code/06iot/flask/app3.py + :language: Python :caption: A simple Flask-based web server to read a GPIO (app3.py) :linenos: @@ -477,6 +480,7 @@ plots the buffer is **analogInContinuous.py**. .. _analog_code: .. literalinclude:: ../code/06iot/analogInContinuous.py + :language: Python :caption: Code to read and plot a continuous analog input(analogInContinuous.py) :linenos: @@ -629,6 +633,7 @@ Then add the code in :ref:`networking_nodemailer_code` to a file named ``emailTe .. _networking_nodemailer_code: .. literalinclude:: ../code/06iot/emailTest.py + :language: Python :caption: Sending email using nodemailer (emailtTest.py) :linenos: @@ -743,6 +748,7 @@ Because your Bone is on the network, it's not hard to access the current weather .. _networking_weather_code: .. literalinclude:: ../code/06iot/weather.py + :language: Python :caption: Code for getting current weather conditions (``weather.py``) :linenos: @@ -865,6 +871,7 @@ The code in :ref:`networking_pushbutton_code` sends a tweet whenever a button is .. _networking_pushbutton_code: .. literalinclude:: ../code/06iot/twitterPushbutton.js + :language: JavaScript :caption: Tweet when a button is pushed (twitterPushbutton.js) :linenos: diff --git a/books/beaglebone-cookbook/07kernel/kernel.rst b/books/beaglebone-cookbook/07kernel/kernel.rst index 25f4a90d9142713863ac5c8d5d0fcf2498d39825..3267873b129367d6e1fa30801e5ad788283f9589 100644 --- a/books/beaglebone-cookbook/07kernel/kernel.rst +++ b/books/beaglebone-cookbook/07kernel/kernel.rst @@ -523,6 +523,7 @@ Solution .. _kernel_hello_patch: .. literalinclude:: ../code/07kernel/hello.patch + :language: text :caption: Simple kernel patch file (hello.patch) :linenos: diff --git a/books/beaglebone-cookbook/11misc/misc.rst b/books/beaglebone-cookbook/11misc/misc.rst index a0681fecbfa14ea96b3341f6a561b4b81c9dcd2a..d6c5dce94d4417f736594209d782ee46d4157113 100644 --- a/books/beaglebone-cookbook/11misc/misc.rst +++ b/books/beaglebone-cookbook/11misc/misc.rst @@ -263,7 +263,7 @@ Restore the line: and restart sshd. -.. code-block:: +.. code-block:: bash root@bone# systemctl restart sshd root@bone# exit @@ -295,7 +295,7 @@ it display on the host. #. First ssh to the Beagle using the `-X` flag. -.. code-block:: +.. code-block:: bash host$ ssh -X debian@10.0.5.10 @@ -351,7 +351,7 @@ Next, create a named pipe and have wireshark read from it. Then, run tcpdump over ssh on your remote machine and redirect the packets to the named pipe: -.. code-block:: +.. code-block:: bash host$ ssh root@192.168.7.2 "tcpdump -s 0 -U -n -w - -i any not port 22" > /tmp/remote diff --git a/books/pru-cookbook/03details/details.rst b/books/pru-cookbook/03details/details.rst index 2a1fca7f40263c962a4e05c7e2159989366c8da0..a8152dcc6f941265b7c459c80b64b9b2384d2c17 100644 --- a/books/pru-cookbook/03details/details.rst +++ b/books/pru-cookbook/03details/details.rst @@ -214,6 +214,7 @@ and then configure the pins accordingly. .. literalinclude:: ../code/06io/setup.sh + :language: Shell :caption: setup.sh :linenos: @@ -467,6 +468,7 @@ If you are on the Black or Pocket you'll need to run the following script. .. literalinclude:: ../code/03details/servos_setup.sh + :language: Shell :caption: servos_setup.sh :linenos: @@ -497,6 +499,7 @@ everything is already configured for you. If you are on the Black or Pocket you'll need to run the following script. .. literalinclude:: ../code/03details/encoder_setup.sh + :language: Shell :caption: encoder_setup.sh :linenos: diff --git a/books/pru-cookbook/05blocks/blocks.rst b/books/pru-cookbook/05blocks/blocks.rst index 8ffe9acc21eb48c9ce71236e68f89d9318121992..d313229cfc17eaf73ea26bab414f171c00c3520a 100644 --- a/books/pru-cookbook/05blocks/blocks.rst +++ b/books/pru-cookbook/05blocks/blocks.rst @@ -313,6 +313,7 @@ the code work. Fortunately the Makefile always runs it. .. _blocks_write_init_pins: .. literalinclude:: ../code/05blocks/write_init_pins.sh + :language: Shell :caption: write_init_pins.sh :linenos: @@ -863,6 +864,7 @@ Here's the code (``pwm7.pru0.c``) Be sure to run ``pwm7_setup.sh`` to get the correct pins configured. .. literalinclude:: ../code/05blocks/pwm7_setup.sh + :language: Shell :caption: pwm7_setup.sh :linenos: @@ -1047,6 +1049,7 @@ These values came from :ref:`blocks_mapping_bits`. Configure the pins with ``input_setup.sh``. .. literalinclude:: ../code/05blocks/input_setup.sh + :language: Shell :caption: input_setup.sh :linenos: @@ -1720,6 +1723,7 @@ high-level view of how to drive the display. .. _blocks_rgb_python: .. literalinclude:: ../code/05blocks/rgb_python.py + :language: Python :caption: rgb_python.py - Python code for driving RGB LED matrix :linenos: @@ -1730,6 +1734,7 @@ Be sure to run the :ref:`blocks_rgb_setup` script before running the python code .. _blocks_rgb_setup: .. literalinclude:: ../code/05blocks/rgb_python_setup.sh + :language: Shell :caption: rgb_python_setup.sh :linenos: diff --git a/books/pru-cookbook/06io/io.rst b/books/pru-cookbook/06io/io.rst index e4a93302df9c6086f5c7c0e5972037bfe3a5408d..bd2161c2ad1e528f4727412f06984557f932fd29 100644 --- a/books/pru-cookbook/06io/io.rst +++ b/books/pru-cookbook/06io/io.rst @@ -98,6 +98,7 @@ GPIO pins, but it's a slower access. This code will toggle ``P9_11`` on and off. Here's the setup file. .. literalinclude:: ../code/06io/setup.sh + :language: shell :caption: setup.sh :linenos: diff --git a/intro/beagle101/blinkLED.rst b/intro/beagle101/blinkLED.rst index 8cd4077b3cf62dfc0c1499b9d54ef9046f30229c..1d66ddec45b4575021b970778d3284d3151d9e29 100644 --- a/intro/beagle101/blinkLED.rst +++ b/intro/beagle101/blinkLED.rst @@ -81,7 +81,7 @@ depends on which Beagle you have. Click on the tab for your board. Board Power LED - For more details see: :ref:`connecting-up-your-beaglebone-ai-64` + For more details see: :ref:`bbai64-quick-start` .. group-tab:: Play @@ -441,6 +441,7 @@ The following script uses evtest to wait for the USR button to be pressed and then turns on the LED. .. literalinclude:: buttonEvent.sh + :language: Shell :caption: buttonEvent.sh :linenos: @@ -451,6 +452,7 @@ Try running it and pressing the USR button. The next script polls the USR button and toggles the LED. .. literalinclude:: buttonLED.sh + :language: shell :caption: buttonLED.sh :linenos: diff --git a/intro/beagle101/qwiic-stemma-grove-addons.rst b/intro/beagle101/qwiic-stemma-grove-addons.rst index 0b6e2d2faf34c51ce19b2bca26c21a70114a0ffe..f730868a340abff60f87983f991faeeb37ee0192 100644 --- a/intro/beagle101/qwiic-stemma-grove-addons.rst +++ b/intro/beagle101/qwiic-stemma-grove-addons.rst @@ -67,7 +67,7 @@ driver loaded. Finally, `in_illuminance0_input` comes from the for this type of device, a light sensor. The `Linux kernel ABI documentation for sysfs-bus-iio <https://www.kernel.org/doc/html/v5.19/admin-guide/abi-testing.html#abi-sys-iio-devicex-in-illuminance-input>`__ provides the definition of available data often provided by light sensor drivers. -.. code-block:: +.. code-block:: bash What: /sys/.../iio:deviceX/in_illuminance_input What: /sys/.../iio:deviceX/in_illuminance_raw diff --git a/intro/contribution/git-usage.rst b/intro/contribution/git-usage.rst index 10062fb01f89d6b47fbf78524c42feff7e0d7bf1..26f24825b3ea38705d81d113891c25d30ecd4b27 100644 --- a/intro/contribution/git-usage.rst +++ b/intro/contribution/git-usage.rst @@ -439,13 +439,13 @@ in your local repository, type: If Jason is adding more commits to his remote branch and you want to update your local copy, just do: -.. code-block:: +.. code-block:: bash git checkout awesomebranch # if you are not already in branch awesomebranch pull If you later want to remove the reference to this particular branch: -.. code-block:: +.. code-block:: bash git branch -r -d jkridner/awesomebranch Deleted remote branch jkridner/awesomebranch (#######) diff --git a/projects/beagleconnect/index.rst b/projects/beagleconnect/index.rst index c9edd084a08f3fb7a0905d259f0a81e2bfb0015e..31f72fbaa94a0f9718ae04eadc0e68ee30a4cb02 100644 --- a/projects/beagleconnect/index.rst +++ b/projects/beagleconnect/index.rst @@ -216,7 +216,7 @@ that is required is a reliable transport. Every 1-2 minutes, you should see something like: -.. code-block:: +.. code-block:: bash ('fe80::3111:7a22:4b:1200%lowpan0', 52213, 0, 13) '2l:7.79;' ('fe80::3111:7a22:4b:1200%lowpan0', 52213, 0, 13) '4h:43.75;4t:23.11;' @@ -912,7 +912,7 @@ Ping Linux Similarly, we can ping the Linux host from the Zephyr shell. -.. code-block:: +.. code-block:: bash uart:~$ net ping --help ping - Ping a network host. diff --git a/projects/librobotcontrol b/projects/librobotcontrol index 1606554843c2b53ab7ca0817868fb32e9f3e6b21..1974b76fd578ff9f5d1481ebd34f6801b9edeb6a 160000 --- a/projects/librobotcontrol +++ b/projects/librobotcontrol @@ -1 +1 @@ -Subproject commit 1606554843c2b53ab7ca0817868fb32e9f3e6b21 +Subproject commit 1974b76fd578ff9f5d1481ebd34f6801b9edeb6a