Zillions of errors when used on incorrect architecture
- Dominant language
- C++
- Stars
- 226
- Forks
- 63
- PR merge metrics
- No merged PRs in 30d
Description
If a user includes TinyWireM.h in a sketch and builds for say an Uno board, they will get tons of errors.
They can easily be confused and not recognize the issue. (I have seen this first hand)
The current library.properties says the library works on any architecture.
The properties files should indicate that it is AVR only.
But even specifying that the library architecture is AVR only does not fully solve the issue.
So to fully remedy the issue, TinyWireM.h should also use conditionals to explicitly check the processor type being used and crash the compile with a meaningful error message when attempting to use it on an unsupported processor.
Even better would be to work with the Attiny core maintainer and get this library into to actual core so that it is only available when that tiny core type is being used.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reading library.properties and TinyWireM.h, then reproduce the build for an Uno board to observe the current errors. Update the architecture metadata and add an explicit unsupported-processor check so the build reports a meaningful error; confirm the supported Tiny core build still works and the unsupported build fails clearly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- arduino, cpp
- Domain
- embedded-iot
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100