I try to read from a string using a variable amount of arguments. This works fine directly with sscanf, but when I try to use sscanf in a procedure I get errors in transmitting the values back. I should have used vsscanf. However, when I use vsscanf I get "error: 'vsscanf' was not declared in this scope". This is strange as vsprintf is declared (see code below). It is even more strange as the same code compiles correctly for the Teensy. Is vsscanf declared in the Arduino libraries or should I include some specific file.
uint8_t CIO::Tx_format (const char* format, ...)
{
uint8_t len;
va_list argptr;
va_start (argptr, format);
len = vsprintf (&CIO_buffer [idx_Str], format, argptr);
len = vsscanf (&CIO_buffer [idx_Str], format, argptr);
va_end (argptr);
}
// call this function
int a, b;
Tx_format ("%d %d", &a, &b);
Regards, Arnold