mirror of
https://github.com/RobTillaart/Arduino.git
synced 2024-09-19 16:46:11 -04:00
0.4.4 printHelpers
This commit is contained in:
parent
ae1391e636
commit
732bc82929
@ -6,12 +6,16 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/)
|
|||||||
and this project adheres to [Semantic Versioning](http://semver.org/).
|
and this project adheres to [Semantic Versioning](http://semver.org/).
|
||||||
|
|
||||||
|
|
||||||
|
## [0.4.4] - 2024-01-05
|
||||||
|
- FIx URL in examples
|
||||||
|
- minor edits
|
||||||
|
|
||||||
|
|
||||||
## [0.4.3] - 2023-11-15
|
## [0.4.3] - 2023-11-15
|
||||||
- added **csi()** comma separated integers for readability e.g. 123,458,654
|
- added **csi()** comma separated integers for readability e.g. 123,458,654
|
||||||
- update readme.md.
|
- update readme.md.
|
||||||
- update examples
|
- update examples
|
||||||
|
|
||||||
|
|
||||||
## [0.4.2] - 2023-11-15
|
## [0.4.2] - 2023-11-15
|
||||||
- update readme.md
|
- update readme.md
|
||||||
- update keywords.txt
|
- update keywords.txt
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
MIT License
|
MIT License
|
||||||
|
|
||||||
Copyright (c) 2018-2023 Rob Tillaart
|
Copyright (c) 2018-2024 Rob Tillaart
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
of this software and associated documentation files (the "Software"), to deal
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
@ -22,7 +22,7 @@ data in a way not possible in the standard print library of the Arduino.
|
|||||||
- **print64()** print **uint64_t** and **int64_t**
|
- **print64()** print **uint64_t** and **int64_t**
|
||||||
- **sci()** generates in scientific format - exponent has step 1.
|
- **sci()** generates in scientific format - exponent has step 1.
|
||||||
- **eng()** generates in engineering format - exponent has step 3.
|
- **eng()** generates in engineering format - exponent has step 3.
|
||||||
- **scieng()** generated exponential format - exponent has step 1 to 9.
|
- **scieng()** generates in exponential format - exponent has step 1 to 9.
|
||||||
- **toBytes()** generates KB MB GB etc.
|
- **toBytes()** generates KB MB GB etc.
|
||||||
- **hex()** generates hexadecimal output with leading zeros up to **uint64_t**.
|
- **hex()** generates hexadecimal output with leading zeros up to **uint64_t**.
|
||||||
- **bin()** generates binary output with leading zeros up to **uint64_t**.
|
- **bin()** generates binary output with leading zeros up to **uint64_t**.
|
||||||
|
@ -2,11 +2,12 @@
|
|||||||
// FILE: print64.ino
|
// FILE: print64.ino
|
||||||
// AUTHOR: Rob Tillaart
|
// AUTHOR: Rob Tillaart
|
||||||
// PURPOSE: demo print 64 bit integers
|
// PURPOSE: demo print 64 bit integers
|
||||||
// DATE: 2020-06-24
|
// URL: https://github.com/RobTillaart/printHelpers
|
||||||
|
|
||||||
|
|
||||||
#include "printHelpers.h"
|
#include "printHelpers.h"
|
||||||
|
|
||||||
|
|
||||||
uint64_t llx = 1311768467284833366;
|
uint64_t llx = 1311768467284833366;
|
||||||
int64_t lly = 0xFFFFFFFFFFFFFFFF;
|
int64_t lly = 0xFFFFFFFFFFFFFFFF;
|
||||||
uint64_t a = 0;
|
uint64_t a = 0;
|
||||||
@ -57,5 +58,5 @@ void loop()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// -- END OF FILE --
|
// -- END OF FILE --
|
||||||
|
|
||||||
|
@ -1,13 +1,13 @@
|
|||||||
|
//
|
||||||
// FILE: print_comma_separated_integers.ino
|
// FILE: print_comma_separated_integers.ino
|
||||||
// AUTHOR: Rob Tillaart
|
// AUTHOR: Rob Tillaart
|
||||||
// VERSION: 0.1.0
|
|
||||||
// DATE: 2023-12-20
|
|
||||||
// PURPOSE: demo readability
|
// PURPOSE: demo readability
|
||||||
// URL: https://github.com/RobTillaart/printHelpers
|
// URL: https://github.com/RobTillaart/printHelpers
|
||||||
|
|
||||||
#include "Arduino.h"
|
|
||||||
#include "printHelpers.h"
|
#include "printHelpers.h"
|
||||||
|
|
||||||
|
|
||||||
void setup()
|
void setup()
|
||||||
{
|
{
|
||||||
Serial.begin(115200);
|
Serial.begin(115200);
|
||||||
|
@ -2,12 +2,15 @@
|
|||||||
// FILE: print_hex_bin.ino
|
// FILE: print_hex_bin.ino
|
||||||
// AUTHOR: Rob Tillaart
|
// AUTHOR: Rob Tillaart
|
||||||
// PURPOSE: demo hex(value, sep);
|
// PURPOSE: demo hex(value, sep);
|
||||||
|
// URL: https://github.com/RobTillaart/printHelpers
|
||||||
|
|
||||||
|
|
||||||
#include "printHelpers.h"
|
#include "printHelpers.h"
|
||||||
|
|
||||||
|
|
||||||
volatile uint32_t n = 0;
|
volatile uint32_t n = 0;
|
||||||
|
|
||||||
|
|
||||||
void setup()
|
void setup()
|
||||||
{
|
{
|
||||||
Serial.begin(115200);
|
Serial.begin(115200);
|
||||||
@ -65,10 +68,6 @@ void setup()
|
|||||||
}
|
}
|
||||||
Serial.println();
|
Serial.println();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Serial.println("10 random() BIN values");
|
Serial.println("10 random() BIN values");
|
||||||
for (uint8_t i = 0; i < 10; i++)
|
for (uint8_t i = 0; i < 10; i++)
|
||||||
{
|
{
|
||||||
@ -90,4 +89,4 @@ void loop()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// -- END OF FILE --
|
// -- END OF FILE --
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
|
//
|
||||||
// FILE: print_inch_feet.ino
|
// FILE: print_inch_feet.ino
|
||||||
// AUTHOR: Rob Tillaart
|
// AUTHOR: Rob Tillaart
|
||||||
// PURPOSE: demo program distance functions
|
// PURPOSE: demo program distance functions
|
||||||
|
// URL: https://github.com/RobTillaart/printHelpers
|
||||||
|
|
||||||
|
|
||||||
#include "printHelpers.h"
|
#include "printHelpers.h"
|
||||||
|
@ -1,14 +1,18 @@
|
|||||||
|
//
|
||||||
// FILE: print_sci_eng_performance.ino
|
// FILE: print_sci_eng_performance.ino
|
||||||
// AUTHOR: Rob Tillaart
|
// AUTHOR: Rob Tillaart
|
||||||
// PURPOSE: demo program SCI
|
// PURPOSE: demo program SCI
|
||||||
|
// URL: https://github.com/RobTillaart/printHelpers
|
||||||
|
|
||||||
|
|
||||||
#include "printHelpers.h"
|
#include "printHelpers.h"
|
||||||
|
|
||||||
|
|
||||||
uint32_t start = 0;
|
uint32_t start = 0;
|
||||||
uint32_t stop = 0;
|
uint32_t stop = 0;
|
||||||
char * b;
|
char * b;
|
||||||
|
|
||||||
|
|
||||||
void setup()
|
void setup()
|
||||||
{
|
{
|
||||||
Serial.begin(115200);
|
Serial.begin(115200);
|
||||||
@ -221,4 +225,4 @@ void loop()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// -- END OF FILE --
|
// -- END OF FILE --
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
|
//
|
||||||
// FILE: print_sci.ino
|
// FILE: print_sci.ino
|
||||||
// AUTHOR: Rob Tillaart
|
// AUTHOR: Rob Tillaart
|
||||||
// PURPOSE: demo program SCI
|
// PURPOSE: demo program SCI
|
||||||
|
// URL: https://github.com/RobTillaart/printHelpers
|
||||||
|
|
||||||
|
|
||||||
#include "printHelpers.h"
|
#include "printHelpers.h"
|
||||||
|
@ -1,12 +1,15 @@
|
|||||||
|
//
|
||||||
// FILE: print_sci_experimental.ino
|
// FILE: print_sci_experimental.ino
|
||||||
// AUTHOR: Rob Tillaart
|
// AUTHOR: Rob Tillaart
|
||||||
// PURPOSE: test program SCI
|
// PURPOSE: test program SCI
|
||||||
|
// URL: https://github.com/RobTillaart/printHelpers
|
||||||
|
|
||||||
|
|
||||||
#include "printHelpers.h"
|
#include "printHelpers.h"
|
||||||
|
|
||||||
uint32_t start, stop, duration;
|
uint32_t start, stop, duration;
|
||||||
|
|
||||||
|
|
||||||
void setup()
|
void setup()
|
||||||
{
|
{
|
||||||
Serial.begin(115200);
|
Serial.begin(115200);
|
||||||
|
@ -1,12 +1,15 @@
|
|||||||
|
//
|
||||||
// FILE: print_toRoman.ino
|
// FILE: print_toRoman.ino
|
||||||
// AUTHOR: Rob Tillaart
|
// AUTHOR: Rob Tillaart
|
||||||
// PURPOSE: demo program toRoman
|
// PURPOSE: demo program toRoman
|
||||||
|
// URL: https://github.com/RobTillaart/printHelpers
|
||||||
|
|
||||||
|
|
||||||
#include "printHelpers.h"
|
#include "printHelpers.h"
|
||||||
|
|
||||||
uint32_t start, stop;
|
uint32_t start, stop;
|
||||||
|
|
||||||
|
|
||||||
void setup()
|
void setup()
|
||||||
{
|
{
|
||||||
Serial.begin(115200);
|
Serial.begin(115200);
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
// FILE: sci_test.ino
|
// FILE: sci_test.ino
|
||||||
// AUTHOR: Rob Tillaart
|
// AUTHOR: Rob Tillaart
|
||||||
// PURPOSE: test different values with sci function
|
// PURPOSE: test different values with sci function
|
||||||
|
// URL: https://github.com/RobTillaart/printHelpers
|
||||||
|
|
||||||
|
|
||||||
#include "printHelpers.h"
|
#include "printHelpers.h"
|
||||||
@ -197,5 +198,5 @@ void test6()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// -- END OF FILE --
|
// -- END OF FILE --
|
||||||
|
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
// FILE: toBytes.ino
|
// FILE: toBytes.ino
|
||||||
// AUTHOR: Rob Tillaart
|
// AUTHOR: Rob Tillaart
|
||||||
// PURPOSE: demo toBytes(double val);
|
// PURPOSE: demo toBytes(double val);
|
||||||
|
// URL: https://github.com/RobTillaart/printHelpers
|
||||||
|
|
||||||
|
|
||||||
#include "printHelpers.h"
|
#include "printHelpers.h"
|
||||||
@ -55,4 +56,4 @@ void loop()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// -- END OF FILE --
|
// -- END OF FILE --
|
||||||
|
@ -15,7 +15,7 @@
|
|||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/RobTillaart/printHelpers"
|
"url": "https://github.com/RobTillaart/printHelpers"
|
||||||
},
|
},
|
||||||
"version": "0.4.3",
|
"version": "0.4.4",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"frameworks": "*",
|
"frameworks": "*",
|
||||||
"platforms": "*",
|
"platforms": "*",
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
name=printHelpers
|
name=printHelpers
|
||||||
version=0.4.3
|
version=0.4.4
|
||||||
author=Rob Tillaart <rob.tillaart@gmail.com>
|
author=Rob Tillaart <rob.tillaart@gmail.com>
|
||||||
maintainer=Rob Tillaart <rob.tillaart@gmail.com>
|
maintainer=Rob Tillaart <rob.tillaart@gmail.com>
|
||||||
sentence=Arduino library to help formatting data for printing. 64 bit integers (base 10 and 16). Engineering and scientific notation.
|
sentence=Arduino library to help formatting data for printing. 64 bit integers (base 10 and 16). Engineering and scientific notation.
|
||||||
|
@ -2,8 +2,8 @@
|
|||||||
// FILE: printHelpers.cpp
|
// FILE: printHelpers.cpp
|
||||||
// AUTHOR: Rob Tillaart
|
// AUTHOR: Rob Tillaart
|
||||||
// DATE: 2018-01-21
|
// DATE: 2018-01-21
|
||||||
// VERSION: 0.4.3
|
// VERSION: 0.4.4
|
||||||
// PUPROSE: Arduino library to help formatting for printing.
|
// PURPOSE: Arduino library to help formatting for printing.
|
||||||
// URL: https://github.com/RobTillaart/printHelpers
|
// URL: https://github.com/RobTillaart/printHelpers
|
||||||
|
|
||||||
|
|
||||||
|
@ -3,8 +3,8 @@
|
|||||||
// FILE: printHelpers.h
|
// FILE: printHelpers.h
|
||||||
// AUTHOR: Rob Tillaart
|
// AUTHOR: Rob Tillaart
|
||||||
// DATE: 2018-01-21
|
// DATE: 2018-01-21
|
||||||
// VERSION: 0.4.3
|
// VERSION: 0.4.4
|
||||||
// PUPROSE: Arduino library to help formatting for printing.
|
// PURPOSE: Arduino library to help formatting for printing.
|
||||||
// URL: https://github.com/RobTillaart/printHelpers
|
// URL: https://github.com/RobTillaart/printHelpers
|
||||||
|
|
||||||
|
|
||||||
@ -12,7 +12,7 @@
|
|||||||
#include "stdlib.h"
|
#include "stdlib.h"
|
||||||
|
|
||||||
|
|
||||||
#define PRINTHELPERS_VERSION (F("0.4.3"))
|
#define PRINTHELPERS_VERSION (F("0.4.4"))
|
||||||
|
|
||||||
|
|
||||||
// global buffer used by all functions so no static buffer in every function
|
// global buffer used by all functions so no static buffer in every function
|
||||||
|
Loading…
Reference in New Issue
Block a user