When compiling for ESP32-S2 I get fatal errors. I get the same errors with another microcontroller (M0), but it compiles successfully because they get treated as Warnings. (pasted below)
I suspect this has something to do with compiler settings, but are these anything you have fixed in the meanwhile? Any suggestions? By the way, I am only using this to encode WSPR packets.
Marty - KB4MG
c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\nhash.c: In function 'nhash':
c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\nhash.c:225:21: error: variable 'k8' set but not used [-Werror=unused-but-set-variable]
const uint8_t k8;
^~
cc1.exe: some warnings being treated as errors
c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp: In member function 'void JTEncode::fsq_encode(const char, const char, uint8_t)':
c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp:251:35: error: unused variable 'tone' [-Werror=unused-variable]
uint8_t i, fch, vcode1, vcode2, tone;
^~~~
c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp: In member function 'void JTEncode::fsq_dir_encode(const char, const char, char, const char, uint8_t)':
c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp:338:35: error: unused variable 'tone' [-Werror=unused-variable]
uint8_t i, fch, vcode1, vcode2, tone, from_call_crc;
^~~~
c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp: In member function 'void JTEncode::ft8_encode(const char, uint8_t)':
c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp:426:11: error: unused variable 'i' [-Werror=unused-variable]
uint8_t i;
^
c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp: In member function 'void JTEncode::ft8_bit_packing(char, uint8_t)':
c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp:1122:28: error: 'i0' may be used uninitialized in this function [-Werror=maybe-uninitialized]
memmove(c18, message, i0 + 1);
cc1plus.exe: some warnings being treated as errors_
To the best of my ability, I went in and fixed the errors in my copy of the library. It does compile, but I have yet to test it to see if I get good WSPR packets.
When compiling for ESP32-S2 I get fatal errors. I get the same errors with another microcontroller (M0), but it compiles successfully because they get treated as Warnings. (pasted below) I suspect this has something to do with compiler settings, but are these anything you have fixed in the meanwhile? Any suggestions? By the way, I am only using this to encode WSPR packets. Marty - KB4MG
c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\nhash.c: In function 'nhash': c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\nhash.c:225:21: error: variable 'k8' set but not used [-Werror=unused-but-set-variable] const uint8_t k8; ^~ cc1.exe: some warnings being treated as errors c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp: In member function 'void JTEncode::fsq_encode(const char, const char, uint8_t)': c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp:251:35: error: unused variable 'tone' [-Werror=unused-variable] uint8_t i, fch, vcode1, vcode2, tone; ^~~~ c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp: In member function 'void JTEncode::fsq_dir_encode(const char, const char, char, const char, uint8_t)': c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp:338:35: error: unused variable 'tone' [-Werror=unused-variable] uint8_t i, fch, vcode1, vcode2, tone, from_call_crc; ^~~~ c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp: In member function 'void JTEncode::ft8_encode(const char, uint8_t)': c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp:426:11: error: unused variable 'i' [-Werror=unused-variable] uint8_t i; ^ c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp: In member function 'void JTEncode::ft8_bit_packing(char, uint8_t)': c:\Users\Marty\Documents\Arduino\libraries\JTEncode\src\JTEncode.cpp:1122:28: error: 'i0' may be used uninitialized in this function [-Werror=maybe-uninitialized] memmove(c18, message, i0 + 1);