diff --git a/docs/documentation/diagrams/UML-esp8266.md b/docs/documentation/diagrams/UML-esp8266.md new file mode 100644 index 0000000..bc7fad5 --- /dev/null +++ b/docs/documentation/diagrams/UML-esp8266.md @@ -0,0 +1,61 @@ +# UML esp8266 diagram + +```mermaid +classDiagram + +Connectivity --> Movement-sensor-code +SensorManager --> Movement-sensor-code +namespace ESP8266 { + + class Movement-sensor-code { + + struct RotationQuaternion + + PepperIP + setup() + loop() + connectWifi() + sensorSetup() + getPepperIP() + httpPost() + } + + class Connectivity { + + void connectWiFi(char* ssid, char* pass) + + void websocketSetup(char* ip, uint16_t port, char* adress) + + void sendData(float roll, float pitch, float yaw); + + int httpPost(const char *serverAddress, const char *serverSubPath, const unsigned short serverPort, const + char *data, const size_t dataLength, const char *contentType) + + const char* fetchIPAddress() + + -ESP8266WiFiMulti wifi; + -WiFiClient wifi_client; + } + + class SensorManager { + + struct eulerAngles( + float roll; + float pitch; + float yaw; + ); + + struct acceleration ( + float x; + float y; + float z; + ); + + eulerAngles getEulerAngles() + + acceleration getAcelleration() + + bool sensorTap() + + + - struct RotationQuaternions ( + float i; + float j; + float k; + float w; + ); + - RotationQuaternions getQuaternions() + + - BNO080 myIMU + } + + +} +``` \ No newline at end of file