-
Notifications
You must be signed in to change notification settings - Fork 212
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix sanity checks for new CFG_sx1276_radio boards #790
base: master
Are you sure you want to change the base?
Conversation
Since they changed the silicon ID, I conclude that there are other changes we have to take into account. The LMIC should record the silicon ID for easy reference at this point; and we must review the LMIC to determine whether other changes are needed. See, for example, #787, which is possibly related. I'd rather not make this change until the review has been done; and I have no time to review, nor hardware that has this value in the registers. Deferring. |
Turns out, not related. The datasheet with the change still shows 0x12 as the chip id. Google search indicates that the differences between 0x12 and 0x13 are not yet documented. More info is needed. |
I checked today on Semtech's site and there's still not an updated datasheet with the new chip ID. |
@@ -1109,7 +1109,7 @@ int radio_init () { | |||
// some sanity checks, e.g., read version number | |||
u1_t v = readReg(RegVersion); | |||
#ifdef CFG_sx1276_radio | |||
if(v != 0x12 ) | |||
if(v != 0x12 & v != 0x13) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if(v != 0x12 & v != 0x13)
:
This should be &&
, not &
. Or else if ((v & ~1u) == 0x12)
, which might be smaller on AVR. Ideally, this would be a macro or inline check: if (is_sx1276_like(v))
, where is_sx1276_like()
looks at v
and makes the decision.
We've not heard more on this since the last few years; has Semtech documented this? Or is this not relevant after all?
No description provided.