Integer literals starting with 0x is hexadecimal (base 16).
Integer literals starting with just 0 is octal (base 8).
Integer literals starting with any non-zero digit 1-9 is decimal (base 10).
this is, by the way, horrible code.
the function uses pointers to replace references (pass by reference) and constant integers are formed with convoluted and undocumented math for no apparent reason.
Likely the hardware manual for this system can demystify some of the why & what here, but even so, it could stand a few comments.