Skip to content
Snippets Groups Projects
Commit a1f859a8 authored by RobertPatzke's avatar RobertPatzke
Browse files

Merge branch 'main' of https://lab.it.hs-hannover.de/streiten/soaap into main

parents 1edfe185 10a9852e
Branches
Tags
1 merge request!8Update Dev
Showing
with 1480 additions and 22 deletions
Zur Kompatibilität mit platformIO wurde die Datei testLoopCheck.txt umbenannt.
Wenn die Datei verwendet werden soll, muss die Dateiendung wieder auf .cpp geändert werden.
\ No newline at end of file
Zur Kompatibilität mit platformIO wurde die Datei testLoopCheck umbenannt. Zur Kompatibilität mit platformIO wurde die Datei testLoopCheck.txt umbenannt.
Wenn die Datei verwendet werden soll, muss die Dateiendung wieder auf .cpp geändert werden. Wenn die Datei verwendet werden soll, muss die Dateiendung wieder auf .cpp geändert werden.
\ No newline at end of file
...@@ -12,27 +12,29 @@ ...@@ -12,27 +12,29 @@
platform = nordicnrf52 platform = nordicnrf52
board = nano33ble board = nano33ble
framework = arduino framework = arduino
upload_port = COM3 ;upload_port = COM3
build_flags = build_flags =
-DsmnDEFBYBUILD -DsmnNANOBLE33 -DsmnDEBUG -DDegugTerminal -DsmnDEFBYBUILD -DsmnNANOBLE33 -DsmnDEBUG -DDebugTerminal
;Anstelle der relativen Pfade können auch lokale Syslinks verwendet werden(siehe unten). ;Anstelle der relativen Pfade können auch lokale Syslinks verwendet werden(siehe unten).
;Diese aber bitte NICHT committen! ;Diese aber bitte NICHT committen!
lib_deps = lib_deps =
..\..\..\..\libraries\BlePoll symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/LoopCheck
..\..\..\..\libraries\environment symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/BlePoll
..\..\..\..\libraries\ComRingBuf symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/environment
..\..\..\..\libraries\LoopCheck symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/ComRingBuf
..\..\..\..\libraries\MidiNotes symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/LoopCheck
..\..\..\..\libraries\Monitor symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/MidiNotes
..\..\..\..\libraries\nRF52840Gpio symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/Monitor
..\..\..\..\libraries\nRF52840Radio symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/nRF52840Gpio
..\..\..\..\libraries\nRF52840Ser symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/nRF52840Radio
..\..\..\..\libraries\nRF52840Twi symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/nRF52840Ser
..\..\..\..\libraries\SensorLSM9DS1 symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/nRF52840Twi
..\..\..\..\libraries\SoaapMsg symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/SensorLSM9DS1
..\..\..\..\libraries\StateMachine symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/SoaapMsg
..\..\..\..\libraries\nRF52840Adc symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/StateMachine
..\..\..\..\libraries\ProcMeas symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/nRF52840Adc
..\..\..\..\libraries\EulerAngles symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/ProcMeas
..\..\..\..\libraries\GpioCtrl symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/EulerAngles
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/GpioCtrl
;symlink://C:\Users\lenna\OneDrive\Dokumente\Git\SOAAP\libraries\SoaapComDue ;symlink://C:\Users\lenna\OneDrive\Dokumente\Git\SOAAP\libraries\SoaapComDue
;..\..\..\..\libraries\GpioCtrl
...@@ -102,7 +102,9 @@ StateMachine ap(apInit, NULL, appCycleTime); ...@@ -102,7 +102,9 @@ StateMachine ap(apInit, NULL, appCycleTime);
// aufgerufen wird. // aufgerufen wird.
// <smCycleTime> Die Zukluszeit (Takt) der Zustandsmaschine in Mikrosekunden // <smCycleTime> Die Zukluszeit (Takt) der Zustandsmaschine in Mikrosekunden
#ifndef DebugTerminal
#define DebugTerminal
#endif
#ifdef DebugTerminal #ifdef DebugTerminal
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// Zum Debuggen und weitere Analysen der Programmumgebung und Funktionstests // Zum Debuggen und weitere Analysen der Programmumgebung und Funktionstests
......
This directory is intended for project header files.
A header file is a file containing C declarations and macro definitions
to be shared between several project source files. You request the use of a
header file in your project source file (C, C++, etc) located in `src` folder
by including it, with the C preprocessing directive `#include'.
```src/main.c
#include "header.h"
int main (void)
{
...
}
```
Including a header file produces the same results as copying the header file
into each source file that needs it. Such copying would be time-consuming
and error-prone. With a header file, the related declarations appear
in only one place. If they need to be changed, they can be changed in one
place, and programs that include the header file will automatically use the
new version when next recompiled. The header file eliminates the labor of
finding and changing all the copies as well as the risk that a failure to
find one copy will result in inconsistencies within a program.
In C, the usual convention is to give header files names that end with `.h'.
It is most portable to use only letters, digits, dashes, and underscores in
header file names, and at most one dot.
Read more about using header files in official GCC documentation:
* Include Syntax
* Include Operation
* Once-Only Headers
* Computed Includes
https://gcc.gnu.org/onlinedocs/cpp/Header-Files.html
This directory is intended for project specific (private) libraries.
PlatformIO will compile them to static libraries and link into executable file.
The source code of each library should be placed in a an own separate directory
("lib/your_library_name/[here are source files]").
For example, see a structure of the following two libraries `Foo` and `Bar`:
|--lib
| |
| |--Bar
| | |--docs
| | |--examples
| | |--src
| | |- Bar.c
| | |- Bar.h
| | |- library.json (optional, custom build options, etc) https://docs.platformio.org/page/librarymanager/config.html
| |
| |--Foo
| | |- Foo.c
| | |- Foo.h
| |
| |- README --> THIS FILE
|
|- platformio.ini
|--src
|- main.c
and a contents of `src/main.c`:
```
#include <Foo.h>
#include <Bar.h>
int main (void)
{
...
}
```
PlatformIO Library Dependency Finder will find automatically dependent
libraries scanning project source files.
More information about PlatformIO Library Dependency Finder
- https://docs.platformio.org/page/librarymanager/ldf.html
[env:nano33ble]
platform = nordicnrf52
board = nano33ble
framework = arduino
;upload_port = COM3
build_flags =
-DsmnDEFBYBUILD -DsmnNANOBLE33 -DsmnDEBUG -DDebugTerminal
;Anstelle der relativen Pfade können auch lokale Syslinks verwendet werden(siehe unten).
;Diese aber bitte NICHT committen!
lib_deps =
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/LoopCheck
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/BlePoll
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/environment
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/ComRingBuf
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/LoopCheck
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/MidiNotes
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/Monitor
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/nRF52840Gpio
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/nRF52840Radio
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/nRF52840Ser
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/nRF52840Twi
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/SensorLSM9DS1
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/SoaapMsg
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/StateMachine
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/nRF52840Adc
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/ProcMeas
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/EulerAngles
symlink:///home/lennardkarger/Dokumente/Git_local/soaap/libraries/GpioCtrl
;symlink://C:\Users\lenna\OneDrive\Dokumente\Git\SOAAP\libraries\SoaapComDue
;..\..\..\..\libraries\GpioCtrl
/*
* SoaapBleSlave.h
*
* Created on: 26.04.2022
* Author: robert
*/
#ifndef SoaapBleSlave_h
#define SoaapBleSlave_h
//#define DebugTerminal
// Mit dieser Definition werden die Klasse Monitor und weitere Testmethoden
// eingebunden, womit ein anwendungsorientiertes Debugging möglich ist
// Dieser Schalter wird in der Regel in der Umgebung des Projektes beim
// Entwicklungssystem gesetzt (z.B. Arduino Compile Options bei Eclipse/Sloeber)
#include "LoopCheck.h"
#include "StateMachine.h"
#include "nRF52840Gpio.h"
#include "GpioCtrl.h"
#include "nRF52840Twi.h"
#include "SensorLSM9DS1.h"
#include "nRF52840Radio.h"
#include "BlePoll.h"
#include "ProcMeas.h"
#include "nRF52840Adc.h"
#ifdef DebugTerminal
#include "Monitor.h"
#endif
bool getValues(PlpType plpType, byte *dest);
bool xchgCtrl(PlpType plpType, byte *dest, byte *src, int sSize);
#ifdef DebugTerminal
void smInit() ;
void smCheckJobs() ;
void smDebDword() ;
void smCtrlPolling() ;
void smWaitPolling() ;
void smCheckSens() ;
void smSensHelp();
void smSensReset1() ;
void smSensReset2() ;
void smSensGetValues1() ;
void smSensGetValues2() ;
void smSensGetValues3() ;
void smSensGetValues4() ;
void smSensGetValues5() ;
void smSensGetValues6() ;
void smSensGetValues7() ;
void smSensGetAngleValues();
void smSensCheckAngleValues();
void smSensGetSoaapValues() ;
void smSensDebugValues() ;
void smSensGetErrors() ;
void smDebugProcMeas();
void smSensGetTimeOuts() ;
void smSensGetRunCounts() ;
void smTestIO();
void smTempTesting();
void smTestAdcMem();
#endif
#endif // SoaapBleSlave_h
This diff is collapsed.
This directory is intended for PlatformIO Test Runner and project tests.
Unit Testing is a software testing method by which individual units of
source code, sets of one or more MCU program modules together with associated
control data, usage procedures, and operating procedures, are tested to
determine whether they are fit for use. Unit testing finds problems early
in the development cycle.
More information about PlatformIO Unit Testing:
- https://docs.platformio.org/en/latest/advanced/unit-testing/index.html
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment