Skip to content
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

MCP_CAN on ESP8266 NodeMCU - SPI not correct? #13

Open
mega-hz opened this issue Jan 14, 2017 · 2 comments
Open

MCP_CAN on ESP8266 NodeMCU - SPI not correct? #13

mega-hz opened this issue Jan 14, 2017 · 2 comments

Comments

@mega-hz
Copy link

mega-hz commented Jan 14, 2017

Hello,

on an Arduino Uno i succesfully realized a MCP2515 Shield running perfectly.
Now i am using a ESP8266 with the following SPI Devices:
1x IL9341 TFT, 1x 74HC595 Expander (4x74HC595) and an MCP2515 CAN BUS Shield.

TFT is working fine, also the 74HC595's , the MCP2515 works fine also,
BUT: There is a problem using the 74HC595 AND the MCP2515 together!
If i don't use the MCP, the 74HC595 are working fine, if the MCP2515 is also running, there are always flickering (on the output-LEDs) of the 74HC595!
I can fix it with using spi.begin and spi.end in the 74HC595 Part, but then the MCP is not working anymore!
Is there something missing initializing the SPI on the MCP_CAN Library?
It would be the right way for a spi-device to begin and end, but the mcp_can seems not to do so!

Please can you help me?

regards,
Wolfram.

@coryjfowler
Copy link
Contributor

If either of your SPI peripherals are using an SPI mode other than 00, you will need to switch it back before doing any CAN instructions. The begintransaction() and endtransaction() functions are relatively new to the Arduino IDE code set and not necessary in most cases. They will be added to the library in the future.

@mega-hz
Copy link
Author

mega-hz commented Jan 17, 2017

thanx,
i use different io's for the shift-register, no spi.
now it works!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants