~aleteoryx/muditaos

ref: c611e3c011c336ca55733ad96af698657df034c5 muditaos/module-bsp/board/rt1051/bsp/pit/pit.hpp -rw-r--r-- 517 bytes
c611e3c0 — DariuszSabala [BH-376] Utils time turned to separate library 4 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// 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 <FreeRTOS.h>
#include <FreeRTOS/include/queue.h>
#include <functional>

namespace bsp
{
    namespace pit
    {
        enum class Event
        {
            Overflow
        };
        void init(xQueueHandle qhandle);
        void start(uint32_t usec, std::function<void(void)> iqr_cb);
        void stop();
    }; // namespace pit
};     // namespace bsp