-
Notifications
You must be signed in to change notification settings - Fork 0
Home
jankinjack edited this page Jul 29, 2026
·
5 revisions
Welcome to the Digital Points Wiki!
-
Download the latest release and unzip it.
-
Add the
microdplibrary to your embedded project:2.1 Add
libmicrodpfolder to include paths of the project.2.2 Add the appropriate static library from the folder to the project's build.
- Implement a transmit function for your communication interface using the following prototype. It must return
DP_OKon success:
Exception_DP func_transmit(const uint_least8_t * const frame, const size_t byte_size);- Initialize the library anywhere in your code:
#include "micro_dp_extern.h"
// Declare a static buffer to limit memory consumption.
static uint_least8_t DP_HEAP[10000];
// Declare the config structure.
static const Info_DP_Struct INFO =
{
.sampling_freq = 100000, // Sampling frequency, [Hz].
.func_transmit = func_transmit, // Function pointer to transmit frames.
.static_buffer = DP_HEAP, // Pointer to the buffer for memory allocation.
.memory_limit = sizeof(DP_HEAP), // Available memory size, [byte].
};
...
int main(void)
{
// Initialize the 'micro_dp' library.
micro_dp_init(&INFO);
...
}- Call background and context functions:
int main(void)
{
while (1)
{
// Call this function within your main loop
// or any non-time-critical task.
micro_dp_background();
}
}
void timer_irq_handler(void)
{
// Call this function periodically at the sampling frequency.
micro_dp_context();
}- Call the receive function to pass a chunk of data (or all the data) to the library:
void interface_irq_handler(void)
{
// Example 1: Byte-by-byte reception
uint_least8_t data = get_interface_data();
// Pass a single byte to the library.
micro_dp_handle_rx_chunk(&data, 1);
/*
// Example 2: Buffer reception.
uint_least8_t data[10];
for (size_t i = 0; i < sizeof(data); i++)
{
data[i] = get_interface_data();
}
// Pass the entire buffer (or a part of it) to the library.
micro_dp_handle_rx_chunk(data, sizeof(data));
*/
}-
Build the project, flash the MCU, and launch the Digital Points application.
-
Load an ELF file (*.axf, *.elf, *.out, *.prx, *.puff, *.so) with DWARF debug information from your project into
Digital Points.
- Configure the communication interface on the
Settingspage.
Note: Enable maximum DWARF debug information in your compiler (e.g.
-g3for GCC/clang).
- Check the connection status
Linked/Unlinkedin the bottom-left corner of the window.