Skip to content

Commit

Permalink
microcontrollers: list PWM peripherals along with the pins
Browse files Browse the repository at this point in the history
Add PWM peripherals in the pin table so that it becomes easier to know
which PWM peripheral is usable for a given pin.

This doesn't include all chips. Specifically:

  - stm32 chips aren't included yet
  - nrf chips can use any PWM peripheral for any pin, so a table doesn't
    make much sense
  • Loading branch information
aykevl authored and deadprogram committed Sep 5, 2022
1 parent 0d03d68 commit 24c6586
Show file tree
Hide file tree
Showing 30 changed files with 1,214 additions and 1,157 deletions.
144 changes: 72 additions & 72 deletions content/docs/reference/microcontrollers/arduino-mega1280.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,78 +21,78 @@ Note: the AVR backend of LLVM is still experimental so you may encounter bugs.

## Pins

| Pin | Hardware pin | Alternative names |
| ----------------- | ------------ | ----------------- |
| `A0` | `PF0` | `ADC0` |
| `A1` | `PF1` | `ADC1` |
| `A2` | `PF2` | `ADC2` |
| `A3` | `PF3` | `ADC3` |
| `A4` | `PF4` | `ADC4` |
| `A5` | `PF5` | `ADC5` |
| `A6` | `PF6` | `ADC6` |
| `A7` | `PF7` | `ADC7` |
| `A8` | `PK0` | `ADC8` |
| `A9` | `PK1` | `ADC9` |
| `A10` | `PK2` | `ADC10` |
| `A11` | `PK3` | `ADC11` |
| `A12` | `PK4` | `ADC12` |
| `A13` | `PK5` | `ADC13` |
| `A14` | `PK6` | `ADC14` |
| `A15` | `PK7` | `ADC15` |
| `D0` | `PE0` | |
| `D1` | `PE1` | |
| `D2` | `PE4` | |
| `D3` | `PE5` | |
| `D4` | `PG5` | |
| `D5` | `PE3` | |
| `D6` | `PH3` | |
| `D7` | `PH4` | |
| `D8` | `PH5` | |
| `D9` | `PH6` | |
| `D10` | `PB4` | |
| `D11` | `PB5` | |
| `D12` | `PB6` | |
| `D13` | `PB7` | `LED` |
| `D14` | `PJ1` | |
| `D15` | `PJ0` | |
| `D16` | `PH1` | |
| `D17` | `PH0` | |
| `D18` | `PD3` | |
| `D19` | `PD2` | |
| `D20` | `PD1` | |
| `D21` | `PD0` | |
| `D22` | `PA0` | |
| `D23` | `PA1` | |
| `D24` | `PA2` | |
| `D25` | `PA3` | |
| `D26` | `PA4` | |
| `D27` | `PA5` | |
| `D28` | `PA6` | |
| `D29` | `PA7` | |
| `D30` | `PC7` | |
| `D31` | `PC6` | |
| `D32` | `PC5` | |
| `D33` | `PC4` | |
| `D34` | `PC3` | |
| `D35` | `PC2` | |
| `D36` | `PC1` | |
| `D37` | `PC0` | |
| `D38` | `PD7` | |
| `D39` | `PG2` | |
| `D40` | `PG1` | |
| `D41` | `PG0` | |
| `D42` | `PL7` | |
| `D43` | `PL6` | |
| `D44` | `PL5` | |
| `D45` | `PL4` | |
| `D46` | `PL3` | |
| `D47` | `PL2` | |
| `D48` | `PL1` | |
| `D49` | `PL0` | |
| `D50` | `PB3` | |
| `D51` | `PB2` | |
| `D52` | `PB1` | |
| `D53` | `PB0` | |
| Pin | Hardware pin | Alternative names | PWM |
| ----------------- | ------------ | ----------------- | -------------------- |
| `A0` | `PF0` | `ADC0` | |
| `A1` | `PF1` | `ADC1` | |
| `A2` | `PF2` | `ADC2` | |
| `A3` | `PF3` | `ADC3` | |
| `A4` | `PF4` | `ADC4` | |
| `A5` | `PF5` | `ADC5` | |
| `A6` | `PF6` | `ADC6` | |
| `A7` | `PF7` | `ADC7` | |
| `A8` | `PK0` | `ADC8` | |
| `A9` | `PK1` | `ADC9` | |
| `A10` | `PK2` | `ADC10` | |
| `A11` | `PK3` | `ADC11` | |
| `A12` | `PK4` | `ADC12` | |
| `A13` | `PK5` | `ADC13` | |
| `A14` | `PK6` | `ADC14` | |
| `A15` | `PK7` | `ADC15` | |
| `D0` | `PE0` | | |
| `D1` | `PE1` | | |
| `D2` | `PE4` | | `Timer3` (channel B) |
| `D3` | `PE5` | | `Timer3` (channel C) |
| `D4` | `PG5` | | `Timer0` (channel B) |
| `D5` | `PE3` | | `Timer3` (channel A) |
| `D6` | `PH3` | | `Timer4` (channel A) |
| `D7` | `PH4` | | `Timer4` (channel B) |
| `D8` | `PH5` | | `Timer4` (channel C) |
| `D9` | `PH6` | | `Timer0` (channel B) |
| `D10` | `PB4` | | `Timer2` (channel A) |
| `D11` | `PB5` | | `Timer1` (channel A) |
| `D12` | `PB6` | | `Timer1` (channel B) |
| `D13` | `PB7` | `LED` | `Timer0` (channel A) |
| `D14` | `PJ1` | | |
| `D15` | `PJ0` | | |
| `D16` | `PH1` | | |
| `D17` | `PH0` | | |
| `D18` | `PD3` | | |
| `D19` | `PD2` | | |
| `D20` | `PD1` | | |
| `D21` | `PD0` | | |
| `D22` | `PA0` | | |
| `D23` | `PA1` | | |
| `D24` | `PA2` | | |
| `D25` | `PA3` | | |
| `D26` | `PA4` | | |
| `D27` | `PA5` | | |
| `D28` | `PA6` | | |
| `D29` | `PA7` | | |
| `D30` | `PC7` | | |
| `D31` | `PC6` | | |
| `D32` | `PC5` | | |
| `D33` | `PC4` | | |
| `D34` | `PC3` | | |
| `D35` | `PC2` | | |
| `D36` | `PC1` | | |
| `D37` | `PC0` | | |
| `D38` | `PD7` | | |
| `D39` | `PG2` | | |
| `D40` | `PG1` | | |
| `D41` | `PG0` | | |
| `D42` | `PL7` | | |
| `D43` | `PL6` | | |
| `D44` | `PL5` | | `Timer5` (channel C) |
| `D45` | `PL4` | | `Timer5` (channel B) |
| `D46` | `PL3` | | `Timer5` (channel A) |
| `D47` | `PL2` | | |
| `D48` | `PL1` | | |
| `D49` | `PL0` | | |
| `D50` | `PB3` | | |
| `D51` | `PB2` | | |
| `D52` | `PB1` | | |
| `D53` | `PB0` | | |

