Main Menu

Menu

Tuesday 3 January 2012

MCP9800 Temp.Sensor in Android via mbed MicroBridge

In this project I am reading the temperature of the Microchip MCP9800 temperature sensor via mbed Microbridge in the Thunder Board running Android 2.2 Froyo.
The mbed NXP1768 is behaving like a host. In this project we see how we can communicate from the external PIC (NXP1768) with an Android System.
We want the program (mbed project) for the communication of the NXP1768 with the MCP9800 sensor, the same project implements the MicroBridge with the Android System and finally in the side of the Android we have the application which communicates with the NXP1768 and displays the info in the screen.
The photos below present this project.
The side of mbed.

The side of Android.

The application.


The Adb  (USB) connection between Android and mbed via MicroBridge.

The desktop of Android with the MicroBridge Application.
Here are the necessary files-projects-application for this project:
http://www.multiupload.com/XV7M8J939X.
The zip file contains the application (Eclipse Project file) for the Android and the mbed NXP1768 project.
I forgot to mention that for the side of the mbed you will need the MCP9800 sensor to be connected in pin9 and pin10 (I2C communication) in the mbed. The sensor needs pull-up resistors. I used 4.1K Ohms. One in the SDA and the other in the SCL of the sensor, they are going at 5 V dc voltage. Finally I used the D+ and D- of the mbed board (NXP1768) connected with a Sparkfun mini usb breakout which then is connected with the ADB USB OTG port of the Android System (Thunder board in my project from TechNexion).
The sensor is measuring the temperature with 3 decimal digits (ex. 23.567) but I am sending integer at the Android, so it is displaying only the 23 for example.
Maybe one of the next implementations will be the reading of float numbers through the mbed MicroBridge.

1 comment: