Example code to set registers in the TMC2208 stepper driver

part of the problem is that these boards are all slightly different, and there is no documentation. It says there is a jumper that needs to be closed, for instance. On my board there is no jumper. There are also separate pins for the PDN and UART. Not a single pin for them both. It's not clear what I should do with the PDN pin.

The combination and possibilities of things that could be going wrong quickly escalate at each stage where more uncertainty is added, and the whole situation quickly becomes intractable.