**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License (version 2) as
**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License (version 2) as
else {
std::cout << "Enter input WinDAQ filename: ";
std::cin.getline (wdq_fname, MAX_INPUT_STR);
else {
std::cout << "Enter input WinDAQ filename: ";
std::cin.getline (wdq_fname, MAX_INPUT_STR);
else {
std::cout << "Enter channel number: ";
std::cin.getline (channel_buf, MAX_INPUT_STR);
else {
std::cout << "Enter channel number: ";
std::cin.getline (channel_buf, MAX_INPUT_STR);
else {
std::cout << "Enter output wav filename: ";
std::cin.getline (wav_fname, MAX_INPUT_STR);
else {
std::cout << "Enter output wav filename: ";
std::cin.getline (wav_fname, MAX_INPUT_STR);
m_data = new signed short int [r_wdq.m_nSamples * 2];
lseek (fd, r_wdq.m_channel_offset + 8 +
m_data = new signed short int [r_wdq.m_nSamples * 2];
lseek (fd, r_wdq.m_channel_offset + 8 +
unsigned char* p = reinterpret_cast<unsigned char*>(&v);
unsigned char c = p[0]; p[0] = p[1]; p[1] = c;
#endif
unsigned char* p = reinterpret_cast<unsigned char*>(&v);
unsigned char c = p[0]; p[0] = p[1]; p[1] = c;
#endif
value = (value + data_offset) * data_scale;
value += 0.5 - 32768;
signed short int v = static_cast<signed short int>(value);
value = (value + data_offset) * data_scale;
value += 0.5 - 32768;
signed short int v = static_cast<signed short int>(value);
unsigned char* p = reinterpret_cast<unsigned char*>(&v);
unsigned char c = p[0]; p[0] = p[1]; p[1] = c;
#endif
unsigned char* p = reinterpret_cast<unsigned char*>(&v);
unsigned char c = p[0]; p[0] = p[1]; p[1] = c;
#endif