A Compute Blade’s pins and settings for an Acorn

This page is for someone with an Acorn wired to a Compute Blade with a CM4 or CM5. It lists what each pin of the two headers is and what the blade must have set for the serial pair. It also says where the kernel console must not be.

Why JTAG and the serial pair share a line is on The line JTAG and the serial port share on a Compute Blade.

How JTAG is run on a blade is on How to run JTAG by hand on an Acorn on a Compute Blade. Which wire goes where is on Acorn wiring on a Compute Blade.

The blade’s connectors and their GPIOs

Each row of the table is a connector of the blade, the GPIOs it carries and its pins.

Connector

GPIOs

Pins

Extension Port (2×5)

GPIO2, GPIO3, GPIO4, GPIO14, GPIO15

printed 1-10

UART (1×4), beside the Extension Port

GPIO14, GPIO15

printed 1-4

UART Front (3-pin)

GPIO14, GPIO15

TX, RX, GND

Fan Unit (4-pin)

GPIO12, GPIO13

PWM0/UART5-TX, PWM1/UART5-RX

Not brought out

GPIO8-11 (SPI0)

none

GPIO14 and GPIO15 are the same lines at every connector that carries them. The vendor’s GPIO table lists GPIO14 at “Expansion Module Port, UART Front(3pin), UART Back(4pin)” as “UART0 TX”, and GPIO15 at the same three as “UART0 RX”. GPIO2 and GPIO3, which carry TDI and TDO here, are also SDA1 and SCL1.

Each row of the next table is one Extension Port pin by printed number: silkscreen, GPIO, matching Pi header pin and wire.

Pin

Silkscreen

GPIO

Same pin on a Raspberry Pi header

Same GPIO as

Wire

1

3.3V

—

1

—

empty

2

IO2

GPIO2 (I2C1_SDA)

3

—

P1:5 TDI

3

IO3

GPIO3 (I2C1_SCL)

5

—

P1:3 TDO

4

IO4

GPIO4 (GPCLK0)

7

—

P1:2 TCK

5

GND

—

9

—

empty

6

5V

—

2

—

empty, 5 V

7

5V

—

4

—

empty, 5 V

8

GND

—

6

—

P1:1 GND

9

IO14

GPIO14 (TXD0)

8

UART 3

P1:4 TMS

10

IO15

GPIO15 (RXD0)

10

UART 4

empty

Each row of the next table is one pin of the UART header by printed number. The 5 V pin can be an input or an output (vendor note), so it is live whenever the blade is powered.

Pin

Silkscreen

GPIO

Same GPIO as

Wire

1

5V

—

—

empty, 5 V

2

GND

—

—

P2:1 GND

3

TX

GPIO14 (TXD0)

Extension Port 9

P2:3 J2

4

RX

GPIO15 (RXD0)

Extension Port 10

P2:2 K2

The serial port

Each row of the table is one wire of the serial pair, a null-modem crossover: the end that transmits lands on the receiver of the other end.

Wire

Transmits

Lands on the host’s

K2

the FPGA

receiver, GPIO15 / RXD0

J2

the host

transmitter, GPIO14 / TXD0

Each row of the next table is a setting of the header’s serial port and its value.

Setting

Value

Device

/dev/ttyAMA0

Baud rate

115200

Overlay on a CM5

none: enable_uart=1 gives /dev/ttyAMA0

Pre-test

systemctl stop serial-getty@ttyAMA0

Each row of the next table is a state of the header’s serial port and what JTAG and the serial pair do in it.

Kernel

Header serial port

/dev/ttyAMA0

JTAG on GPIO14

6.18

on (enable_uart=1)

present

cannot run: the kernel’s serial driver holds GPIO14

6.18

off

absent

ran on the one blade it was tried on (test-designs issue #213)

6.12.75

on

present

ran, and then the serial pair was used in the same boot

Warning

Never drive a Pi GPIO against an FPGA output. With the pin-ID design loaded, every P2 ball is an FPGA output, J2 included. Setting GPIO14 to a4 (TXD0) or op while pin-ID runs is then output against output on the J2 wire, and it crashes the Pi. Probe with pinctrl set 14 ip pn (input, no pull). Restore pinctrl set 14 a4 only once a design that treats J2 as an input is loaded.

Kernel console on the FPGA UART

Warning

The kernel console must not be on the FPGA’s UART. It is there when the kernel command line has console=ttyAMA0, or console=serial0 on a host whose header UART is enabled. Then loading any design that drives serial TX reboots or crashes the host.

Those designs are the UART SoC, pin-ID and the GPIO loopback. The FPGA drives K2 at its own baud rate, 1200 for pin-ID and 115200 for the UART SoC. The console reads those bytes as garbage, and some of them are SysRq commands: reboot(b), crash(c), poweroff(o), kill-all-tasks(i).

Each row of the table is a kernel setting that keeps the console off the FPGA’s UART, and where it is set. Check them on every host you set up and on a host that has been reinstalled.

Host

Setting

Set in

Compute Blade

console=tty1

the kernel command line

Raspberry Pi 5

console=ttyAMA10 (the debug connector); the getty that systemd derives from the console lands there too

[pi5] cmdline=cmdline-pi5.txt

Either

kernel.sysrq=0

the kernel command line or /etc/sysctl.d/

When a wire does not answer: Acorn wiring faults on a Compute Blade.