app: delete foo sample code
The initial idea behind this code was to showcase documentation. It does not add any special value to the sample, so remove it. A proper library can be added in the future. Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
This commit is contained in:
parent
bf4392f1a1
commit
e50d42c801
|
@ -12,4 +12,4 @@ project(app LANGUAGES C VERSION 1.0.0)
|
|||
configure_file(app_version.h.in ${CMAKE_BINARY_DIR}/app/include/app_version.h)
|
||||
target_include_directories(app PRIVATE ${CMAKE_BINARY_DIR}/app/include src)
|
||||
|
||||
target_sources(app PRIVATE src/main.c src/foo.c)
|
||||
target_sources(app PRIVATE src/main.c)
|
||||
|
|
|
@ -1,11 +0,0 @@
|
|||
/*
|
||||
* Copyright (c) 2021 Nordic Semiconductor ASA
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
#include "foo.h"
|
||||
|
||||
int app_foo_bar(void)
|
||||
{
|
||||
return 0;
|
||||
}
|
|
@ -1,30 +0,0 @@
|
|||
/**
|
||||
* @file foo.h
|
||||
*
|
||||
* Foo API.
|
||||
*
|
||||
* Copyright (c) 2021 Nordic Semiconductor ASA
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
#ifndef _FOO_H_
|
||||
#define _FOO_H_
|
||||
|
||||
/**
|
||||
* @defgroup app_foo Foo API
|
||||
*
|
||||
* A detailed description of the foo API.
|
||||
*
|
||||
* @{
|
||||
*/
|
||||
|
||||
/**
|
||||
* @brief An example foo API call.
|
||||
*
|
||||
* @return 0 on success, negative errno otherwise.
|
||||
*/
|
||||
int app_foo_bar(void);
|
||||
|
||||
/** @} */
|
||||
|
||||
#endif /* _FOO_H_ */
|
|
@ -7,7 +7,6 @@
|
|||
#include <drivers/sensor.h>
|
||||
|
||||
#include "app_version.h"
|
||||
#include "foo.h"
|
||||
|
||||
#include <logging/log.h>
|
||||
LOG_MODULE_REGISTER(main, CONFIG_APP_LOG_LEVEL);
|
||||
|
@ -19,12 +18,6 @@ void main(void)
|
|||
|
||||
printk("Zephyr Example Application %s\n", APP_VERSION_STR);
|
||||
|
||||
ret = app_foo_bar();
|
||||
if (ret < 0) {
|
||||
LOG_ERR("app_foo_bar failed (%d)", ret);
|
||||
return;
|
||||
}
|
||||
|
||||
sensor = DEVICE_DT_GET(DT_NODELABEL(examplesensor0));
|
||||
if (!device_is_ready(sensor)) {
|
||||
LOG_ERR("Sensor not ready");
|
||||
|
|
Loading…
Reference in a new issue