2017-12-09 14:39:12 -05:00
|
|
|
//
|
|
|
|
// FILE: printCharArray1.ino
|
|
|
|
// AUTHOR: Rob Tillaart
|
2021-01-29 06:31:58 -05:00
|
|
|
// VERSION: 0.3.0
|
2017-12-09 14:39:12 -05:00
|
|
|
// PURPOSE: demo
|
2020-11-27 05:28:57 -05:00
|
|
|
// URL: https://github.com/RobTillaart/PrintCharArray
|
2017-12-09 14:39:12 -05:00
|
|
|
//
|
2021-01-29 06:31:58 -05:00
|
|
|
// HISTORY:
|
|
|
|
// 0.1.0 2017-12-07 initial version
|
|
|
|
// 0.3.0 2021-01-06 free() => available()
|
2017-12-09 14:39:12 -05:00
|
|
|
|
|
|
|
#include "PrintCharArray.h"
|
|
|
|
|
|
|
|
PrintCharArray ps;
|
|
|
|
|
|
|
|
void setup()
|
|
|
|
{
|
|
|
|
Serial.begin(115200);
|
|
|
|
Serial.println(__FILE__);
|
|
|
|
|
2021-01-29 06:31:58 -05:00
|
|
|
Serial.println(ps.available());
|
2017-12-09 14:39:12 -05:00
|
|
|
ps.println("Hello World");
|
2021-01-29 06:31:58 -05:00
|
|
|
Serial.println(ps.available());
|
2017-12-09 14:39:12 -05:00
|
|
|
ps.println(3.14159265, 4);
|
2021-01-29 06:31:58 -05:00
|
|
|
Serial.println(ps.available());
|
2017-12-09 14:39:12 -05:00
|
|
|
Serial.println(ps.getBuffer());
|
|
|
|
|
|
|
|
ps.clear();
|
|
|
|
ps.println(3.14159265, 4);
|
|
|
|
ps.println("Hello World");
|
|
|
|
Serial.println(ps.getBuffer());
|
|
|
|
}
|
|
|
|
|
|
|
|
void loop()
|
|
|
|
{
|
|
|
|
|
|
|
|
}
|
|
|
|
|
2020-11-27 05:28:57 -05:00
|
|
|
// -- END OF FILE --
|