06-14-2022 09:12 AM
Hi guys, sorry if this is the wrong place to post but hoping someone can help me out. How can I save channels as audio files? I can save wav files but they are silent, online info seems to suggest I need to scale it but I’m not sure what is required. Thanks, sorry if this isn’t appropriate here
06-17-2022 06:53 AM
Hi, having the channels scaled means their range must be between -1 and 1.
You can save a channel in a .wav file as follows (remarks, it is Python code)
dd.DataFileSave(r'D:\Data\Signal.wav', 'Audio', True)
If you use VBS, the script should be as folllowing (not tested).
Call DataFileSave("D:\Data\Signal.wav", "Audio", True)
I tried to export a channel to .wav and it worked (I opened the .wav file anc could hear the sound).
I put a time channel t (frequency: 44100 Hz that is a standard frequency for audio files) and an associated signal channel y.
With the sample code you can find above I was able to export it as a working .wav file.
Hope it helps.