Demo application of SNICInterface library for Murata TypeYD, which reports sensor data periodically to Xively cloud server . Hardware platform: mbed application board (https://mbed.org/cookbook/mbed-application-board), mbed LPC1768 (https://mbed.org/platforms/mbed-LPC1768/) and TypeYD.
Dependencies: C12832 LM75B MMA7660 SNICInterface libxively mbed-rtos mbed
Revision 25:39099b3b173f, committed 2014-09-19
- Comitter:
- kishino
- Date:
- Fri Sep 19 01:46:21 2014 +0000
- Parent:
- 24:3d150ff59276
- Child:
- 26:b666d1b66f62
- Commit message:
- It was supported to the FRDM-KL46Z platform.
Changed in this revision
| SNICInterface.lib | Show annotated file Show diff for this revision Revisions of this file |
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/SNICInterface.lib Fri Sep 12 00:28:16 2014 +0000 +++ b/SNICInterface.lib Fri Sep 19 01:46:21 2014 +0000 @@ -1,1 +1,1 @@ -http://mbed.org/teams/murata/code/SNICInterface/#1c1b5ad4d491 +http://mbed.org/teams/murata/code/SNICInterface/#17d89443d899
--- a/main.cpp Fri Sep 12 00:28:16 2014 +0000
+++ b/main.cpp Fri Sep 19 01:46:21 2014 +0000
@@ -36,10 +36,10 @@
C12832 lcd(p5, p7, p6, p8, p11);
MMA7660 axl(p28, p27);
LM75B tmp(p28, p27);
-#elif defined(TARGET_LPC1549)
+#elif defined(TARGET_KL46Z)
C12832 lcd(D11, D13, D12, D7, D10);
-MMA7660 axl(SDA, SCL);
-LM75B tmp(SDA, SCL);
+MMA7660 axl(I2C_SDA, I2C_SCL);
+LM75B tmp(I2C_SDA, I2C_SCL);
#endif
#include "logo.h"
@@ -52,10 +52,8 @@
/** Wi-Fi SNIC UART Interface*/
#if defined(TARGET_LPC1768)
C_SNIC_WifiInterface mSNICwifi( p9, p10, NC, NC, p30 );
-Serial pc(USBTX, USBRX); /* for DEBUG_PRINT */
-#elif defined(TARGET_LPC1549)
-C_SNIC_WifiInterface mSNICwifi( D0, D1, NC, NC, D3 );
-Serial pc(P2_12, P2_11); /* for DEBUG_PRINT */
+#elif defined(TARGET_KL46Z)
+C_SNIC_WifiInterface mSNICwifi( D1, D0, NC, NC, D3 );
#endif
int main() {
@@ -63,7 +61,9 @@
#if defined(TARGET_LPC1768)
PHY_PowerDown();
#endif
+#ifdef _DEBUG
pc.baud( 115200 );
+#endif
DEBUG_PRINT("main\r\n");
lcd_print_xively_logo();
muRata
Murata TypeYD