As the ARM compiler is in GNU compatible mode, it defines __GNU__ which
(based on pre-processor condition in mbed_printf_implentation.h)
causes the printf functions to be wrapped using _wrap_* instead of
$Sub$$*.
This commit modifies the pre-processor
conditions to check for __GNUC__last in order to correctly
substitute the printf functions depending on the toolchain in use.
It also gets rid of $Super$$* substitution as it is not needed. $Super$$
is used to identify the original unpatched functions.
Missing substitutions for ARM compiler internal optimized "printfs" are
also added.
Earlier we called AT+QICSGP only if the username and password was set.
It seems that we must call it also to set up APN while in AT mode.
This commit fixes the issue + updated IPv4/v6 handling to be correct in the same call
1. Fix 'spurious close' by adding close() in open(). 'spurious close' gets frequent and cannot ignore when send() changes to asynchronous. User can retry open() until 'spurious close' gets true.
2. Allow only one actively sending socket because:
(1) ESP8266 AT packets 'SEND OK'/'SEND FAIL' are not associated with socket ID. No way to tell them.
(2) In original implementation, ESP8266::send() is synchronous, which implies only one actively sending socket.
3. Register 'SEND OK'/'SEND FAIL' oobs, like others in ESP8266::ESP8266 constructor. Don't get involved in oob management with send status because ESP8266 modem possibly doesn't reply these packets on error case.
4. Now that ESP8266::send() changes to asynchronous, drop the code with _parser.recv("SEND OK")/_parser.recv("SEND FAIL"). _parser.recv("SEND OK")/_parser.recv("SEND FAIL") and 'SEND OK'/'SEND FAIL' oobs both consume 'SEND OK'/'SEND FAIL' packets and complicate flow control.
On some targets with very fast counters used for us ticker (e.g. 26 MHz) tested interrupt delays provided in the ticker_timeout array may be too short (execution of the set_interrupt() function takes longer than the tested delay).
We will skip tested ticker delay if the delay is less than assumed max set_interrupt() function execution time (20 us).
Also, the test array will be extended.
Per feedback from STM the correct ROM size is 1 MB, instead of
16 MB. The KEIL source information is (in the pack itself) wrong, since
the KEIL webpage lists it as a 16 MB part, too - but if you look into
other sources - it is indeed 1 MB.
Original default constructor implementation wasn't quite working
properly; it didn't cope with the new "mode_limit" parameter.
Change mechanism so that this now works:
MbedCRC<POLY32_BIT_ANSI_CRC, 32, CrcMode::TABLE> crc;
CRC tests failed to exercise handling of the initial and final-xor
values with respect to reflection parameters. Add tests covering this.
Expected behaviour is that the initial value is always non-reflected and
the final-xor happens after the optional output reflection.
Init values often need reflection, and use of `__RBIT` prevents constant
init being done at compile time (unless `__RBIT` uses a compiler
intrinsic, which it doesn't for GCC).
Rather than try to handle constants 0U and -1U with a special case to
avoid the RBIT, which can in turn lead to runtime bloat for nonconstant
inits, use a C++20 style is_constant_evaluated() check to switch between
C and assembly forms.
This reduces code-size for non-constant init, by eliminating a runtime
condition, and allows the bit-reversal of any constant init to happen at
compile time.