// PocketBeagle device definitions
// Copyright (C)2018-2023, Philip Munts dba Munts Technologies.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are met:
//
// * Redistributions of source code must retain the above copyright notice,
// this list of conditions and the following disclaimer.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
// ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
// LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
// SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
// POSSIBILITY OF SUCH DAMAGE.
using IO.Objects.SimpleIO.Device;
namespace IO.Objects.SimpleIO.Platforms
{
///
/// This class defines identifiers for the devices provided by the
/// PocketBeagle hardware platform.
/// .
public static class PocketBeagle
{
/// ADC input designator (0, 0) for P1.19 (1.8V).
/// Requires the PB-ADC device tree overlay.
public static readonly Designator AIN0 = new Designator(0, 0);
/// ADC input designator (0, 1) for P1.21 (1.8V).
/// Requires the PB-ADC device tree overlay.
public static readonly Designator AIN1 = new Designator(0, 1);
/// ADC input designator (0, 2) for P1.23 (1.8V).
/// Requires the PB-ADC device tree overlay.
public static readonly Designator AIN2 = new Designator(0, 2);
/// ADC input designator (0, 3) for P1.25 (1.8V).
/// Requires the PB-ADC device tree overlay.
public static readonly Designator AIN3 = new Designator(0, 3);
/// ADC input designator (0, 4) for P1.27 (1.8V).
/// Requires the PB-ADC device tree overlay.
public static readonly Designator AIN4 = new Designator(0, 4);
/// ADC input designator (0, 5) for P2.35 (3.6V). Conflicts
/// with GPIO86.
/// Requires the PB-ADC device tree overlay.
public static readonly Designator AIN5 = new Designator(0, 5);
/// ADC input designator (0, 6) for P1.2 (3.6V). Conflicts
/// with GPIO87.
/// Requires the PB-ADC device tree overlay.
public static readonly Designator AIN6 = new Designator(0, 6);
/// ADC input designator (0, 7) for P2.36 (1.8V).
/// Requires the PB-ADC device tree overlay.
public static readonly Designator AIN7 = new Designator(0, 7);
/// GPIO pin designator (0, 2) for P1.8. Conflicts with
/// SPI0 SCLK.
public static readonly Designator GPIO2 = new Designator(0, 2);
/// GPIO pin designator (0, 3) for P1.10. Conflicts with
/// SPI0 MISO.
public static readonly Designator GPIO3 = new Designator(0, 3);
/// GPIO pin designator (0, 4) for P1.12. Conflicts with
/// SPI0 MOSI.
public static readonly Designator GPIO4 = new Designator(0, 4);
/// GPIO pin designator (0, 5) for P1.6. Conflicts with
/// SPI0 CS0.
public static readonly Designator GPIO5 = new Designator(0, 5);
/// GPIO pin designator (0, 7) for P2.29. Conflicts with
/// SPI1 SCLK.
public static readonly Designator GPIO7 = new Designator(0, 7);
/// GPIO pin designator (0, 12) for P1.26. Conflicts with
/// I2C2 SDA.
public static readonly Designator GPIO12 = new Designator(0, 12);
/// GPIO pin designator (0, 13) for P1.28. Conflicts with
/// I2C2 SCL.
public static readonly Designator GPIO13 = new Designator(0, 13);
/// GPIO pin designator (0, 14) for P2.11. Conflicts with
/// I2C1 SDA.
public static readonly Designator GPIO14 = new Designator(0, 14);
/// GPIO pin designator (0, 15) for P2.9. Conflicts with
/// I2C1 SCL.
public static readonly Designator GPIO15 = new Designator(0, 15);
/// GPIO pin designator (0, 19) for P2.31. Conflicts with
/// SPI1 CS1.
public static readonly Designator GPIO19 = new Designator(0, 19);
/// GPIO pin designator (0, 20) for P1.20.
public static readonly Designator GPIO20 = new Designator(0, 20);
/// GPIO pin designator (0, 23) for P2.3.
public static readonly Designator GPIO23 = new Designator(0, 23);
/// GPIO pin designator (0, 26) for P1.34.
public static readonly Designator GPIO26 = new Designator(0, 26);
/// GPIO pin designator (0, 27) for P2.19.
public static readonly Designator GPIO27 = new Designator(0, 27);
/// GPIO pin designator (0, 30) for P2.5. Conflicts with
/// RXD4.
public static readonly Designator GPIO30 = new Designator(0, 30);
/// GPIO pin designator (0, 31) for P2.7. Conflicts with
/// TXD4.
public static readonly Designator GPIO31 = new Designator(0, 31);
/// GPIO pin designator (1, 8) for P2.27. Conflicts with
/// SPI1 MISO.
public static readonly Designator GPIO40 = new Designator(1, 8);
/// GPIO pin designator (1, 9) for P2.25. Conflicts with
/// SPI1 MOSI.
public static readonly Designator GPIO41 = new Designator(1, 9);
/// GPIO pin designator (1, 10) for P1.32. Conflicts with
/// RXD0.
public static readonly Designator GPIO42 = new Designator(1, 10);
/// GPIO pin designator (1, 11) for P1.30. Conflicts with
/// TXD0.
public static readonly Designator GPIO43 = new Designator(1, 11);
/// GPIO pin designator (1, 12) for P2.24.
public static readonly Designator GPIO44 = new Designator(1, 12);
/// GPIO pin designator (1, 13) for P2.33.
public static readonly Designator GPIO45 = new Designator(1, 13);
/// GPIO pin designator (1, 14) for P2.22.
public static readonly Designator GPIO46 = new Designator(1, 14);
/// GPIO pin designator (1, 15) for P2.18.
public static readonly Designator GPIO47 = new Designator(1, 15);
/// GPIO pin designator (1, 18) for P2.1.
public static readonly Designator GPIO50 = new Designator(1, 18);
/// GPIO pin designator (1, 20) for P2.10.
public static readonly Designator GPIO52 = new Designator(1, 20);
/// GPIO pin designator (1, 25) for P2.6.
public static readonly Designator GPIO57 = new Designator(1, 25);
/// GPIO pin designator (1, 26) for P2.4.
public static readonly Designator GPIO58 = new Designator(1, 26);
/// GPIO pin designator (1, 27) for P2.2.
public static readonly Designator GPIO59 = new Designator(1, 27);
/// GPIO pin designator (1, 28) for P2.8.
public static readonly Designator GPIO60 = new Designator(1, 28);
/// GPIO pin designator (2, 0) for P2.20.
public static readonly Designator GPIO64 = new Designator(2, 0);
/// GPIO pin designator (2, 1) for P2.17.
public static readonly Designator GPIO65 = new Designator(2, 1);
/// GPIO pin designator (2, 22) for P2.35. Conflicts with
/// AIN5.
public static readonly Designator GPIO86 = new Designator(2, 22);
/// GPIO pin designator (2, 23) for P1.2. Conflicts with
/// AIN6.
public static readonly Designator GPIO87 = new Designator(2, 23);
/// GPIO pin designator (2, 24) for P1.35.
public static readonly Designator GPIO88 = new Designator(2, 24);
/// GPIO pin designator (2, 25) for P1.4.
public static readonly Designator GPIO89 = new Designator(2, 25);
/// GPIO pin designator (3, 14) for P1.36.
public static readonly Designator GPIO110 = new Designator(3, 14);
/// GPIO pin designator (3, 15) for P1.33.
public static readonly Designator GPIO111 = new Designator(3, 15);
/// GPIO pin designator (3, 16) for P2.32.
public static readonly Designator GPIO112 = new Designator(3, 16);
/// GPIO pin designator (3, 17) for P2.30.
public static readonly Designator GPIO113 = new Designator(3, 17);
/// GPIO pin designator (3, 18) for P1.31.
public static readonly Designator GPIO114 = new Designator(3, 18);
/// GPIO pin designator (3, 19) for P2.34.
public static readonly Designator GPIO115 = new Designator(3, 19);
/// GPIO pin designator (3, 20) for P2.28.
public static readonly Designator GPIO116 = new Designator(3, 20);
/// GPIO pin designator (3, 21) for P1.29.
public static readonly Designator GPIO117 = new Designator(3, 21);
/// I2C bus designator (0, 1) for P2.9 and P2.11. Conflicts
/// with GPIO15 and GPIO14.
public static readonly Designator I2C1 = new Designator(0, 1);
/// I2C bus designator (0, 2) for P1.26 and P1.28. Conflicts
/// with GPIO12 and GPIO13.
public static readonly Designator I2C2 = new Designator(0, 2);
/// PWM output designator (0, 0) for P1.36. Conflicts with
/// GPIO110.
public static readonly Designator PWM0_0 = new Designator(0, 0);
/// PWM output designator (2, 0) for P2.1. Conflicts with
/// GPIO50.
public static readonly Designator PWM2_0 = new Designator(2, 0);
/// SPI slave designator (0, 0) for P1.6. Conflicts with
/// GPIO5.
public static readonly Designator SPI0_0 = new Designator(0, 0);
/// SPI slave designator (1, 1) for P2.31. Conflicts with
/// GPIO19.
public static readonly Designator SPI1_1 = new Designator(1, 1);
}
}