Skip to content
This repository was archived by the owner on Jun 8, 2023. It is now read-only.

Commit cc0122c

Browse files
committed
Allow code to compile on esp8266
1 parent 7115cad commit cc0122c

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/MCP2515.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,9 @@ void MCP2515Class::onReceive(void(*callback)(int))
265265
pinMode(_intPin, INPUT);
266266

267267
if (callback) {
268+
#ifndef ESP8266
268269
SPI.usingInterrupt(digitalPinToInterrupt(_intPin));
270+
#endif
269271
attachInterrupt(digitalPinToInterrupt(_intPin), MCP2515Class::onInterrupt, LOW);
270272
} else {
271273
detachInterrupt(digitalPinToInterrupt(_intPin));

0 commit comments

Comments
 (0)