Skip to content

Commit 4dba4b4

Browse files
committed
* missed const modifier. Fixed.
* Added a reference to the co-author of class DirectPin.
1 parent 024f4ef commit 4dba4b4

File tree

2 files changed

+12
-13
lines changed

2 files changed

+12
-13
lines changed

src/DirectInteract.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22
*
33
* DirectInteract this is a helper class to direct interaction with a set of Arduino pins.
44
*
5-
* @author Valeriy V Dmitriev aka valmat <[email protected]>
6-
* @author ...
7-
* @licenses MIT https://opensource.org/licenses/MIT
8-
* @repo https://github.com/valmat/LedMatrix
5+
* @author Valeriy V Dmitriev aka valmat <[email protected]>
6+
* @coauthor Nikolai Tikhonov aka Dragon_Knight <[email protected]>, https://vk.com/globalzone_edev
7+
* @licenses MIT https://opensource.org/licenses/MIT
8+
* @repo https://github.com/valmat/LedMatrix
99
*
1010
*/
1111

src/DirectPin.h

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44
* The purpose of this class is to increase speed by eliminating unnecessary in this case checks.
55
* Not all methods are implemented, but only those that are needed within the library.
66
*
7-
* @author Valeriy V Dmitriev aka valmat <[email protected]>
8-
* @author ...
9-
* @licenses MIT https://opensource.org/licenses/MIT
10-
* @repo https://github.com/valmat/LedMatrix
7+
* @author Valeriy V Dmitriev aka valmat <[email protected]>
8+
* @coauthor Nikolai Tikhonov aka Dragon_Knight <[email protected]>, https://vk.com/globalzone_edev
9+
* @licenses MIT https://opensource.org/licenses/MIT
10+
* @repo https://github.com/valmat/LedMatrix
1111
*
1212
*/
1313

@@ -39,25 +39,25 @@ class DirectPin
3939
{}
4040

4141
// Directly set mode as `OUTPUT`
42-
void modeOut(bool mode)
42+
void modeOut(bool mode) const
4343
{
4444
*(_baseReg + 1) |= _bitMask;
4545
}
4646

4747
// Directly set mode as `INPUT`
48-
void modeIn()
48+
void modeIn() const
4949
{
5050
*(_baseReg + 1) &= ~_bitMask;
5151
}
5252

5353
// Directly set mode as `OUTPUT`
54-
void modeOut()
54+
void modeOut() const
5555
{
5656
*(_baseReg + 1) |= _bitMask;
5757
}
5858

5959
// Directly set mode
60-
void setMode(uint8_t mode)
60+
void setMode(uint8_t mode) const
6161
{
6262
if(OUTPUT == mode) {
6363
modeOut();
@@ -105,7 +105,6 @@ class DirectPin
105105
{
106106
for(uint8_t i = 0; i < 8; ++i) {
107107
turn(val & (1 << i));
108-
109108
clock.on();
110109
clock.off();
111110
}

0 commit comments

Comments
 (0)