R-Car/CPLD

Introduction
Certain Renesas boards contain a CPLD, which can be accessed both from the SoC and via the USB-serial FTDI chip. The CPLD allows restarting the board and provides various status registers, like the MD pin status. These boards which contain the CPLD are at least the ULCB and H2 Stout boards.

To access the CPLD from U-Boot, use the 'cpld' command on U-Boot prompt.

To access the CPLD via the USB-serial adapter, use the cpld-control tool.

cpld-control
The cpld-control tool allows accessing the CPLD via the USB-serial FTDI chip on the board. The tool uses USB iSerial to identify the specific FTDI on the board. Use the following to list all available FTDIs:

$ cpld-control -l

To dump CPLD registers, use:

$ cpld-control -d  Using device with iSerial: ... CPLD version:                  0xff: 0x20160923 Mode setting (MD0..28):        0x00: 0x00218128 Multiplexer settings:          0x02: 0x0000000e DIPSW (SW6):                   0x08: 0x0000000f

To reset the board, use: $ cpld-control -w  0x80 0x1 Using device with iSerial: ... Writing register 0x80 with value 0x00000001 CPLD version:                  0xff: 0x20160923 Mode setting (MD0..28):        0x00: 0x00218128 Multiplexer settings:          0x02: 0x0000000e DIPSW (SW6):                   0x08: 0x0000000f