Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
06/27/07 06:20
Read: times


 
#141282 - A query on a C statement...
Please see the following code which is taken from an example provided by Keil for bit banged I2C :

void i2c_stop (void)
{
unsigned char input_var;

SCLK = LOW; // Set clock line low
SDATA = LOW; // Set data line low
SCLK = HIGH; // Set clock line high
SDATA = HIGH; // Set data line high (STOP SIGNAL)
input_var = SDATA; // Put port pin into HiZ
}

What exactly happens in the last statement ? Or is it a typo where RHS and LHS are swapped ??

Thanks

Raghu

List of 7 messages in thread
TopicAuthorDate
A query on a C statement...            01/01/70 00:00      
   You should know by now...            01/01/70 00:00      
      Just a slip..            01/01/70 00:00      
         just a slip            01/01/70 00:00      
         Formatting            01/01/70 00:00      
   checking for I2C slave done            01/01/70 00:00      
      Ready made code            01/01/70 00:00      

Back to Subject List