创客百科

姿势共享,有节操无门槛参与的创客百科,创客动力之源 \ (^_^) /

用户工具

站点工具


arduino:avrgcc:bit_is_set

bit_is_set()

Abstcact

The bit_is_set() is a macro that checks if the second argumen-th bit of the first argument is 1.

Source Code

The bit_is_set() is defined in hardware/tools/avr/avr/include/avr/sfr_defs.h as below.

#define bit_is_set(sfr, bit) (_SFR_BYTE(sfr) & _BV(bit))

It calculates the logical AND of _SFR_BYTE(str) and _BV(bit).

本页面的其他翻译:
arduino/avrgcc/bit_is_set.txt · 最后更改: 2016/12/25 22:15 (外部编辑)