From 3f6835ac94b1bc26ed8786dc19e7002c21cd0ec4 Mon Sep 17 00:00:00 2001 From: u-siri-ous Date: Mon, 20 Jan 2020 18:57:14 +0100 Subject: [PATCH] aaaaaaa --- include/data_source_camera.h | 6 +++--- src/data_source_camera.cpp | 26 ++++++++++++++++++++++++-- 2 files changed, 27 insertions(+), 5 deletions(-) diff --git a/include/data_source_camera.h b/include/data_source_camera.h index 18d1c50..c2a8a5e 100755 --- a/include/data_source_camera.h +++ b/include/data_source_camera.h @@ -1,7 +1,7 @@ #pragma once -#define startp 0b01111111 -#define endp 0b10000000 -#define unkn 0b01101001 +#define startp 105 +#define endp 115 +//#define unkn 0b01101001 #include "data_source.h" class DataSourceCamera : public DataSource{ diff --git a/src/data_source_camera.cpp b/src/data_source_camera.cpp index 82f44ee..51b2a94 100755 --- a/src/data_source_camera.cpp +++ b/src/data_source_camera.cpp @@ -174,14 +174,36 @@ int DataSourceCamera::getValueDef(bool fixed){ void DataSourceCamera::test(){ goalOrientation = digitalRead(SWITCH_SX); //se HIGH attacco gialla, difendo blu - DEBUG.print(pAtk); +/* DEBUG.print(pAtk); DEBUG.print(" | "); DEBUG.print(fixCamIMU(pAtk)); DEBUG.print(" --- "); DEBUG.print(pDef); DEBUG.print(" | "); - DEBUG.println(fixCamIMU(pDef)); + DEBUG.println(fixCamIMU(pDef)); */ + update(); + DEBUG.print(xb); + DEBUG.print("|"); + delay(100); + DEBUG.print(yb); + DEBUG.print("|"); + delay(100); + DEBUG.print(xy); + DEBUG.print("|"); + delay(100); + DEBUG.print(yy); + DEBUG.println("---------------"); + DEBUG.print(true_xb); + DEBUG.print("|"); + delay(100); + DEBUG.print(true_yb); + DEBUG.print("|"); + delay(100); + DEBUG.print(true_xy); + DEBUG.print("|"); + delay(100); + DEBUG.print(true_yy); } int DataSourceCamera::fixCamIMU(int d){