blob: 36126dadd03be21b15a4f5afe02b377c8d0c4d4b [file] [log] [blame]
Sylvain Munautbc9f5c42020-09-14 10:22:29 +02001/*
2 * misc.h
3 *
4 * Copyright (C) 2019-2020 Sylvain Munaut <tnt@246tNt.com>
5 * SPDX-License-Identifier: GPL-3.0-or-later
6 */
7
8#pragma once
9
10#include <stdbool.h>
11#include <stdint.h>
12
13enum pdm_chan {
14 PDM_CLK_LO = 0,
15 PDM_CLK_HI = 1,
16 PDM_E1_N = 2,
17 PDM_E1_P = 3,
18 PDM_E1_CT = 4,
19};
20
21void pdm_set(int chan, bool enable, unsigned value, bool normalize);
22
23uint16_t e1_tick_read(void);