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: main.cpp
- Revision:
- 1:ba9bd888e526
- Parent:
- 0:09641ab44f00
--- a/main.cpp Tue Dec 02 01:17:26 2014 +0000 +++ b/main.cpp Tue Dec 02 03:57:43 2014 +0000 @@ -1,15 +1,23 @@ +/** I2C_FmPlus library + * + * @class I2C_FmPlus + * @author tedd + * @version 1.0 + * @date 02-Dec-2014 + */ + #include "mbed.h" #include "I2C_FmPlus.h" // I2C i2c( p28, p27 ); I2C_FmPlus i2c( p28, p27 ); -int main() { +int main() +{ char v[] = { 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07 }; char target_address = 0xC0; - - i2c.frequency( 1100 * 1000 ); -// i2c.scl_setting( 25, 25 ); + + i2c.frequency( 1000 * 1000 ); while(1) { i2c.write( target_address, v, sizeof( v ) );