Files
MuditaOS/module-bsp/bsp/light_sensor/light_sensor.hpp
wojtekrzepecki 4aef4d8166 [EGD-4653] BSP: amblient light sensor (#1135)
* [EGD-4653] Added first working readout

* [EGD-4653] Light sensor first working irq

* [EGD-4653] Interrupt config

* [EGD-4653] Cleanup

* [EGD-4653] Linux target file added

* [EGD-4653] Added messages with readout + fix of keypad light message

* [EGD-4653] Proper lux calculation

* [EGD-4653] Branch fix

* [EGD-4653] Pre PR cleanup

* [EGD-4653] Clang tidy hints application

* [EGD-4653] PR comments pt1

* [EGD-4653] Style branch fix

* [EGD-4653] Pr comments pt2

Co-authored-by: Wojtek Rzepecki <wojtek.rzepecki@mudita.com>
2020-12-04 15:21:45 +01:00

35 lines
552 B
C++

// Copyright (c) 2017-2020, Mudita Sp. z.o.o. All rights reserved.
// For licensing, see https://github.com/mudita/MuditaOS/LICENSE.md
#pragma once
#include <cstdint>
extern "C"
{
#include "FreeRTOS.h"
#include "task.h"
#include "queue.h"
}
namespace bsp::light_sensor
{
using IlluminanceLux = float;
std::int32_t init(xQueueHandle qHandle);
void deinit();
bool standby();
bool wakeup();
bool reset();
bool isPresent();
IlluminanceLux readout();
BaseType_t IRQHandler();
} // namespace bsp::light_sensor