Skip to content

Use PDLS with the EXT4 extension board

This technical note details how to use PDLS with the EXT4 extension board.

Danger

When the EXT4 extension board is connected to the main controller board, ensure only one power source is used.

Either through the USB cable:

  • Remove the two CR2450 batteries, and
  • Power the main controller board and the EXT4 through the USB cable;

or with the two CR2450 batteries:

  • Disconnect the USB cable, and
  • Power the main controller board and the EXT4 with the two CR2450 batteries.

EXT4 extension board

The EXT4 extension board is specifically designed to be used as an Internet of Thing, or IoT, device.

It features the circuit for a small e-paper display with a panel power control circuit, an RGB LED, a button, an 3-axis accelerometer, a temperature and humidity sensor, a passive NFC, a Flash SPI memory and pads for an optional SPI memory.

Warning

The EXT4 extension board requires the panelPower signal, as the power control circuit is normally off.

Board configuration

Driving an e-paper display through the EXT4 extension board requires a minimum of 9 signals, and up to 20 signals with all the sensors and interrupts, RGB LED and external memory.

Signal Minimal Sensors Optional
Power +3.3V, Ground
SPI bus Clock, Data in Data out
Panel Select, Reset, Busy,
Data/Command, Power
Flash Select, Second select
I²C bus Clock, Data
RGB LED Data
Sensors Interrupts x5
Total 9 2 9

The standard board definition of PDLS can be used with the EXT4 extension board, with three major differences compared to EXT3.1 extension board:

  • panelPower in pin  20  is required, as the EXT4 extension board features a panel power control circuit, normally off;

  • panelCSS is not available, as the EXT4 extension board drives only small panels;

  • touchIn and touchReset are not available, as the EXT4 extension board does not support touch.

Like for the EXT3.1 extension board, the flashCSS signal in pin  15  is optional, as the EXT4 extension board provides pads for a second external SPI memory, Flash or SRAM.

Connector

The EXT4 extension board features a 2x10-way connector.

Pins 1 to 10 are compatible with the EXT3 and EXT3.1 extension boards.

Variable Number Signal Type Function
 1  VCC +3.3V P Power Supply
 2  SPI SCK SPI SPI clock
.panelBusy  3  Panel !BUSY O Panel busy signal
.panelDC  4  Panel D/C I Panel Data/Command control
.panelReset  5  Panel /RESET I Panel reset
 6  SPI MISO SPI SPI MISO
 7  SPI MOSI SPI SPI MOSI
.flashCS  8  Flash /CS I Flash chip select
.panelCS  9  Panel /CS I Panel chip select
 10  Ground P Ground

Pins 11 to 20 are specific to the EXT4 extension board. All the signals are new, except the second SPI memory chip select.

Variable Number Signal Type Function
.panelPOWER  11  P_POWER I MOSFET for panel power control
 12  SWITCH O Switch position
 13  LED_DATA I WS2813C data signal
 14  I2C_SDA I²C I²C data signal, bi-directional
 15  I2C_SCL I²C I²C clock signal
.flashCSS  16  F_CS2 I Second SPI memory chip select
 17  NFC_FD O NT3H2111 field detect interrupt
 18  IMU_INT1 O LIS2DH12 first interrupt
 19  IMU_INT2 O LIS2DH12 second interrupt
 20  RHT_INT O HDC2080 interrupt
Type
  • P = power
  • O = output
  • I = input
  • SPI = serial peripheral interface
  • I²C = inter-integrated circuit

The SPI bus connects the screen, Flash memory and optional second memory. The SPI MISO signal is used as SDIO to read the OTP memory. Pull-up resistors on the chip select lines maintain the Flash memory and the optional second memory unselected.

The I²C bus connects the HDC2080 temperature and relative humidity sensor, the LIS2DH12 3-axis accelerometer, and the NT3H2111 passive NFC controller.

Screens

The EXT4 extension board and the dedicated variant PDLS_EXT4_Basic_Matter support the screens with wide temperature and embedded fast update (film K) up to 2.90”, as described in the specific procedure.

Note

The dedicated variant PDLS_EXT4_Basic_Matter does not support the colour black-white-red-yellow screens (film Q). Use the general procedure instead.

Sensors

The PDLS library does not manage the I²C sensors, the button or the addressable RGB LED. However, it exposes the interrupt signals of the I²C sensors, the button and the addressable RGB LED.

Reference Manufacturer Function
LIS2DH12 STMicroelectronics MEMS digital output motion sensor: ultra-low-power high-performance 3-axis “femto” accelerometer
NT3H2111 NXP NTAG I²C plus 1K, NFC Forum Type 2 Tag with I²C interface
MX25R8035F Macronix Ultra Low Power 1M-bit Flash memory
HDC2080 Texas Instruments Ultra-low-power digital relative humidity sensor with interrupt
Not populated Pads for second SPI external memory
WS2813C World Semi Low power addressable RGB LED

Configure

The EXT4 extension board requires the panelPower in pin  11 , as the power control circuit is normally off.

The general procedure is valid for all the editions and all the variants.

The specific procedure relies on a variant of the PDLS Basic edition, PDLS_EXT4_Basic_Matter, aimed at the E-Paper Development Kit for Matter (EPDK-Matter) and monochrome screens with wide temperature and embedded fast update.

General procedure

