0.2.3 NibbleArray

This commit is contained in:
rob tillaart 2021-12-22 13:28:44 +01:00
parent e764caa61b
commit ae5318b131
9 changed files with 23 additions and 11 deletions

View File

@ -1,6 +1,6 @@
MIT License MIT License
Copyright (c) 2017-2021 Rob Tillaart Copyright (c) 2017-2022 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

View File

@ -1,7 +1,6 @@
// //
// FILE: nibbleArray_demo.ino // FILE: nibbleArray_demo.ino
// AUTHOR: Rob Tillaart // AUTHOR: Rob Tillaart
// VERSION: 0.1.1
// PURPOSE: demo nibble array // PURPOSE: demo nibble array
// DATE: 2020-06-21 // DATE: 2020-06-21
// URL: https://github.com/RobTillaart/nibbleArray // URL: https://github.com/RobTillaart/nibbleArray
@ -148,3 +147,4 @@ void loop()
// -- END OF FILE -- // -- END OF FILE --

View File

@ -1,7 +1,6 @@
// //
// FILE: nibbleArray_performance.ino // FILE: nibbleArray_performance.ino
// AUTHOR: Rob Tillaart // AUTHOR: Rob Tillaart
// VERSION: 0.1.0
// PURPOSE: demo performance nibble array // PURPOSE: demo performance nibble array
// DATE: 2020-06-21 // DATE: 2020-06-21
// URL: https://github.com/RobTillaart/nibbleArray // URL: https://github.com/RobTillaart/nibbleArray
@ -180,3 +179,4 @@ void loop()
// -- END OF FILE -- // -- END OF FILE --

View File

@ -1,6 +1,6 @@
# Syntax Colouring Map For BoolArray # Syntax Colouring Map For BoolArray
# Datat ypes (KEYWORD1) # Data types (KEYWORD1)
BoolArray KEYWORD1 BoolArray KEYWORD1

View File

@ -15,8 +15,9 @@
"type": "git", "type": "git",
"url": "https://github.com/RobTillaart/nibbleArray.git" "url": "https://github.com/RobTillaart/nibbleArray.git"
}, },
"version": "0.2.2", "version": "0.2.3",
"license": "MIT", "license": "MIT",
"frameworks": "arduino", "frameworks": "arduino",
"platforms": "*" "platforms": "*",
"headers": "nibbleArray.h"
} }

View File

@ -1,5 +1,5 @@
name=NibbleArray name=NibbleArray
version=0.2.2 version=0.2.3
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=Library to implement a compact array of nibbles (4 bit). sentence=Library to implement a compact array of nibbles (4 bit).

View File

@ -1,7 +1,7 @@
// //
// FILE: nibbleArray.cpp // FILE: nibbleArray.cpp
// AUTHOR: Rob Tillaart // AUTHOR: Rob Tillaart
// VERSION: 0.2.2 // VERSION: 0.2.3
// PURPOSE: Arduino library for a compact array of nibbles (4 bits) // PURPOSE: Arduino library for a compact array of nibbles (4 bits)
// URL: https://github.com/RobTillaart/nibbleArray // URL: https://github.com/RobTillaart/nibbleArray
// //
@ -12,6 +12,7 @@
// 0.2.2 2020-11-10 update Arduino-CI, badges // 0.2.2 2020-11-10 update Arduino-CI, badges
// fix bug in setAll(); // fix bug in setAll();
// add memory(); // add memory();
// 0.2.3 2021-12-22 update library.json, readme, license, minor edits
#include "nibbleArray.h" #include "nibbleArray.h"
@ -75,4 +76,6 @@ void nibbleArray::setAll(uint8_t value)
memset(_arr, v, (_size + 1)/2); memset(_arr, v, (_size + 1)/2);
} }
// -- END OF FILE -- // -- END OF FILE --

View File

@ -2,7 +2,7 @@
// //
// FILE: nibbleArray.h // FILE: nibbleArray.h
// AUTHOR: Rob Tillaart // AUTHOR: Rob Tillaart
// VERSION: 0.2.2 // VERSION: 0.2.3
// PURPOSE: Arduino library for a compact array of nibbles (4 bits) // PURPOSE: Arduino library for a compact array of nibbles (4 bits)
// URL: https://github.com/RobTillaart/nibbleArray // URL: https://github.com/RobTillaart/nibbleArray
// //

View File

@ -38,6 +38,7 @@
unittest_setup() unittest_setup()
{ {
fprintf(stderr, "VERSION: %s\n", (char *) NIBBLEARRAY_LIB_VERSION);
} }
unittest_teardown() unittest_teardown()
@ -46,10 +47,16 @@ unittest_teardown()
} }
unittest(test_constants)
{
assertEqual(NIBBLEARRAY_MAXSIZE , 510 );
assertEqual(NIBBLEARRAY_OK , 0x00);
assertEqual(NIBBLEARRAY_ERROR_INDEX, 0xFF);
}
unittest(test_all) unittest(test_all)
{ {
fprintf(stderr, "VERSION: %s\n", (char *) NIBBLEARRAY_LIB_VERSION);
nibbleArray na(500); nibbleArray na(500);
assertEqual(500, na.size()); assertEqual(500, na.size());
assertEqual(250, na.memory()); assertEqual(250, na.memory());
@ -84,6 +91,7 @@ unittest(test_all)
} }
unittest_main() unittest_main()
// -------- // --------