KL25Z HelloWorldメモ

ee9king に投稿

MacOSではKL25Zが認識できないので、WindowsでMakeしたメモ

FRDM-KL25ZのTargetNameは"KL25Z"であることは調べてあった。

ほとんど手順通りだが、一つ。VSCodeインストールするまで終わった後、DOS窓からgithubのプロジェクトをインポートしてビルドのところまで行ったがエラーでビルドできなかった。エラーというよりなんかないと言っているようで、まず最初のミスはcmake-variants.yamlの修正ミス


board:
  # Fill name of your targer which has to corespond to
  # target name in targets.json5 file or custom_targets.json5 in case of custom target.
  # For simplified just replace every occurrence of YOUR_MBED_TARGET with Mbed target name. 
  # For example LPC1768 or NUCLEO_L452RE_P
  default: KL25Z # default variant (choose) from below
  choices:
    KL25Z: # Name of one variant
      short: KL25Z # Short name of the variant
      settings:
        MBED_TARGET: KL25Z # Your mbed target name from targets.json5 file
        # Fill your upload method according to variants below
        # - universal: NONE, MBED, JLINK, PYOCD, OPENOCD
        # - target specific: STLINK, STM32CUBE, LINKSERVER, PICOTOOL, ARDUINO_BOSSAC
        # For more visit - https://github.com/mbed-ce/mbed-os/wiki/Upload-Methods#upload-method-list
        UPLOAD_METHOD: LINKSERVER

MBED_TARGETの部分の修正ミス。修正してもビルドが通らない、キャッシュか?

Shift+Ctrl+Pで"CMake: Delete Cache and Reconfigure"でキャッシュクリアできるが、次にLinkserverのpathが見つからないようなことを言ってる。UploadMethodを先のcmake-variants.yamlで指定するだけではダメな模様・・

https://github.com/mbed-ce/mbed-os/wiki/Upload-Methods#upload-method-list

ここに、freescalはLinkserverであることが書かれている、ページ内リンクで

https://github.com/mbed-ce/mbed-os/wiki/Upload-Methods#linkserver

インストーラが示されているリンクが文章内にある。インストールするだけで、cmakeは場所を探し出して使うようだ。pathの設定は不要だった。

出来上がったbinファイルをKL25Zにドロップすると動作した。。。ちょっと一安心

 

 

 

 

 

コメントを追加

Plain text

  • HTMLタグは利用できません。
  • ウェブページのアドレスとメールアドレスは自動的にリンクに変換されます。
  • 行と段落は自動的に折り返されます。