Fix compiler warning

Cast array to const array. Syntax is awkward but correct.

Note: this is part of PX4 mavlink compiler warning cleanup.