Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
6 years, 11 months ago.
MBED-OS VERSION NUMBER
Hello, I've downloaded mbed-os v5.7 . How can I print os version number in runtime? is mbed-os code compatible with ARMCC v6? Will there be an export to uvision / ARMCCv6 ?
Thanks, ilkay KOZAK
1 Answer
6 years, 11 months ago.
Here's what I do. It only works on "official" releases. If you get an intermediate build, the compiler returns errors
#define DOBLUE "\033[0;34;2m" #define DORED "\033[0;31;2m" #define DONONE "\033[0m" //in your code pc.printf("mbed-os-rev: %s%d.%d.%d%s lib-rev: %s%d%s\r\n", DOBLUE, MBED_MAJOR_VERSION, MBED_MINOR_VERSION, MBED_PATCH_VERSION, DONONE, DOBLUE, MBED_LIBRARY_VERSION, DONONE);
...kevin