0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

2019-10-11 LPC > LPCXpresso54628 > rit.c > kCLOCK_GPIO3 > LEDの操作はポート3-14であるためGPIO3のクロックをオンにする

Last updated at Posted at 2019-10-11
動作環境
OS: Ubuntu 18.04 LTS
基板: LPCXpresso54628
IDE: MCUXpresso IDE v11.0.1 [Build 2563] [2019-09-01]

関連

概要

  • SDK Example(s)からRITを選択
  • kCLOCK_GPIO3を設定している
  • その理由をフォーラムで質問した

フォーラムの質問

Because the LED function used the port3_14, need enable the clock of GPIO3.

ということらしい。

提供されている様々なドキュメントのどこにこういう情報が記載されているか、初学者には分からない。

Port3-14

User LED D12のポートについては以下の資料にある。

p10

D9, D11, D12: User LEDs
P2-2 (D9), P3-3(D11) and P3-14(D12)

シルク印刷を確認すると
LED1: D12
LED2: D11
LED3: D9

これに関連して、kCLOCK_Gpio3をオンにせよ、という正式情報が見つからない。

LED3 (P2-2: D9)

試しにLED3に変更したところ、LEDは点滅しなくなった。
LED3の場合はkCLOCK_Gpio2をオンにすることになる。
実際にそのようにしたらLED3は点滅するようになった。

正式情報

正式な情報としては、以下に記載があった。

UM10912 Rev 1.8 - 28 April 2017
Chapter 11: LPC546xx General Purpose I/O (GPIO)
11.3 Basic configuration

For the GPIO port registers, enable the clock to each GPIO port in the AHBCLKCTRL0 register (Table 137).

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?