added FIFOdata fetch method

This commit is contained in:
hhaupt 2024-06-13 23:35:17 +02:00
parent d4cb8af3b3
commit 4f308412e4
3 changed files with 7 additions and 27 deletions

View File

@ -12,14 +12,13 @@
#include "Dezibot.h" #include "Dezibot.h"
MotionDetection motionDetection;
static MotionDetection* motionDetectionPTR = &motionDetection;
Dezibot::Dezibot():multiColorLight(){ Dezibot::Dezibot():multiColorLight(){
}; };
void Dezibot::begin(void) { void Dezibot::begin(void) {
//motion.begin(); motion.begin();
multiColorLight.begin(); multiColorLight.begin();
//motionDetection.begin(); motionDetection.begin();
Wire.begin(1,2); Wire.begin(1,2);
}; };

View File

@ -19,37 +19,18 @@
#include "Arduino.h" #include "Arduino.h"
#include "Wire.h" #include "Wire.h"
extern static MotionDetection* motionDetectionPTR;
class Dezibot { class Dezibot {
protected: protected:
void setIMU(Motion& m){
m.imuInst = motionDetection;
};
public: public:
Dezibot(); Dezibot();
LightDetection lightDetection; LightDetection lightDetection;
ColorDetection colorDetection; ColorDetection colorDetection;
MultiColorLight multiColorLight; MultiColorLight multiColorLight;
Motion motion = Motion(motionDetectionPTR); Motion motion ;
static MotionDetection motionDetection = *motionDetectionPTR; MotionDetection motionDetection;
void begin(void); void begin(void);
/*
Display display
IRCommuncation irCommuncation (beinhaltet Kommuniaktion / Annhärung...)
Battery battery
Extension extension
WiFi wifi //wie wird WiFi geschrieben?
//nur lesender Zugriff, in dieser Klasse sind andere Instanzen mit dem Dezibotinterface gekapselt
Friends friends
OperatingSystem operatingSystem
USBCommunication usbCommunication
Button button
//nicht unique, initzial Dezibot
String robotName
*/
}; };
#endif //Dezibot_h #endif //Dezibot_h

View File

@ -1,7 +1,7 @@
#include "MotionDetection.h" #include "MotionDetection.h"
#include <math.h> #include <math.h>
MotionDetection::MotionDetection(){//:handler(FSPI){ MotionDetection::MotionDetection(){
handler = new SPIClass(FSPI); handler = new SPIClass(FSPI);
}; };