I’d love a solution to this but everything I’ve read implies that this API wasn’t meant for strings. Questionable lifetime wrt a memory leak.
Instead you can use SimConnect within the gauge, the same way this is done externally (AddToDataDefintion etc). The only problem is you can only read A: vars and not C:fs9gps: or L: vars.