Showing results for 
Search instead for 
Did you mean: 

How implemented the code where user can provide the file in csv format to DAC for different output waveforms

Associate II


I am working on Nucleo-h745ziq board, I interface the AD9106 sensor. I have to generate the different output waveforms for this I have to use the CSV file. How the CSV file is import in stm32cubeide.How I can read the CSV file. Can you help me?


Write a small C application (Python script, or whatever kids use these days to quickly code a solution) on your host PC to read and parse the .CSV file, and have it output a .C file or .H file with the numeric content expressed as a C array variable. Say uint16_t DacData[] = { .... , ... };

Add this file to your project , and have the code use DacData and sizeof(DacData) / sizeof(uint16_t) to reference the data you've imported.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Chief II

You need define if CSV is used in runtime or buildtime. Buildtime explain Tesla

Runtime is on your board Ethernet ,USB or other way to load CSV..., but here you need write something about CSV, because here can be samples, but for examplke too



... is too CSV