diff options
author | siddhu8990 | 2016-08-18 15:47:18 +0530 |
---|---|---|
committer | siddhu8990 | 2016-08-18 15:47:18 +0530 |
commit | c8fd6991786ccddb44547b619178bb391f3f9b96 (patch) | |
tree | cd1cacd7796d85875e8b2bb15780902c55f42db1 /src/c/hardware/rasberrypi/gpio/u8RPIDigitalOuts.c | |
parent | 24fbba33153e7758df4a990cb4c21ae8e53e6f3e (diff) | |
download | Scilab2C_fossee_old-c8fd6991786ccddb44547b619178bb391f3f9b96.tar.gz Scilab2C_fossee_old-c8fd6991786ccddb44547b619178bb391f3f9b96.tar.bz2 Scilab2C_fossee_old-c8fd6991786ccddb44547b619178bb391f3f9b96.zip |
RPi-PWM and basic imaage processing
Diffstat (limited to 'src/c/hardware/rasberrypi/gpio/u8RPIDigitalOuts.c')
-rw-r--r-- | src/c/hardware/rasberrypi/gpio/u8RPIDigitalOuts.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/c/hardware/rasberrypi/gpio/u8RPIDigitalOuts.c b/src/c/hardware/rasberrypi/gpio/u8RPIDigitalOuts.c index d40263f..a5f80e5 100644 --- a/src/c/hardware/rasberrypi/gpio/u8RPIDigitalOuts.c +++ b/src/c/hardware/rasberrypi/gpio/u8RPIDigitalOuts.c @@ -19,8 +19,10 @@ /*pin is reduced by one as array index starts from 0 and pin no starts from 1*/ uint8 u8RPIDigitalOuts(uint8 pin, uint8 state) { - if (state == 0) //low output + if (state == 0) /*low output*/ digitalWrite(phy_pin[pin-1], LOW); - if (state == 1) //high output + if (state == 1) /*high output*/ digitalWrite(phy_pin[pin-1], HIGH); + + return 0; } |