cancel
Showing results for 
Search instead for 
Did you mean: 

How to define the GPIO mode ?

614678489
Associate II
Posted on August 13, 2012 at 09:20

typedef enum

{ GPIO_Mode_AIN = 0x0,

  GPIO_Mode_IN_FLOATING = 0x04,

  GPIO_Mode_IPD = 0x28,

  GPIO_Mode_IPU = 0x48,

  GPIO_Mode_Out_OD = 0x14,

  GPIO_Mode_Out_PP = 0x10,

  GPIO_Mode_AF_OD = 0x1C,

  GPIO_Mode_AF_PP = 0x18

}GPIOMode_TypeDef;

How come 0x0, 0x28, 0x48? Which register are they based on?

10 REPLIES 10
ricardo
Associate II
Posted on June 15, 2013 at 14:57

Thanks, that's right.