Reading the ADC with Xojo

I would like to read the A/D converter on the Automation Hat from Xojo programming language. I can activate the relays just fine, but would also like to get analog values. Anybody done this or know how? Also, I’d like to control the Power, COMMS and Warn LEDs. What pin are they on?

The pinout is here, https://pinout.xyz/pinout/automation_hat# . Those LEDs must be controlled via i2c? Or the onboard firmware?