4ログ印刷

1. 関連文書


2.例
#include <stdbool.h>
#include <stdint.h>
#include <stdio.h>
#include "nrf.h"
#include "nrf_lay.h"
#include "app_error.h"

# include "nrf_log.h"
#include "nrf_log_ctrl.h"
#include "nrf_log_default_backends.h"
/** @brief メイン アプリケーション エントリの関数。
 */
int main(void)
{     APP_ERROR_CHECK(NRF_LOG_INIT(NULL));     NRF_LOG_DEFAULT_BACKENDS_INIT();     NRF_LOG_INFO("温度の例が開始されました。");


    while (true)
    {         NRF_LOG_INFO("実際の温度");         nrf_遅延_ms(500);

        NRF_LOG_FLUSH();
    }
}

おすすめ

転載: blog.csdn.net/fanxianchao_2012/article/details/130304298