C/C++ Question how to handle a stream from arduino library ?

candide

Active Member
Licensed User
in an arduino library i have:
- in cpp file Arduino:
B4X:
void LoRaClass::dumpRegisters(Stream& out)
{
  for (int i = 0; i < 128; i++) {
    out.print("0x");
    out.print(i, HEX);
    out.print(": 0x");
    out.println(readRegister(i), HEX);
  }
}
- in h file Arduino:
B4X:
void dumpRegisters(Stream& out);

after B4X wrapper i think we should arrive at :
B4X:
           void dumpRawdata(B4RStream* Out);
or
B4X:
           B4RStream* dumpRawdata();

how to make wrapper for this stream ? i didn't find example to help on this stream....
where i can find an example ?

thanks for your help
 
Last edited:
Top