## Machine Package Docs

Expand Down
52 changes: 26 additions & 26 deletions content/docs/reference/microcontrollers/arduino-mkr1000.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,32 +19,32 @@ The [Arduino MKR1000](https://store.arduino.cc/arduino-mkr1000-wifi) is a very s

## Pins

| Pin | Hardware pin | Alternative names |
| ----------------- | ------------ | ----------------- |
| `D0` | `PA22` | |
| `D1` | `PA23` | |
| `D2` | `PA10` | `I2S_SCK_PIN` |
| `D3` | `PA11` | |
| `D4` | `PB10` | |
| `D5` | `PB11` | |
| `D6` | `PA20` | `LED` |
| `D7` | `PA21` | |
| `D8` | `PA16` | `SPI0_SDO_PIN` |
| `D9` | `PA17` | `SPI0_SCK_PIN` |
| `D10` | `PA19` | `SPI0_SDI_PIN` |
| `D11` | `PA08` | `SDA_PIN` |
| `D12` | `PA09` | `SCL_PIN` |
| `D13` | `PB23` | `RX0`, `UART_RX_PIN` |
| `D14` | `PB22` | `TX1`, `UART_TX_PIN` |
| `A0` | `PA02` | |
| `A1` | `PB02` | |
| `A2` | `PB03` | |
| `A3` | `PA04` | |
| `A4` | `PA05` | |
| `A5` | `PA06` | |
| `A6` | `PA07` | `I2S_SD_PIN` |
| `USBCDC_DM_PIN` | `PA24` | |
| `USBCDC_DP_PIN` | `PA25` | |
| Pin | Hardware pin | Alternative names | PWM |
| ----------------- | ------------ | ----------------- | -------------------- |
| `D0` | `PA22` | | `TCC0` (channel 0) |
| `D1` | `PA23` | | `TCC0` (channel 1) |
| `D2` | `PA10` | `I2S_SCK_PIN` | `TCC1` (channel 0), `TCC0` (channel 2) |
| `D3` | `PA11` | | `TCC1` (channel 1), `TCC0` (channel 3) |
| `D4` | `PB10` | | `TCC0` (channel 0) |
| `D5` | `PB11` | | `TCC0` (channel 1) |
| `D6` | `PA20` | `LED` | `TCC0` (channel 2) |
| `D7` | `PA21` | | `TCC0` (channel 3) |
| `D8` | `PA16` | `SPI0_SDO_PIN` | `TCC2` (channel 0), `TCC0` (channel 2) |
| `D9` | `PA17` | `SPI0_SCK_PIN` | `TCC2` (channel 1), `TCC0` (channel 3) |
| `D10` | `PA19` | `SPI0_SDI_PIN` | `TCC0` (channel 3) |
| `D11` | `PA08` | `SDA_PIN` | `TCC0` (channel 0), `TCC1` (channel 2) |
| `D12` | `PA09` | `SCL_PIN` | `TCC0` (channel 1), `TCC1` (channel 3) |
| `D13` | `PB23` | `RX0`, `UART_RX_PIN` | |
| `D14` | `PB22` | `TX1`, `UART_TX_PIN` | |
| `A0` | `PA02` | | |
| `A1` | `PB02` | | |
| `A2` | `PB03` | | |
| `A3` | `PA04` | | `TCC0` (channel 0) |
| `A4` | `PA05` | | `TCC0` (channel 1) |
| `A5` | `PA06` | | `TCC1` (channel 0) |
| `A6` | `PA07` | `I2S_SD_PIN` | `TCC1` (channel 1) |
| `USBCDC_DM_PIN` | `PA24` | | `TCC1` (channel 2) |
| `USBCDC_DP_PIN` | `PA25` | | `TCC1` (channel 3) |

## Machine Package Docs

Expand Down
66 changes: 33 additions & 33 deletions content/docs/reference/microcontrollers/arduino-mkrwifi1010.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,39 +19,39 @@ The [Arduino MKR WiFi 1010](https://store.arduino.cc/usa/mkr-wifi-1010) is a ver

## Pins

| Pin | Hardware pin | Alternative names |
| ----------------- | ------------ | ----------------- |
| `D0` | `PA22` | `NINA_TX` |
| `D1` | `PA23` | `NINA_RX` |
| `D2` | `PA10` | `I2S_SCK_PIN` |
| `D3` | `PA11` | |
| `D4` | `PB10` | |
| `D5` | `PB11` | |
| `D6` | `PA20` | `LED` |
| `D7` | `PA21` | |
| `D8` | `PA16` | `SPI0_SDO_PIN` |
| `D9` | `PA17` | `SPI0_SCK_PIN` |
| `D10` | `PA19` | `SPI0_SDI_PIN` |
| `D11` | `PA08` | `SDA_PIN` |
| `D12` | `PA09` | `SCL_PIN` |
| `D13` | `PB23` | `RX0`, `UART_RX_PIN` |
| `D14` | `PB22` | `TX1`, `UART_TX_PIN` |
| `A0` | `PA02` | |
| `A1` | `PB02` | |
| `A2` | `PB03` | |
| `A3` | `PA04` | |
| `A4` | `PA05` | |
| `A5` | `PA06` | |
| `A6` | `PA07` | `I2S_SD_PIN` |
| `USBCDC_DM_PIN` | `PA24` | |
| `USBCDC_DP_PIN` | `PA25` | |
| `NINA_SDO` | `PA12` | |
| `NINA_SDI` | `PA13` | |
| `NINA_CS` | `PA14` | |
| `NINA_SCK` | `PA15` | |
| `NINA_GPIO0` | `PA27` | |
| `NINA_RESETN` | `PB08` | |
| `NINA_ACK` | `PA28` | |
| Pin | Hardware pin | Alternative names | PWM |
| ----------------- | ------------ | ----------------- | -------------------- |
| `D0` | `PA22` | `NINA_TX` | `TCC0` (channel 0) |
| `D1` | `PA23` | `NINA_RX` | `TCC0` (channel 1) |
| `D2` | `PA10` | `I2S_SCK_PIN` | `TCC1` (channel 0), `TCC0` (channel 2) |
| `D3` | `PA11` | | `TCC1` (channel 1), `TCC0` (channel 3) |
| `D4` | `PB10` | | `TCC0` (channel 0) |
| `D5` | `PB11` | | `TCC0` (channel 1) |
| `D6` | `PA20` | `LED` | `TCC0` (channel 2) |
| `D7` | `PA21` | | `TCC0` (channel 3) |
| `D8` | `PA16` | `SPI0_SDO_PIN` | `TCC2` (channel 0), `TCC0` (channel 2) |
| `D9` | `PA17` | `SPI0_SCK_PIN` | `TCC2` (channel 1), `TCC0` (channel 3) |
| `D10` | `PA19` | `SPI0_SDI_PIN` | `TCC0` (channel 3) |
| `D11` | `PA08` | `SDA_PIN` | `TCC0` (channel 0), `TCC1` (channel 2) |
| `D12` | `PA09` | `SCL_PIN` | `TCC0` (channel 1), `TCC1` (channel 3) |
| `D13` | `PB23` | `RX0`, `UART_RX_PIN` | |
| `D14` | `PB22` | `TX1`, `UART_TX_PIN` | |
| `A0` | `PA02` | | |
| `A1` | `PB02` | | |
| `A2` | `PB03` | | |
| `A3` | `PA04` | | `TCC0` (channel 0) |
| `A4` | `PA05` | | `TCC0` (channel 1) |
| `A5` | `PA06` | | `TCC1` (channel 0) |
| `A6` | `PA07` | `I2S_SD_PIN` | `TCC1` (channel 1) |
| `USBCDC_DM_PIN` | `PA24` | | `TCC1` (channel 2) |
| `USBCDC_DP_PIN` | `PA25` | | `TCC1` (channel 3) |
| `NINA_SDO` | `PA12` | | `TCC2` (channel 0), `TCC0` (channel 2) |
| `NINA_SDI` | `PA13` | | `TCC2` (channel 1), `TCC0` (channel 3) |
| `NINA_CS` | `PA14` | | `TCC0` (channel 0) |
| `NINA_SCK` | `PA15` | | `TCC0` (channel 1) |
| `NINA_GPIO0` | `PA27` | | |
| `NINA_RESETN` | `PB08` | | |
| `NINA_ACK` | `PA28` | | |

## Machine Package Docs

Expand Down
Loading

0 comments on commit 24c6586

Please sign in to comment.