diff --git a/LICENSE b/LICENSE index b3a1e7e..f48d982 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2024 Andreas Merkle +Copyright (c) 2023 - 2025 Andreas Merkle Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index 90813d8..4ef3487 100644 --- a/README.md +++ b/README.md @@ -8,59 +8,68 @@ Projects have sometimes the need to run on different platforms. For example a ro This library provides for this use case some Arduino interfaces, but not all yet. If something is missing, feel free to contribute, which make our all lifes easier. :-) -## Table of content +## Table of content -* [Architecture](#architecture) - * [The Principle](#the-principle) - * [Detail](#detail) -* [How to integrate the library?](#how-to-integrate-the-library) - * [Example](#example) -* [Used Libraries](#used-libraries) -* [Issues, Ideas And Bugs](#issues-ideas-and-bugs) -* [License](#license) -* [Contribution](#contribution) +- [Architecture](#architecture) + - [The Principle](#the-principle) + - [Detail](#detail) +- [How to integrate the library?](#how-to-integrate-the-library) + - [Example](#example) +- [Used Libraries](#used-libraries) +- [Issues, Ideas And Bugs](#issues-ideas-and-bugs) +- [License](#license) +- [Contribution](#contribution) -# Architecture +## Architecture -## The Principle +### The Principle ![Principle](http://www.plantuml.com/plantuml/proxy?cache=no&src=https://raw.githubusercontent.com//BlueAndi/ArduinoNative/master/doc/uml/Principle.plantuml) -## Detail +### Detail ![ArduinoNative](http://www.plantuml.com/plantuml/proxy?cache=no&src=https://raw.githubusercontent.com/BlueAndi/ArduinoNative/master/doc/uml/ArduinoNative.plantuml) ![DynamicFlow](http://www.plantuml.com/plantuml/proxy?cache=no&src=https://raw.githubusercontent.com/BlueAndi/ArduinoNative/master/doc/uml/DynamicFlow.plantuml) -# How to integrate the library? +## How to integrate the library? + 1. Add it to the _platformio.ini_ in your environment to the _lib\_deps_ section: - ``` + + ```text lib_deps = - BlueAndi/ArduinoNative @ ~0.1.0 + BlueAndi/ArduinoNative @ ~0.2.2 ``` + 2. Add this build flags to your _platformio.ini_ in your environment: - ``` + + ```text build_flags = -D _USE_MATH_DEFINES ``` + 3. Call the ```Arduino::setup()``` once and the ```Arduino::loop()``` in a infinite loop in your main entry point function. -## Example +### Example + See [minimal example](./examples/example/). -# Used Libraries +## Used Libraries | Library | Description | License | | ------------------------------------------------------------------ | ---------------------------------------------------------------- | ---------- | | - | - | - | -# Issues, Ideas And Bugs +## Issues, Ideas And Bugs + If you have further ideas or you found some bugs, great! Create a [issue](https://github.com/BlueAndi/ArduinoNative/issues) or if you are able and willing to fix it by yourself, clone the repository and create a pull request. -# License +## License + The whole source code is published under the [MIT license](http://choosealicense.com/licenses/mit/). Consider the different licenses of the used third party libraries too! -# Contribution +## Contribution + Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, shall be licensed as above, without any additional terms or conditions. diff --git a/doc/doxygen/Doxyfile b/doc/doxygen/Doxyfile index 65c7254..fcd3ee0 100644 --- a/doc/doxygen/Doxyfile +++ b/doc/doxygen/Doxyfile @@ -48,7 +48,7 @@ PROJECT_NAME = "ArduinoNative" # could be handy for archiving the generated documentation or if some version # control system is used. -PROJECT_NUMBER = v0.1.0 +PROJECT_NUMBER = v0.2.2 # Using the PROJECT_BRIEF tag one can provide an optional one line description # for a project that appears at the top of each page and should give viewer a diff --git a/examples/example/LICENSE b/examples/example/LICENSE index 6b991e9..7bae39a 100644 --- a/examples/example/LICENSE +++ b/examples/example/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2023 - 2024 Andreas Merkle +Copyright (c) 2023 - 2025 Andreas Merkle Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/examples/example/lib/MainNative/src/main.cpp b/examples/example/lib/MainNative/src/main.cpp index d734861..6f9e58d 100644 --- a/examples/example/lib/MainNative/src/main.cpp +++ b/examples/example/lib/MainNative/src/main.cpp @@ -1,6 +1,6 @@ /* MIT License * - * Copyright (c) 2023 - 2024 Andreas Merkle + * Copyright (c) 2023 - 2025 Andreas Merkle * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/examples/example/platformio.ini b/examples/example/platformio.ini index 3207351..11755ec 100644 --- a/examples/example/platformio.ini +++ b/examples/example/platformio.ini @@ -19,4 +19,4 @@ build_flags = -D _USE_MATH_DEFINES lib_deps = MainNative - BlueAndi/ArduinoNative @ ~0.1.1 + BlueAndi/ArduinoNative @ ~0.2.2 diff --git a/examples/example/src/main.cpp b/examples/example/src/main.cpp index 99073b2..f3cae5f 100644 --- a/examples/example/src/main.cpp +++ b/examples/example/src/main.cpp @@ -1,6 +1,6 @@ /* MIT License * - * Copyright (c) 2023 - 2024 Andreas Merkle + * Copyright (c) 2023 - 2025 Andreas Merkle * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/library.json b/library.json index e842ca8..8819f25 100644 --- a/library.json +++ b/library.json @@ -1,6 +1,6 @@ { "name": "ArduinoNative", - "version": "0.2.1", + "version": "0.2.2", "description": "Arduino for the native environment. It doesn't support every interface, just some of them!", "authors": [{ "name": "Andreas Merkle", diff --git a/src/Arduino.cpp b/src/Arduino.cpp index 9e151b6..b18b15f 100644 --- a/src/Arduino.cpp +++ b/src/Arduino.cpp @@ -1,6 +1,6 @@ /* MIT License * - * Copyright (c) 2023 - 2024 Andreas Merkle + * Copyright (c) 2023 - 2025 Andreas Merkle * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/Arduino.h b/src/Arduino.h index 84f2287..8cd2188 100644 --- a/src/Arduino.h +++ b/src/Arduino.h @@ -1,6 +1,6 @@ /* MIT License * - * Copyright (c) 2023 - 2024 Andreas Merkle + * Copyright (c) 2023 - 2025 Andreas Merkle * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/Print.h b/src/Print.h index 46cc995..696f4f1 100644 --- a/src/Print.h +++ b/src/Print.h @@ -1,6 +1,6 @@ /* MIT License * - * Copyright (c) 2023 - 2024 Andreas Merkle + * Copyright (c) 2023 - 2025 Andreas Merkle * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/Serial.cpp b/src/Serial.cpp index b1a2176..bc689ae 100644 --- a/src/Serial.cpp +++ b/src/Serial.cpp @@ -1,6 +1,6 @@ /* MIT License * - * Copyright (c) 2023 - 2024 Andreas Merkle + * Copyright (c) 2023 - 2025 Andreas Merkle * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/Serial.h b/src/Serial.h index 45ca8f1..423aac0 100644 --- a/src/Serial.h +++ b/src/Serial.h @@ -1,6 +1,6 @@ /* MIT License * - * Copyright (c) 2023 - 2024 Andreas Merkle + * Copyright (c) 2023 - 2025 Andreas Merkle * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/Stream.h b/src/Stream.h index 204d83b..1c5b727 100644 --- a/src/Stream.h +++ b/src/Stream.h @@ -1,6 +1,6 @@ /* MIT License * - * Copyright (c) 2023 - 2024 Andreas Merkle + * Copyright (c) 2023 - 2025 Andreas Merkle * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/Terminal.cpp b/src/Terminal.cpp index 205475d..792316e 100644 --- a/src/Terminal.cpp +++ b/src/Terminal.cpp @@ -1,6 +1,6 @@ /* MIT License * - * Copyright (c) 2023 - 2024 Andreas Merkle + * Copyright (c) 2023 - 2025 Andreas Merkle * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/Terminal.h b/src/Terminal.h index a55cf13..13e7c8d 100644 --- a/src/Terminal.h +++ b/src/Terminal.h @@ -1,6 +1,6 @@ /* MIT License * - * Copyright (c) 2023 - 2024 Andreas Merkle + * Copyright (c) 2023 - 2025 Andreas Merkle * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/WString.h b/src/WString.h index 6253b76..1183977 100644 --- a/src/WString.h +++ b/src/WString.h @@ -1,6 +1,6 @@ /* MIT License * - * Copyright (c) 2023 - 2024 Andreas Merkle + * Copyright (c) 2023 - 2025 Andreas Merkle * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -96,7 +96,7 @@ class String * * @param[in] other String to copy */ - String(const char* other) : m_stdStr(other) + String(const char* other) : m_stdStr((nullptr == other) ? "" : other) { } @@ -115,7 +115,7 @@ class String * @param[in] other String to copy * @param[in] length Number of characters to copy */ - String(const char* other, unsigned int length) : m_stdStr(other, length) + String(const char* other, unsigned int length) : m_stdStr((nullptr == other) ? "" : std::string(other, length)) { } diff --git a/test/test_Wstring/test_WString.cpp b/test/test_Wstring/test_WString.cpp index 811a53a..a6ce123 100644 --- a/test/test_Wstring/test_WString.cpp +++ b/test/test_Wstring/test_WString.cpp @@ -1,6 +1,6 @@ /* MIT License * - * Copyright (c) 2023 - 2024 Andreas Merkle + * Copyright (c) 2023 - 2025 Andreas Merkle * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal