doc
parent
980700e68a
commit
e3217ffa69
25
README.md
25
README.md
|
@ -70,7 +70,7 @@ First, look at the reference hardware implementation above. You will need to
|
|||
build this circuit on your board, and connect it to the microcontroller as
|
||||
shown.
|
||||
|
||||
### Firmware
|
||||
### Firmware (using Meson)
|
||||
|
||||
TIMDAC provides a Meson build file, so if you use Meson you can include it
|
||||
directly as a subproject. The following options should be defined:
|
||||
|
@ -99,6 +99,18 @@ bsp_dep = declare_dependency(include_directories: include_directories('.'))
|
|||
If you want to call the dependency something other than `bsp_dep`, you can set
|
||||
the same-named option (`bsp_dep`) to its actual name.
|
||||
|
||||
### Firmware (not using Meson)
|
||||
|
||||
- Add the source files under `src` to your build (only add one of the
|
||||
`timdac_hw` files, matching your target platform).
|
||||
- Add the include directory `inc` to your build.
|
||||
- When building TIMDAC itself, ensure that wherever `timdac_config.h` lives is
|
||||
in TIMDAC's include path.
|
||||
|
||||
### Firmware configuration
|
||||
|
||||
TIMDAC needs to be given a build configuration with hardware and runtime
|
||||
options as `timdac_config.h`.
|
||||
A template configuration file can be found in
|
||||
[`timdac_config_template_ch32v103.h`](inc/timdac_config_template_ch32v103.h).
|
||||
All of the configuration options for TIMDAC itself are documented in
|
||||
|
@ -106,6 +118,17 @@ All of the configuration options for TIMDAC itself are documented in
|
|||
driver are documented in that driver's source file (e.g.
|
||||
[`timdac_hw_ch32v103.c`](src/timdac_hw_ch32v103.c)).
|
||||
|
||||
Some of these options are labeled `[REFHW]` in the documentation. These options
|
||||
pertain to the reference hardware implementation, and as long as you are
|
||||
following the hardware suggestions, you should not change them. They can have
|
||||
surprising and difficult-to-measure effects on the DAC performance. To get the
|
||||
correct options for a reference design, you should `#include` that reference
|
||||
design's sub-config in your config:
|
||||
|
||||
```
|
||||
#include "timdac_config_ref1p0.h"
|
||||
```
|
||||
|
||||
### Using TIMDAC
|
||||
|
||||
Once integrated into your codebase, it can be initialized and started very
|
||||
|
|
Loading…
Reference in New Issue