### Install pip3 Source: https://learn.adafruit.com/adafruit-led-backpack?view=all Command to install pip3 if it is missing on your system. ```bash sudo apt-get install python3-pip ``` -------------------------------- ### Install PIL via apt-get Source: https://learn.adafruit.com/adafruit-led-backpack?view=all Install the Python Imaging Library (PIL) using the system package manager to support custom fonts. ```bash sudo apt-get install python3-pil ``` -------------------------------- ### Initialize I2C and Seg7x4 display Source: https://learn.adafruit.com/adafruit-led-backpack/0-dot-56-seven-segment-backpack-circuitpython-and-python-usage Imports the necessary modules and creates an I2C instance using board.I2C(), then initializes a Seg7x4 display. Use this as the starting point for controlling the LED backpack from the REPL. ```python import board from adafruit_ht16k33.segments import Seg7x4 i2c = board.I2C() display = Seg7x4(i2c) ``` -------------------------------- ### Adafruit_7segment matrix begin(0x70) - single Source: https://learn.adafruit.com/adafruit-led-backpack/changing-i2c-address Original example for setting a single seven-segment matrix to address 0x70. Replace this with two object instantiations when using multiple backpacks. ```C++ Adafruit_7segment matrix = Adafruit_7segment(); void setup() { Serial.begin(9600); Serial.println("7 Segment Backpack Test"); matrix.begin(0x70); } ``` -------------------------------- ### Install HT16K33 Library Source: https://learn.adafruit.com/adafruit-led-backpack?view=all Command to install the CircuitPython HT16K33 library via pip. ```bash pip3 install adafruit-circuitpython-ht16k33 ``` -------------------------------- ### CircuitPython AlphaNumeric Display Example Source: https://learn.adafruit.com/adafruit-led-backpack?view=all This script demonstrates how to initialize the display, use set_digit_raw with various data formats, and scroll text using the marquee function. ```python # SPDX-FileCopyrightText: 2022 Kattni Rembor for Adafruit Industries # SPDX-License-Identifier: MIT import time import board from adafruit_ht16k33 import segments # Create the display object. # Display connected to STEMMA QT connector. display = segments.Seg14x4(board.STEMMA_I2C()) # Display connected to I2C pins. # display = segments.Seg14x4(board.I2C()) # uses board.SCL and board.SDA # This section displays four 0's across the display. The code shows four # different ways to use the set_digit_raw function. Each is labeled below. # 16-bit Hexadecimal number display.set_digit_raw(0, 0x2D3F) time.sleep(0.2) # 16-bit Binary number display.set_digit_raw(1, 0b0010110100111111) time.sleep(0.2) # 8-bit Binary Tuple display.set_digit_raw(2, (0b00101101, 0b00111111)) time.sleep(0.2) # 8-bit Hexadecimal List display.set_digit_raw(3, [0x2D, 0x3F]) time.sleep(0.2) # Delay between. time.sleep(2) # Scroll "Hello, world!" across the display. Setting the loop parameter to false allows you to # tell the marquee function to run only once. By default, marquee loops indefinitely. display.marquee("Hello, world!", loop=False) # Delay between. time.sleep(2) # Scroll special characters, uppercase and lowercase letters, and numbers across # the display in a loop. This section will continue to run indefinitely. display.marquee("".join(chr(character) for character in range(ord("!"), ord("z") + 1))) ``` -------------------------------- ### Line Number Reference Source: https://learn.adafruit.com/adafruit-led-backpack?view=all A simple list of line numbers corresponding to the code example. ```text 1 2 3 4 5 6 7 8 ``` -------------------------------- ### Set Custom I2C Address for BiColor24 Source: https://learn.adafruit.com/adafruit-led-backpack/bi-color-24-bargraph-circuitpython-usage Passes a custom I2C address to the Bicolor24 constructor. Addresses can range from 0x70 to 0x77 depending on bridged pads; for example, bridging only the a0 pad uses 0x71. ```python bc24 = Bicolor24(i2c, address=0x71) ``` -------------------------------- ### Set individual segments using set_digit_raw Source: https://learn.adafruit.com/adafruit-led-backpack/0-dot-56-seven-segment-backpack-circuitpython-and-python-usage Use set_digit_raw with an 8-bit bitmask (Hex, Decimal, or binary) to control specific segments of a digit. This example displays '8.8.EE' by passing different bitmask formats. ```python display.set_digit_raw(0, 0xFF) display.set_digit_raw(1, 0b11111111) display.set_digit_raw(2, 0x79) display.set_digit_raw(3, 0b01111001) ``` -------------------------------- ### Set Custom I2C Address for BigSeg7x4 Source: https://learn.adafruit.com/adafruit-led-backpack/circuitpython-and-python-usage-197dcbfa-4ccf-4b98-a152-3982411df681 Creates a BigSeg7x4 display object with a custom I2C address. The address can range from 0x70 to 0x77 depending on which address pads are bridged; for example, bridging only the A0 pad uses 0x71. ```python display = BigSeg7x4(i2c, address=0x71) ``` -------------------------------- ### Write raw segment data to digit Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-9b21a470-83ad-459c-af02-209d8d82c462 Control individual segments of a digit by writing a 16-bit raw bitmap. The first example turns off all LEDs on digit #3, and the second turns on all segments for digit #0. ```auto alpha4.writeDigitRaw(3, 0x0); ``` ```auto alpha4.writeDigitRaw(0, 0x3FFF); ``` -------------------------------- ### Set individual segments using set_digit_raw with various bitmask formats Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Sets individual segments using the set_digit_raw function with a bitmask. The bitmask can be passed as a hexadecimal, binary, decimal number, or as a list/tuple of two 8-bit numbers. All examples create a box with an X in the center. ```python display.set_digit_raw(0, 0x2D3F) display.set_digit_raw(1, 0b0010110100111111) display.set_digit_raw(2, (0b00101101, 0b00111111)) display.set_digit_raw(3, [0x2D, 0x3F]) ``` -------------------------------- ### Initialize I2C and MatrixBackpack16x8 Source: https://learn.adafruit.com/adafruit-led-backpack/1-2-16x8-matrix-circuitpython-and-python-usage Import the necessary modules and initialize the I2C bus and matrix display. Note that some boards may require board.STEMMA_I2C() instead of board.I2C(). ```python import board from adafruit_ht16k33.matrix import MatrixBackpack16x8 i2c = board.I2C() matrix = MatrixBackpack16x8(i2c) ``` -------------------------------- ### Initialize display with I2C address Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-9b21a470-83ad-459c-af02-209d8d82c462 Initialize the display using the begin method. The default address is 0x70, but a custom address can be provided. ```auto alpha4.begin(0x70); // pass in the address ``` -------------------------------- ### Initialize BigSeg7x4 Display with I2C Source: https://learn.adafruit.com/adafruit-led-backpack/circuitpython-and-python-usage-197dcbfa-4ccf-4b98-a152-3982411df681 Imports the necessary modules and initializes the I2C bus using board.I2C(), then creates a BigSeg7x4 display object. Note that some boards may require board.STEMMA_I2C() instead of board.I2C() when using the STEMMA QT port. ```python import board from adafruit_ht16k33.segments import BigSeg7x4 i2c = board.I2C() display = BigSeg7x4(i2c) ``` -------------------------------- ### Initialize BiColor24 Bargraph with I2C Source: https://learn.adafruit.com/adafruit-led-backpack/bi-color-24-bargraph-circuitpython-usage Imports the necessary modules and initializes the I2C bus using board.I2C(), then creates a Bicolor24 instance. Note: Some boards may require board.STEMMA_I2C() when using the STEMMA QT port. ```python import board from adafruit_ht16k33.bargraph import Bicolor24 i2c = board.I2C() bc24 = Bicolor24(i2c) ``` -------------------------------- ### Initialize I2C and Matrix8x8x2 Source: https://learn.adafruit.com/adafruit-led-backpack/bi-color-8x8-matrix-circuitpython-and-python-usage Imports the necessary modules and initializes the I2C bus and the LED matrix display. Note that some boards may require board.STEMMA_I2C() instead of board.I2C(). ```python import board from adafruit_ht16k33.matrix import Matrix8x8x2 i2c = board.I2C() matrix = Matrix8x8x2(i2c) ``` -------------------------------- ### Initialize I2C and Seg14x4 Display Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Import the necessary modules and initialize the I2C bus and display. Note that some boards may require board.STEMMA_I2C() when using the STEMMA QT port. ```python import board from adafruit_ht16k33.segments import Seg14x4 i2c = board.I2C() display = Seg14x4(i2c) ``` -------------------------------- ### Initialize I2C and Matrix8x8 Source: https://learn.adafruit.com/adafruit-led-backpack/0-8-8x8-matrix-circuitpython-and-python-usage Imports the necessary modules and initializes the I2C bus and the 8x8 matrix display. Note that some boards may require board.STEMMA_I2C() when using the STEMMA QT port. ```python import board from adafruit_ht16k33.matrix import Matrix8x8 i2c = board.I2C() matrix = Matrix8x8(i2c) ``` -------------------------------- ### Initialize MatrixBackpack16x8 with Custom Address Source: https://learn.adafruit.com/adafruit-led-backpack/1-2-16x8-matrix-circuitpython-and-python-usage Initialize the matrix with a specific I2C address if the address pads on the back of the display have been bridged. ```python matrix = MatrixBackpack16x8(i2c, address=0x71) ``` -------------------------------- ### Initialize Adafruit_AlphaNum4 object Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-9b21a470-83ad-459c-af02-209d8d82c462 Create the display object. No arguments or pins are required as the backpacks use fixed I2C pins. ```auto Adafruit_AlphaNum4 alpha4 = Adafruit_AlphaNum4(); ``` -------------------------------- ### Initialize Multiple Chained Displays Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Initialize multiple displays by passing a tuple of their unique I2C addresses to the address parameter. ```python display = Seg14x4(i2c, address=(0x70, 0x71)) ``` -------------------------------- ### Initialize Adafruit_24bargraph object Source: https://learn.adafruit.com/adafruit-led-backpack?view=all Create the bargraph object to interface with the display. ```cpp Adafruit_24bargraph bar = Adafruit_24bargraph(); ``` -------------------------------- ### Initialize Display with Custom Address Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Initialize the display using a specific I2C address, such as 0x71, if address pads on the back of the display have been bridged. ```python display = Seg14x4(i2c, address=0x71) ``` -------------------------------- ### Initialize bargraph with I2C address Source: https://learn.adafruit.com/adafruit-led-backpack?view=all Initialize the display using its I2C address, which defaults to 0x70. ```cpp bar.begin(0x70); // pass in the address ``` -------------------------------- ### Initialize Matrix8x8 with Custom Address Source: https://learn.adafruit.com/adafruit-led-backpack/0-8-8x8-matrix-circuitpython-and-python-usage Initializes the matrix display with a specific I2C address, useful if address pads on the back of the display have been bridged. ```python matrix = Matrix8x8(i2c, address=0x71) ``` -------------------------------- ### Initialize Matrix8x8x2 with Custom Address Source: https://learn.adafruit.com/adafruit-led-backpack/bi-color-8x8-matrix-circuitpython-and-python-usage Initializes the matrix display using a specific I2C address, which is necessary if the address pads on the back of the display have been bridged. ```python matrix = Matrix8x8x2(i2c, address=0x71) ``` -------------------------------- ### Displaying an image with Pillow Source: https://learn.adafruit.com/adafruit-led-backpack/0-8-8x8-matrix-circuitpython-and-python-usage Use this code to load an 8x8 pixel image file named 'myimage.png' and display it on the matrix. Ensure the image dimensions match the matrix size exactly. ```python import board from PIL import Image from adafruit_ht16k33 import matrix matrix = matrix.Matrix8x8(board.I2C()) image = Image.open("myimage.png") matrix.image(image) ``` -------------------------------- ### Commit data to the display Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-9b21a470-83ad-459c-af02-209d8d82c462 Call writeDisplay to actually set the data onto the LEDs after updating digits. ```auto alpha4.writeDisplay(); ``` -------------------------------- ### Set display brightness to half Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Sets the display brightness to 0.5, which is half brightness. Brightness can be adjusted in 1/16 increments between 0 and 1.0, with 1.0 being the brightest. ```python display.brightness = 0.5 ``` -------------------------------- ### Turn on all segments on digit 0 Source: https://learn.adafruit.com/adafruit-led-backpack?view=all Use writeDigitRaw with the 0x3FFF bitmap to illuminate all segments on the first digit. ```cpp alpha4.writeDigitRaw(0, 0x3FFF); ``` -------------------------------- ### Print text to display Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Prints the string 'ABCD' to the display using the print function. ```python display.print("ABCD") ``` -------------------------------- ### Fill all segments Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Use the fill() function to turn all segments on or off by passing 1 or 0 respectively. ```python display.fill(1) ``` -------------------------------- ### Adafruit_7segment matrix1 and matrix2 addressing - 0x70/0x71 Source: https://learn.adafruit.com/adafruit-led-backpack/changing-i2c-address Modified version for two seven-segment matrices, each with its own object and I2C address. Set matrix1.begin(0x70) and matrix2.begin(0x71), then use them individually. Increase the number of objects and begin() calls for more matrices. ```C++ Adafruit_7segment matrix1 = Adafruit_7segment(); Adafruit_7segment matrix2 = Adafruit_7segment(); void setup() { Serial.begin(9600); Serial.println("Double 7 Segment Backpack Test"); matrix1.begin(0x70); matrix2.begin(0x71); } ``` -------------------------------- ### Configure marquee delay and looping Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Customize the marquee delay and disable looping by providing additional parameters to the marquee function. ```python display.marquee('This is a really long string ', 0.5, False) ``` -------------------------------- ### Convenience Shift Functions Source: https://learn.adafruit.com/adafruit-led-backpack/0-8-8x8-matrix-circuitpython-and-python-usage Use dedicated convenience functions to shift pixels by one position, with an optional boolean parameter to enable looping. ```python matrix.shift_up() # Shift pixels up matrix.shift_left() # Shift pixels left matrix.shift_down() # Shift pixels down matrix.shift_right() # Shift pixels right matrix.shift_up(True) # Loop pixels up matrix.shift_left(True) # Loop pixels left matrix.shift_down(True) # Loop pixels down matrix.shift_right(True) # Loop pixels right ``` -------------------------------- ### Fill Entire Matrix Source: https://learn.adafruit.com/adafruit-led-backpack/bi-color-8x8-matrix-circuitpython-and-python-usage Use the fill() function to set every pixel on the matrix to a specific color. ```python matrix.fill(matrix.LED_GREEN) ``` -------------------------------- ### Fill Entire Matrix Source: https://learn.adafruit.com/adafruit-led-backpack/0-8-8x8-matrix-circuitpython-and-python-usage Use the fill() function to turn all pixels on or off by passing 1 or 0. ```python matrix.fill(1) ``` -------------------------------- ### Display an image on the 16x8 Matrix using Pillow Source: https://learn.adafruit.com/adafruit-led-backpack/1-2-16x8-matrix-circuitpython-and-python-usage Use the Pillow library to load and display a 16x8 pixel image on the matrix. Ensure the image file is exactly 16x8 pixels in size. ```python import board from PIL import Image from adafruit_ht16k33 import matrix matrix = matrix.MatrixBackpack16x8(board.I2C()) image = Image.open("myimage.png") matrix.image(image) ``` -------------------------------- ### Set Blink Rate Source: https://learn.adafruit.com/adafruit-led-backpack/0-8-8x8-matrix-circuitpython-and-python-usage Configure the blink rate of the entire display using a value between 0 and 3, where 3 is the fastest. ```python matrix.blink_rate = 3 ``` -------------------------------- ### Display an image with Pillow (commented version) Source: https://learn.adafruit.com/adafruit-led-backpack?view=all Alternate version of the same image display code, presumably with comments or line numbers. Note that the code block includes line numbers 1-8 as part of the source. ```python 1 2 3 4 5 6 7 8 import board from PIL import Image from adafruit_ht16k33 import matrix matrix = matrix.Matrix8x8(board.I2C()) image = Image.open("myimage.png") matrix.image(image) ``` -------------------------------- ### Set Display Brightness Source: https://learn.adafruit.com/adafruit-led-backpack/0-8-8x8-matrix-circuitpython-and-python-usage Adjust the global brightness of the entire display using a value between 0 and 1.0. ```python matrix.brightness = 0.5 ``` -------------------------------- ### Set display blink rate Source: https://learn.adafruit.com/adafruit-led-backpack?view=all Configure the blink rate of the display using values between 0 and 3, where 3 is the slowest speed. ```python display.blink_rate = 3 ``` ```text 1 ``` ```python display.blink_rate = 3 ``` -------------------------------- ### Set custom I2C address for Seg7x4 Source: https://learn.adafruit.com/adafruit-led-backpack/0-dot-56-seven-segment-backpack-circuitpython-and-python-usage Passes an address parameter to Seg7x4 to use a non-default I2C address, such as 0x71 when the A0 pad is bridged. Addresses can range from 0x70 to 0x77. ```python display = Seg7x4(i2c, address=0x71) ``` -------------------------------- ### Display an ASCII character Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-9b21a470-83ad-459c-af02-209d8d82c462 Use the writeDigitAscii method to set a specific digit on the display to an ASCII character. ```auto alpha4.writeDigitAscii(0, 'A') ``` -------------------------------- ### Set display blink rate to slowest Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Sets the display blink rate to 3, which is the slowest blinking. Blink rate can be adjusted in increments between 0 and 3. ```python display.blink_rate = 3 ``` -------------------------------- ### Set AM/PM Indicator Source: https://learn.adafruit.com/adafruit-led-backpack/circuitpython-and-python-usage-197dcbfa-4ccf-4b98-a152-3982411df681 Use the ampm property to toggle the upper-right dot on the display. ```python display.ampm = True ``` -------------------------------- ### Shift Matrix Pixels with Looping Source: https://learn.adafruit.com/adafruit-led-backpack/0-8-8x8-matrix-circuitpython-and-python-usage Shift pixels with the loop parameter set to True to wrap pixels that move off the edge back to the other side. ```python matrix.shift(2, 0, True) # loop pixels to the right by 2 matrix.shift(-1, 0, True) # loop pixels to the left by 1 matrix.shift(0, -3, True) # loop pixels down by 3 matrix.shift(-2, 2, True) # loop pixels left by 2 and up by 2 ``` -------------------------------- ### Set left-side dots individually Source: https://learn.adafruit.com/adafruit-led-backpack/circuitpython-and-python-usage-197dcbfa-4ccf-4b98-a152-3982411df681 Use the top_left_dot and bottom_left_dot properties to toggle specific dots on or off. ```python display.top_left_dot = True display.bottom_left_dot = True ``` -------------------------------- ### Displaying the Colon with print Source: https://learn.adafruit.com/adafruit-led-backpack/0-dot-56-seven-segment-backpack-circuitpython-and-python-usage Use the print function to display a colon on the 7-segment display. ```python display.print("12:30") ``` -------------------------------- ### Set Individual Pixels Source: https://learn.adafruit.com/adafruit-led-backpack/bi-color-8x8-matrix-circuitpython-and-python-usage Treat the matrix object as a multidimensional list to set specific pixels to LED_RED, LED_GREEN, LED_YELLOW, or LED_OFF. ```python matrix[0, 0] = matrix.LED_RED matrix[4, 4] = matrix.LED_GREEN matrix[7, 7] = matrix.LED_YELLOW matrix[7, 0] = matrix.LED_OFF ``` -------------------------------- ### Print hexadecimal values to display Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Prints the hexadecimal value 0x1A2B to the display using the print_hex function. ```python display.print_hex(0x1A2B) ``` -------------------------------- ### Set individual characters on display Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Sets individual characters by treating the display object as a list and assigning values to indices 0 through 3. ```python display[0] = '1' display[1] = '2' display[2] = 'A' display[3] = 'B' ``` -------------------------------- ### Print numbers to display Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Prints the number 1234 to the display. Numbers can be printed without quotes, or as strings. ```python display.print(1234) ``` -------------------------------- ### Set bargraph LED color Source: https://learn.adafruit.com/adafruit-led-backpack?view=all Set the color of a specific LED on the bargraph using its index and color constant. ```cpp bar.setBar(lednumber,ledcolor); ``` -------------------------------- ### Scroll display manually Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Scroll displayed data to the left using the scroll() function, then manually update the right-most digit and call show() to apply changes. ```python display.print("A") display.scroll(2) display[3] = " " display.show() ``` -------------------------------- ### Display automatic scrolling marquee Source: https://learn.adafruit.com/adafruit-led-backpack/0-54-alphanumeric-circuitpython-and-python-usage Use the marquee function to display long strings. The default delay is 0.25 seconds, but it can be customized. ```python display.marquee("This is a really long string ") ``` -------------------------------- ### Fill Entire Bargraph Source: https://learn.adafruit.com/adafruit-led-backpack/bi-color-24-bargraph-circuitpython-usage Use the fill() function to set all segments of the bargraph to a specific color. ```python bc24.fill(bc24.LED_GREEN) ``` -------------------------------- ### Set left-side dots via colons property Source: https://learn.adafruit.com/adafruit-led-backpack/circuitpython-and-python-usage-197dcbfa-4ccf-4b98-a152-3982411df681 Control the left-side dots by setting index 1 of the colons property to True or False. ```python display.colons[1] = False ``` -------------------------------- ### Set Individual Bargraph Segments Source: https://learn.adafruit.com/adafruit-led-backpack/bi-color-24-bargraph-circuitpython-usage Control individual bars by treating the object as a list and assigning color constants like LED_RED, LED_GREEN, LED_YELLOW, or LED_OFF. ```python bc24[0] = bc24.LED_RED bc24[1] = bc24.LED_GREEN bc24[2] = bc24.LED_YELLOW bc24[3] = bc24.LED_OFF ``` -------------------------------- ### Set Individual Pixels Source: https://learn.adafruit.com/adafruit-led-backpack/0-8-8x8-matrix-circuitpython-and-python-usage Control specific pixels by treating the matrix object as a multidimensional list and setting the value to 1. ```python matrix[0, 0] = 1 matrix[4, 4] = 1 matrix[7, 7] = 1 ``` -------------------------------- ### Shift Matrix Pixels Source: https://learn.adafruit.com/adafruit-led-backpack/0-8-8x8-matrix-circuitpython-and-python-usage Shift pixels in various directions using the shift() function. Positive values shift right/up, while negative values shift left/down. ```python matrix.shift(2, 0) # shift pixels to the right by 2 matrix.shift(-1, 0) # shift pixels to the left by 1 matrix.shift(0, -3) # shift pixels down by 3 matrix.shift(-2, 2) # shift pixels left by 2 and up by 2 ``` -------------------------------- ### Controlling the Colon Property Source: https://learn.adafruit.com/adafruit-led-backpack/0-dot-56-seven-segment-backpack-circuitpython-and-python-usage Access the colon property directly to toggle the colon on or off. ```python display.colon = False ``` -------------------------------- ### Turn off segments on digit 3 Source: https://learn.adafruit.com/adafruit-led-backpack?view=all Use writeDigitRaw to turn off all LEDs on the third digit. ```cpp alpha4.writeDigitRaw(3, 0x0); ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.