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

RPI2040 using Wire1 instead of Wire #64

Open
wsandor opened this issue Jan 2, 2023 · 0 comments
Open

RPI2040 using Wire1 instead of Wire #64

wsandor opened this issue Jan 2, 2023 · 0 comments
Assignees

Comments

@wsandor
Copy link

wsandor commented Jan 2, 2023

Hi,

I've tried your library on RPI2040. RPI2040 has 2pc of 2wire interfaces, and unfortunately the MCP7940 is connected to the i2c1 (Wire1) interface on my board, so it won't worked as Wire is hard wired in the library.
I've modified the code to be able to use Wire1 also. Now it can be set as an optional parameter to the MCP7940_Class constructor: MCP7940_Class MCP7940(&Wire1); // Create an instance of the MCP7940

Here are my modified files, include them in the next version if you find it useful:
MCP7940.cpp.txt
MCP7940.h.txt

One more problem:
It could be some configuration problem, but for some reason PlatformIO sees only and downloads version 1.2.0 of the library instead of the newest one.

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

No branches or pull requests

2 participants