AmboVent-1690-108 / AmboVent

AmboVent 1690.108
The Unlicense
205 stars 69 forks source link

Fix some formatting (some #defines at the top) #46

Closed ElectricRCAircraftGuy closed 4 years ago

ElectricRCAircraftGuy commented 4 years ago

This PR fixes a tiny portion of the formatting issues in the file (it was a lot of changes, but only a tiny portion of how many there are to fix, so it is perhaps 1/10 of what needs to be done). It primarily covers the top few dozen defines is all.

Here's the description from my latest commit:

Clean up the top section of #defines; change all byte types to uint8_t

Cleaning up the #defines included:

  1. renaming to have more descriptive names, names in ALL_CAPITALS, and names which ended in their units (ex: _PA for Pascals)
  2. Changing all 0s meaning false to false, all 1s meaning true to true
  3. Adding more-detailed descriptions, such as for the low-pass-filter IIR (Infinite Impulse Response) alpha constants

When converting byte --> uint8_t, I also changed the parenthesis style from uint8_t(val), which mistakenly looks like a function, to (uint8_t)val, which is clearly a C-style type cast.

This closes #43 (a PR), since it replaces it.

ElectricRCAircraftGuy commented 4 years ago

@nimrod46, note that I've added a bunch of TODOs in the .ino file. Let's land this, then can you please go through and resolve all TODOs? I can review your changes once you do. Make that a separate PR after this one. They involve insight I do not have so you will need to do it. It's just comments and questions about measurement units.

ElectricRCAircraftGuy commented 4 years ago

If you'd like to view the detailed differences, as usual, checkout this branch to your local machine and use meld as your git difftool to do the comparison, as it is a much better line-by-line comparison tool than GitHub.

If you have any specific line comments though, leave them on GitHub using the "Files Changed" tab above.