Merge pull request #34 from dmbryson/setgpios
Add support for directly setting the GPIO values
This commit is contained in:
commit
23c8c85b98
|
@ -1061,6 +1061,10 @@ uint16_t HamShield::getGpioMode(uint16_t gpio){
|
|||
return radio_i2c_buf[0];
|
||||
}
|
||||
|
||||
void HamShield::setGpios(uint16_t mode){
|
||||
HSwriteWord(devAddr, A1846S_GPIO_MODE_REG, mode);
|
||||
}
|
||||
|
||||
uint16_t HamShield::getGpios(){
|
||||
HSreadWord(devAddr, A1846S_GPIO_MODE_REG, radio_i2c_buf);
|
||||
return radio_i2c_buf[0];
|
||||
|
|
|
@ -403,6 +403,7 @@ class HamShield {
|
|||
void setGpioLow(uint16_t gpio);
|
||||
void setGpioHi(uint16_t gpio);
|
||||
uint16_t getGpioMode(uint16_t gpio);
|
||||
void setGpios(uint16_t mode);
|
||||
uint16_t getGpios();
|
||||
|
||||
// Int
|
||||
|
|
Loading…
Reference in New Issue