GPIO Port Name Update, wrong in Kinetis SDK 1.2 API Documentation?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

GPIO Port Name Update, wrong in Kinetis SDK 1.2 API Documentation?

875件の閲覧回数
bosleymusic_com
Contributor IV

If you're migrating a project that uses custom pin declarations, and you copy old "board" files, you're going to have a problem...

 

Make pin used to be :

kGpioLED2       = GPIO_MAKE_PIN(HW_GPIOB, 19U),  /* */

where HW_GPIOB set the port.

 

The documentation says something to the effect of HW_PORTB would be proper now...

// Feel free to change the pin names as what you want

enum _gpio_pins

{

  kGpioLED1 = GPIO_MAKE_PIN(HW_PORTC, 0x0), 

  kGpioLED2 = GPIO_MAKE_PIN(HW_PORTC, 0x1), 

  kGpioLED3 = GPIO_MAKE_PIN(HW_PORTC, 0x2), 

  kGpioLED4 = GPIO_MAKE_PIN(HW_PORTC, 0x3), 

};

 

But that fails to compile...

 

 

So I saw in the new gpio_pins.h file is this guy:

GPIOB_IDX

 

Which now compiles...

 

 

 

ラベル(1)
0 件の賞賛
返信
0 返答(返信)