From 311cc4a03ce6d0f75c143af846df293603a7ef2c Mon Sep 17 00:00:00 2001 From: Megamannen Date: Mon, 1 Mar 2021 22:42:05 +0100 Subject: [PATCH] Ran prettier and updated pin reference according to suggestion --- docs/docs/features/underglow.md | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/docs/docs/features/underglow.md b/docs/docs/features/underglow.md index f1b6d95a..a093ecac 100644 --- a/docs/docs/features/underglow.md +++ b/docs/docs/features/underglow.md @@ -56,12 +56,13 @@ Inside the `boards/` folder, you define a `.overlay` for each different b For example, the Kyria shield has a `boards/nice_nano.overlay` file that defines the RGB underglow for the `nice_nano` board specifically. ### nRF52-based boards + With nRF52 boards, you can just use `&spi1` and define the pins you want to use. To identify which pin number you need to put in the config you need do to a bit of math. You need the hardware port and run it through a function. -**32 * X + Y** = `` where X is first part of the hardware port "PX.01" and Y is the second part of the hardware port "P1.Y". +**32 \* X + Y** = `` where X is first part of the hardware port "PX.01" and Y is the second part of the hardware port "P1.Y". -(_P1.13_ would give you _32 * 1 + 13_ = `<45>` and P0.15 would give you _32 * 0 + 15_ = `<15>`) +(_P1.13_ would give you _32 \* 1 + 13_ = `<45>` and P0.15 would give you _32 \* 0 + 15_ = `<15>`) Here's an example on a definition that uses P0.06: @@ -93,11 +94,12 @@ Here's an example on a definition that uses P0.06: :::info If you are configuring SPI for an nRF52 based board, double check that you are using pins that aren't restricted to low frequency I/O. -Ignoring these restrictions may result in poor wireless performance. You can find the list of low frequency I/O pins [here](https://infocenter.nordicsemi.com/index.jsp?topic=%2Fps_nrf52840%2Fpin.html&cp=4_0_0_6_0). +Ignoring these restrictions may result in poor wireless performance. You can find the list of low frequency I/O pins for the nRF52840 [here](https://infocenter.nordicsemi.com/index.jsp?topic=%2Fps_nrf52840%2Fpin.html&cp=4_0_0_6_0). ::: ### Other boards + For other boards, you must select an SPI definition that has the `MOSI` pin as your data pin going to your LED strip. Here's another example for a non-nRF52 board on `spi1`: