LoginSignup
0
0

More than 1 year has passed since last update.

LPC812MAXのシリアルでHello Worldと出力

Last updated at Posted at 2022-09-03

x mbed2リビジョン144
x リビジョンを変更できる人むけ

目的
シリアルのテスト

o_con717.jpg

参考




//SER_HELLO_812_1

#include "mbed.h"

//         TX    RX
Serial pc(P0_4, P0_0); //812

int main()
{

    char *ss1; //文字のポインター
    int ii; //ループカウンター

    //無限ループ
    while(1) {

        ss1="Hello World !\r\n";
        ii=0; //ループカウンター
        while(ss1[ii]!=0) {

            //一文字出力
            pc.putc(ss1[ii]);
            ii++;

        } //while

        //1秒の待ち
        wait_ms(1000);

    } //while
} //main





o_con833.jpg

-7-

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