求助:这个到底是赋值的什么? 怎么实现dat的发送的?

2019-07-15 09:56发布

在iic总线里面的发送函数时,
unsigned char i2csendbyte (unsigned char date)
{
   unsigned char a=0;
         for (a=0;a<8;a++)
        {
                 SDA=dat>>7;
                 dat=dat<<1;
                 delay10us();
                 SCL=1;
                 delay10us();
                 SCL=0;
                 delay10us();
        
   }

我看不懂这个;SDA是一个个发送的从高位发送到低位,但是dat是有8个byte,
而SDA一次只能发送一个byte那这个赋值语句 SDA=dat>>7;到底是赋值的什么?
怎么实现dat的发送的?

0条回答

一周热门 更多>