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.
Revision 0:786b75c6aaca, committed 2011-03-29
- Comitter:
- Kemp
- Date:
- Tue Mar 29 13:42:16 2011 +0000
- Child:
- 1:883b8bc1f54a
- Commit message:
Changed in this revision
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
| mbed.bld | Show annotated file Show diff for this revision Revisions of this file |
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp Tue Mar 29 13:42:16 2011 +0000
@@ -0,0 +1,38 @@
+#include "mbed.h"
+
+
+Serial pc(USBTX, USBRX);
+
+extern "C" void HardFault_Handler()
+{
+ pc.printf("Hard fault!\r\n");
+ exit(1);
+}
+
+
+void fail()
+{
+ pc.printf("Caught the failure\r\n");
+ exit(1);
+}
+
+
+class Test
+{
+ public:
+ int something;
+ char woot[28];
+};
+
+
+int main() {
+ Test *dummy;
+ int index = 0;
+
+ while(1) {
+ dummy = new Test;
+ if (dummy == NULL) fail();
+ pc.printf("%u\r\n", index);
+ ++index;
+ }
+}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Tue Mar 29 13:42:16 2011 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/63bcd7ba4912