Simple data logging test incorporating datalog library with user configurable as follows:
Parameters | Values |
---|---|
Number of data log channels | 4 |
Buffer size | 400 |
Data type | 32bit floating point |
Trigger typ | Auto trigger |
Trigger Value | 5.0 |
Prescalar/size | 1 |
This example verifies data logging capability and showcase datalog API usage. In this one float variable(i) will be incremented with "1" in every loop starting with "0" and with trigger value as "5". When *iptr[0] value will be monitered at auto trigger type and if it crosses trigger value, data logging is initiated and values provided to *iptr[] will be logged for every prescalar loop.
In datalog_input.h, user can use following defines as per data type:
Data type | Defines |
---|---|
32 bit signed integer | u_int32_t |
32 bit unsigned integer | u_uint32_t |
64 bit signed integer | u_int64_t |
64 bit floating point | u_float64_t |
32 bit floating point | u_float32_t |
16 bit signed integer | u_int16_t |
16 bit unsigned integer | u_uint16_t |
8 bit signed integer | u_int8_t |
8 bit unsigned integer | u_uint8_t |
Folder/Files | Description |
---|---|
main.c | Main function for datalog library testing |
datalog_test.c | Contains all initialization of test strctures and variables with datalog functionality |
datalog.c | datalog library source file |
datalog.h | datalog library header file at "${SDK_INSTALL_PATH}/source/utilities/datalog/include" |
datalog_input.h | User configurable datalog header file need to be changed at "${SDK_INSTALL_PATH}/source/utilities/datalog/include" |
datalog.syscfg | syscfg file for application |
Parameter | Value |
---|---|
CPU + OS | r5fss0-0 nortos |
r5fss0-0 freertos | |
Toolchain | ti-arm-clang |
Boards | am263x-cc |
Example folder | examples/utilities/datalog |
Shown below is a sample output when the application is run and datalog output observed in datalogBuff[][]: