Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: check_revision.cpp
- Revision:
- 0:564965644ed2
diff -r 000000000000 -r 564965644ed2 check_revision.cpp
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/check_revision.cpp Fri Aug 07 05:43:59 2020 +0000
@@ -0,0 +1,27 @@
+/*
+ * Check Mbed revision
+ *
+ * Copyright (c) 2019,'20 Kenji Arai / JH1PJL
+ * http://www7b.biglobe.ne.jp/~kenjia/
+ * https://os.mbed.com/users/kenjiArai/
+ * Created: July 17th, 2019
+ * Revised: August 1st, 2020
+ */
+
+#include "mbed.h"
+
+// RUN ONLY ON mbed-os-6.2.0
+// https://github.com/ARMmbed/mbed-os/releases/tag/mbed-os-6.2.0
+#if (MBED_MAJOR_VERSION == 6) &&\
+ (MBED_MINOR_VERSION == 2) &&\
+ (MBED_PATCH_VERSION == 0)
+#else
+# error "Please use mbed-os-6.2.0"
+#endif
+
+void print_revision(void)
+{
+ printf("MBED_MAJOR_VERSION = %d, ", MBED_MAJOR_VERSION);
+ printf("MINOR = %d, ", MBED_MINOR_VERSION);
+ printf("PATCH = %d\r\n", MBED_PATCH_VERSION);
+}