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: DevI2C/DevI2C.h
- Revision:
- 2:c1cac955d4bd
- Parent:
- 1:ca975408dd4e
- Child:
- 3:bc5fc631e9c5
--- a/DevI2C/DevI2C.h Thu Apr 02 13:23:09 2015 +0200 +++ b/DevI2C/DevI2C.h Tue Apr 14 15:32:06 2015 +0200 @@ -80,11 +80,7 @@ ret = write(DeviceAddr, (const char*)tmp, NumByteToWrite+1, 0); - if(ret) { - error("%s: dev = %d, reg = %d, num = %d\n", - __func__, DeviceAddr, RegisterAddr, NumByteToWrite); - return -1; - } + if(ret) return -1; return 0; } @@ -111,11 +107,7 @@ ret = read(DeviceAddr, (char*)pBuffer, NumByteToRead, 0); } - if(ret) { - error("%s: dev = %d, reg = %d, num = %d\n", - __func__, DeviceAddr, RegisterAddr, NumByteToRead); - return -1; - } + if(ret) return -1; return 0; } };