]> Repositories - Adafruit_Blinka-hackapet.git/blob - test/src/testing/board/__init__.py
Added pre-commit support
[Adafruit_Blinka-hackapet.git] / test / src / testing / board / __init__.py
1 # SPDX-FileCopyrightText: 2021 Melissa LeBlanc-Williams for Adafruit Industries
2 #
3 # SPDX-License-Identifier: MIT
4 """Configuration of testing fixtures depending on the board layout"""
5 from adafruit_blinka import agnostic
6
7 import board
8
9 if agnostic.board == "feather_m0_express":
10     default_pin = board.D5
11     led_pin = board.D13
12     led_hardwired = True
13     led_inverted = False
14 elif agnostic.board == "feather_huzzah":
15     default_pin = board.GPIO4
16     led_pin = board.GPIO0  # red led
17     led_hardwired = True
18     led_inverted = True
19 elif agnostic.board == "pyboard":
20     default_pin = board.X1
21     led_pin = board.LED_BLUE
22     led_hardwired = True
23     led_inverted = False
24     uartTxId = "B6"
25     uartRXId = "B7"
26 else:
27     raise NotImplementedError("Board not supported")