[OpenTRV-dev] SPI speed and REV1 crashes

Damon Hart-Davis damon at opentrv.uk
Tue Sep 22 13:15:16 BST 2015


We’ve had some mysterious crashes, mainly on REV1 (though some also on REV9, now avoided), that I had blamed on used of the AVR’s IDLE mode.

Further thinking and help from Bo suggests it may more boringly be the LED on the SPI_SCK pin, so experimentally I’ve slowed down SPI (basic clocking, and around the select line).

OpenTRV and OTRadioLink now have a tag:


with that in place.

The problem mainly shows up with a REV1 in RX mode (stats or boiler hub) because it has to poll furiously (IRQ is not available); typically the board resets after ~30 minutes (variable).  I suspect that it is a problem on REV1 because of that SCK LED and because of thinner tracks on the board.

I have done some limited testing and the change doesn’t seem to make things worse.

It is possible to adjust the SPI speed at compile time, so that we could have full speed on REV2, but my inclination if this works is to leave us the extra safety/noise/speed margin on the newer boards too.



More information about the OpenTRV-dev mailing list