gHall_GpioData = (~HAL_readGpio(halHandle, (GPIO_Number_e)HAL_HallGpio_C) & 0x1) << 2;
我想请问:得出gHall_GpioData是多少?
PS:28069+8305 lab11e
rookiecalf:0或者4
gHall_GpioData = (~HAL_readGpio(halHandle, (GPIO_Number_e)HAL_HallGpio_C) & 0x1) << 2;
我想请问:得出gHall_GpioData是多少?
PS:28069+8305 lab11e
mangui zhang:看这个就够了& 0x1) << 2
与0x1与结果是0或1左移一位也就是0或4