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.
Dependencies: NDefLib X_NUCLEO_NFC02A1 hdc1080 mbed
Fork of HelloWorld_NFC02A1 by
Diff: main.cpp
- Revision:
- 9:0bd2f0c13d3d
- Parent:
- 8:9bdd16ebccfb
- Child:
- 11:d0665d9c28a6
diff -r 9bdd16ebccfb -r 0bd2f0c13d3d main.cpp
--- a/main.cpp Fri Sep 30 11:46:24 2016 +0000
+++ b/main.cpp Mon Oct 03 11:58:00 2016 +0000
@@ -43,8 +43,6 @@
#include "NDefLib/NDefNfcTag.h"
#include "NDefLib/RecordType/RecordURI.h"
-#if 0
-/*----------------------------------------------------------------------------*/
static volatile bool buttonPress=false; // true when the user press the message
static void setButtonPress(){
@@ -83,8 +81,6 @@
printf("Error open read Session\n\r");
}
}
-/*----------------------------------------------------------------------------*/
-#endif
/**
* Write a Ndef URI message linking to st.com site.
@@ -145,9 +141,8 @@
}
else
printf("Error opening the session\n\r");
-
-#if 0
-/*----------------------------------------------------------------------------*/
+
+#if defined(TARGET_STM)
/* enable the button */
InterruptIn mybutton(USER_BUTTON);
@@ -163,9 +158,9 @@
buttonPress=false;
}
}
-/*----------------------------------------------------------------------------*/
+#else
+ readAndPrintNfcTag(tag);
#endif
-
}
