ardupilot/libraries/Desktop/support/ultoa_invert.c
Andrew Tridgell 4109374959 first rough build for desktop CPUs
this allows ArduPlane to build and startup on 'desktop' systems (eg. a
Linux box). Very rough for now, and only for HIL so far
2011-10-09 22:16:13 +11:00

13 lines
227 B
C

#include <stdio.h>
char * __ultoa_invert(unsigned long val, char *s, int base)
{
switch (base) {
case 8:
return s+sprintf(s, "%lo", val);
case 16:
return s+sprintf(s, "%lx", val);
}
return s+sprintf(s, "%lu", val);
}