@@ -38,8 +38,8 @@ void pinMode(uint8_t pin, PinMode mode)
3838 if (((pin == PIN_A4 ) || (pin == PIN_A5 )) && (TWI0 .MCTRLA & TWI_ENABLE_bm )) return ;
3939
4040 /* Special check for SPI_SS double bonded pin -- no action if SPI is active
41- (Using Slave Select Disable as indicator of SPI activity) */
42- if ((pin == 10 ) && (SPI0 .CTRLB & SPI_SSD_bm )) return ;
41+ (Using SPI Enable bit as indicator of SPI activity) */
42+ if ((pin == 10 ) && (SPI0 .CTRLA & SPI_ENABLE_bm )) return ;
4343
4444 PORT_t * port = digitalPinToPortStruct (pin );
4545 if (port == NULL ) return ;
@@ -153,8 +153,8 @@ void digitalWrite(uint8_t pin, PinStatus val)
153153 if (((pin == PIN_A4 ) || (pin == PIN_A5 )) && (TWI0 .MCTRLA & TWI_ENABLE_bm )) return ;
154154
155155 /* Special check for SPI_SS double bonded pin -- no action if SPI is active
156- (Using Slave Select Disable as indicator of SPI activity) */
157- if ((pin == 10 ) && (SPI0 .CTRLB & SPI_SSD_bm )) return ;
156+ (Using SPI Enable bit as indicator of SPI activity) */
157+ if ((pin == 10 ) && (SPI0 .CTRLA & SPI_ENABLE_bm )) return ;
158158
159159 /* Turn off PWM if applicable */
160160
@@ -235,8 +235,8 @@ PinStatus digitalRead(uint8_t pin)
235235 if (((pin == PIN_A4 ) || (pin == PIN_A5 )) && (TWI0 .MCTRLA & TWI_ENABLE_bm )) return LOW ;
236236
237237 /* Special check for SPI_SS double bonded pin -- no action if SPI is active
238- (Using Slave Select Disable as indicator of SPI activity) */
239- if ((pin == 10 ) && (SPI0 .CTRLB & SPI_SSD_bm )) return LOW ;
238+ (Using SPI Enable bit as indicator of SPI activity) */
239+ if ((pin == 10 ) && (SPI0 .CTRLA & SPI_ENABLE_bm )) return ;
240240
241241 // If the pin that support PWM output, we need to turn it off
242242 // before getting a digital reading.
0 commit comments