You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In #33@simonmacarthur came with some good suggestion for refactoring the debug output. This issue is forked, because the original issue was closed successfully.
Suggestion 1:
Maybe have send_message return a bool to indicate if a message was sent?
-> Yes, in fact a good idea!
Suggestion 2:
There is no reason for it to be placed near the code that does the calculation as the flow will always run through to the end of the function (and in fact always call send_message) so it could be moved into a single call that takes all possible "watched" values and ...
-> We need to rewrite the good a little bit, because the centered array is mapped to the min-max values between debug=2 and debug=3. No big deal with an additional array. In every case, we must leave proper comments for new-comers in the code how to call the debug-reporting for this spots.
Suggestion 3:
and by changing the debug_level to a bitmask, would give better flexibility in determining which items people want output. (I'm happy to put something together by way of example if that helps).
-> Yes, also a good idea as an additional debuging. I think there is nothing simpler for newcomers than giving them numbers rising from 1 to 9 to perform ;) (and also typing this numbers of the serial interface is easier than a bitmask ;))
But we can obviously put a mapping from those numbers to general applicable bitmask.
The text was updated successfully, but these errors were encountered:
In #33 @simonmacarthur came with some good suggestion for refactoring the debug output. This issue is forked, because the original issue was closed successfully.
Suggestion 1:
-> Yes, in fact a good idea!
Suggestion 2:
-> We need to rewrite the good a little bit, because the centered array is mapped to the min-max values between debug=2 and debug=3. No big deal with an additional array. In every case, we must leave proper comments for new-comers in the code how to call the debug-reporting for this spots.
Suggestion 3:
-> Yes, also a good idea as an additional debuging. I think there is nothing simpler for newcomers than giving them numbers rising from 1 to 9 to perform ;) (and also typing this numbers of the serial interface is easier than a bitmask ;))
But we can obviously put a mapping from those numbers to general applicable bitmask.
The text was updated successfully, but these errors were encountered: