Loading...
Searching...
No Matches
dac_dds_params.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2020 Beuth Hochschule für Technik Berlin
3 * SPDX-License-Identifier: LGPL-2.1-only
4 */
5
6#pragma once
7
17
18#include "board.h"
19#include "macros/units.h"
20
21#ifdef __cplusplus
22extern "C" {
23#endif
24
29#ifndef DAC_DDS_PARAM_DAC
30#define DAC_DDS_PARAM_DAC DAC_LINE(0)
31#endif
32#ifndef DAC_DDS_PARAM_TIMER
33#define DAC_DDS_PARAM_TIMER (TIMER_NUMOF - 1)
34#endif
35#ifndef DAC_DDS_PARAM_TIMER_HZ
36#define DAC_DDS_PARAM_TIMER_HZ MHZ(1)
37#endif
38
39#ifndef DAC_DDS_PARAMS
40#define DAC_DDS_PARAMS { .dac = DAC_DDS_PARAM_DAC, \
41 .timer = DAC_DDS_PARAM_TIMER, \
42 .timer_hz = DAC_DDS_PARAM_TIMER_HZ, \
43 }
44#endif
46
51{
52 DAC_DDS_PARAMS
53};
54
58#define DAC_DDS_NUMOF ARRAY_SIZE(dac_dds_params)
59
60#ifdef __cplusplus
61}
62#endif
63
static const dac_dds_params_t dac_dds_params[]
DAC DDS configuration.
Configuration struct for a DAC DDS channel.
Definition dac_dds.h:66
Unit helper macros.