This is the recommended procedure for the colour black-white-red-yellow screens (film Q) on the EXT4 extension board.

There are three options to define the panel power pin.

  • Edit the board definition on the hV_List_Boards.h header file.

  • Define a specific board on the main program and set .panelPower.

Example

This example shows a modified board definition, to be adapted to the specific main controller board.

const pins_t myBoardEXT4 =
{
    .panelBusy = 13, ///< EXT4 pin 3 Red
    .panelDC = 12, ///< EXT4 pin 4 Orange
    .panelReset = 11, ///< EXT4 pin 5 Yellow
    .flashCS = 10, ///< EXT4 pin 8 Violet
    .panelCS = 17, ///< EXT4 pin 9 Grey
    .panelCSS = NOT_CONNECTED, ///< Signal not available
    .flashCSS = 15, ///< EXT4 pin 15 Green2, optional
    .touchInt = NOT_CONNECTED, ///< Signal not available
    .touchReset = NOT_CONNECTED, ///< Signal not available
    .panelPower = 16, ///< EXT4 pin 11 White2, required
    .cardCS = NOT_CONNECTED, ///< Separate SD-card board
    .cardDetect = NOT_CONNECTED, ///< Separate SD-card board
};

// Screen
#include "PDLS_EXT3_Basic_Wide.h"
Screen_EPD_EXT4_Fast myScreen(eScreen_EPD_290_KS_0F, myBoard);
  • Use the standard board definition and specify the panel power pin at run-time.
// Screen
#include "PDLS_EXT3_Advanced_Wide.h"
Screen_EPD_Fast myScreen(eScreen_EPD_271_KS_09, boardArduinoNanoMatter);

myScreen.setPanelPowerPin(16);
myScreen.begin();

setPanelPowerPin() defines the pin used for panel power.

The required parameter is

  • the GPIO or pin number for the panel power signal.

Warning

The setPanelPowerPin() function should always be called before begin() so the panel power pin is initialised.

Specific procedure

The dedicated variant PDLS_EXT4_Basic_Matter of the PDLS Basic edition targets the E-Paper Development Kit for Matter (EPDK-Matter) and monochrome screens with wide temperature and embedded fast update (film K).

This is the recommended procedure for the monochrome screens with wide temperature and embedded fast update (film K) on the EXT4 extension board.

It includes a specific board definition for the EXT4 extension board which lists all the GPIOs.

///
/// @brief Arduino Nano Matter with Silicon Labs MGM240P, tested
/// @details Variant of boardArduinoNanoMatter with panelPower, button and LED for EXT4
/// @note Numbers refer to pins
/// @note Recommended board
///
const pins_t boardArduinoNanoMatter =
{
    .panelBusy = 10, ///< EXT3, EXT3.1 and EXT4 pin 3 Red -> D10
    .panelDC = 9, ///< EXT3, EXT3.1 and EXT4 pin 4 Orange -> D9
    .panelReset = 8, ///< EXT3, EXT3.1 and EXT4 pin 5 Yellow -> D8
    .flashCS = 7, ///< EXT3, EXT3.1 and EXT4 pin 8 Violet -> D7
    .panelCS = 6, ///< EXT3, EXT3.1 and EXT4 pin 9 Grey -> D6

    .panelCSS = NOT_CONNECTED, ///< EXT4 not available
    .flashCSS = 5, ///< EXT3 pin 20 or EXT3.1 pin 11 Black2; EXT4 pin 16 Yellow2 -> D5
    .touchInt = NOT_CONNECTED, ///< EXT3-Touch pin 3 Red
    .touchReset = NOT_CONNECTED, ///< EXT3-Touch pin 4 Orange
    .panelPower = 2, ///< EXT4 pin 11 White -> D2
    .cardCS = NOT_CONNECTED, ///< Separate SD-card board
    .cardDetect = NOT_CONNECTED, ///< Separate SD-card board

    // EXT4 specific
    .button = 3, // EXT4 pin 12 Grey -> D3
    .ledData = 4, // EXT4 pin 13 Violet WS2813C -> D4
    .nfcFD = 17, // EXT4 pin 17 Orange NFC NT3H2111_2211 !Field detect, I2C address = 0x55 -> A3
    .imuInt1 = 16, // EXT4 pin 18 Red LIS2DH12 !INT1, I2C address = 0x19 -> A2
    .imuInt2 = 15, // EXT4 pin 19 Brown LIS2DH12 !INT2, I2C address = 0x19 -> A1
    .weatherInt = 14, // EXT4 pin 20 Black HDC2080 !INT, I2C address = 0x40 -> A0
    // End of EXT4 specific
};

The specific board definition requires to set USE_EXT_BOARD to BOARD_EXT4 on the hV_List_Options header file, as described at Parameters.

#define USE_EXT_BOARD BOARD_EXT4 ///< Selected board

The general procedure mentioned above remains valid for the E-Paper Development Kit for Matter (EPDK-Matter) and monochrome screens with wide temperature and embedded fast update (film K).

#include "PDLS_EXT4_Basic_Matter.h"
pins_t myBoard = boardArduinoNanoMatter;
Screen_EPD_EXT4_Fast myScreen(eScreen_EPD_290_KS_0F, myBoard);

The variable myBoard provides an easy access to other signals, like myBoard.ledData to drive the RGB LED or myBoard.button to read the button.

Use

Use the screen like any other.


Next