Tiny improvement to M7219

The registers within the Max7219 can get corrupted a number of ways.  This allows the Max7219 to be reset and fully initialized.
And...  it also allows the user to see the initialization pattern.
This commit is contained in:
Roxy-3D 2018-06-19 14:46:30 -05:00 committed by GitHub
parent a65d15c905
commit 7c54c4ed27
Signed by: GitHub
GPG key ID: 4AEE18F83AFDEB23

View file

@ -39,7 +39,7 @@
*/
void GcodeSuite::M7219() {
if (parser.seen('I'))
for (uint8_t r = 0; r < 8; r++) Max7219_Set_Row(r, 0);
Max7219_init();
else if (parser.seenval('R')) {
const uint8_t r = parser.value_int();
Max7219_Set_Row(r, parser.byteval('V'));