Checking for known conflicts

8 views
Skip to first unread message

Paul Stoffregen

unread,
Mar 8, 2018, 7:47:15 AM3/8/18
to Developers
Just wanted to share a quick idea, ask if anyone has any further feedback?

Today while answering forum questions, again someone hit a known
conflict between a library which accesses the ADC from interrupts and
use of analogRead() in their sketch.  Turns out, by the time I answered
(~2 days) they had found another forum thread where the same problem
came up, and already added other hardware to meet their needs.  It's a
well known conflict.

Then I started to wonder whether some sort of script could read the
compiler's symbol table output.  Maybe it could check for certain
combinations of symbols which are known conflicts?  Then we could show
the user a helpful message before their sketch uploads.  Even a short
list of just a few common conflicts might save many people from frustration.

Would love to hear any feedback or suggestions about how this might work
best.

Tom Igoe

unread,
Mar 8, 2018, 8:22:18 AM3/8/18
to Arduino Developers
It sounds like a good idea. I think Bjoern Hartmann at UC Berkeley might have some thoughts on it too. He has a continuing  research interest in better error messages.

It'd work best if the reports it produced describe the conflicts at a high level, for the beginner (e.g. "these two libraries both try to use the internal timers, but in conflicting ways"), with a verbose setting for the advanced programmer. 


--
You received this message because you are subscribed to the Google Groups "Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to developers+unsubscribe@arduino.cc.

Andrew Kroll

unread,
Mar 8, 2018, 9:16:59 AM3/8/18
to Arduino Developers
Perhaps this is also partially solvable with a used resources list in the library descriptors too? What happens if the resources are dynamic?
Other than the user understanding what is used, I think automation is going to miss a ton of corner cases without additional help.
Perhaps it would be possible to have the used resources appear as a comment when the user selects the library from the menu?

Reply all
Reply to author
Forward
0 new messages