Commit f5341bfc authored by TMRh20's avatar TMRh20

Merge pull request #19 from reixd/master

Fix "warning: binary constants are a GCC extension".
parents 9e28a602 6f70a3cc
......@@ -434,24 +434,24 @@ extern volatile uint32_t *bcm2835_bsc1;
/// Port function select modes for bcm2835_gpio_fsel()
typedef enum
{
BCM2835_GPIO_FSEL_INPT = 0b000, ///< Input
BCM2835_GPIO_FSEL_OUTP = 0b001, ///< Output
BCM2835_GPIO_FSEL_ALT0 = 0b100, ///< Alternate function 0
BCM2835_GPIO_FSEL_ALT1 = 0b101, ///< Alternate function 1
BCM2835_GPIO_FSEL_ALT2 = 0b110, ///< Alternate function 2
BCM2835_GPIO_FSEL_ALT3 = 0b111, ///< Alternate function 3
BCM2835_GPIO_FSEL_ALT4 = 0b011, ///< Alternate function 4
BCM2835_GPIO_FSEL_ALT5 = 0b010, ///< Alternate function 5
BCM2835_GPIO_FSEL_MASK = 0b111 ///< Function select bits mask
BCM2835_GPIO_FSEL_INPT = 0x00, ///< Input
BCM2835_GPIO_FSEL_OUTP = 0x01, ///< Output
BCM2835_GPIO_FSEL_ALT0 = 0x04, ///< Alternate function 0
BCM2835_GPIO_FSEL_ALT1 = 0x05, ///< Alternate function 1
BCM2835_GPIO_FSEL_ALT2 = 0x06, ///< Alternate function 2
BCM2835_GPIO_FSEL_ALT3 = 0x07, ///< Alternate function 3
BCM2835_GPIO_FSEL_ALT4 = 0x03, ///< Alternate function 4
BCM2835_GPIO_FSEL_ALT5 = 0x02, ///< Alternate function 5
BCM2835_GPIO_FSEL_MASK = 0x07 ///< Function select bits mask
} bcm2835FunctionSelect;
/// \brief bcm2835PUDControl
/// Pullup/Pulldown defines for bcm2835_gpio_pud()
typedef enum
{
BCM2835_GPIO_PUD_OFF = 0b00, ///< Off ? disable pull-up/down
BCM2835_GPIO_PUD_DOWN = 0b01, ///< Enable Pull Down control
BCM2835_GPIO_PUD_UP = 0b10 ///< Enable Pull Up control
BCM2835_GPIO_PUD_OFF = 0x00, ///< Off ? disable pull-up/down
BCM2835_GPIO_PUD_DOWN = 0x01, ///< Enable Pull Down control
BCM2835_GPIO_PUD_UP = 0x02 ///< Enable Pull Up control
} bcm2835PUDControl;
/// Pad control register offsets from BCM2835_GPIO_PADS
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment