Merge pull request #9 from slepp/id-test

Check for 0x3AC or 0x32C in testConnection().
This commit is contained in:
Nigel VH 2015-07-05 16:52:26 -07:00
commit efca76806c
1 changed files with 3 additions and 2 deletions

View File

@ -286,8 +286,9 @@ void HamShield::initialize() {
*/
bool HamShield::testConnection() {
I2Cdev::readWord(devAddr, 0x09, radio_i2c_buf);
// 03ac or 032c
return radio_i2c_buf[0] == 0x03AC; // TODO: find a device ID reg I can use
// TODO: find a device ID reg I can use
// 03ac or 032c
return (radio_i2c_buf[0] == 0x03AC || radio_i2c_buf[0] == 0x32C);
}