Skip to content

Commit

Permalink
Integrated into pub workspace
Browse files Browse the repository at this point in the history
  • Loading branch information
Gold872 committed Dec 20, 2024
1 parent 27b8e37 commit f262e96
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 494 deletions.
8 changes: 4 additions & 4 deletions lib/src/interfaces/video.dart
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import "package:autonomy/interfaces.dart";
import "package:burt_network/generated.dart";
import "package:burt_network/protobuf.dart";

/// Handles obstacle detection data and ArUco data from video
abstract class VideoInterface extends Service with Receiver {
bool flag = false;
bool flag = false;

final AutonomyInterface collection;
VideoInterface({required this.collection});
Expand All @@ -12,6 +12,6 @@ bool flag = false;

void updateFrame(VideoData newData);

double get arucoSize => data.arucoSize;
double get arucoPosition => data.arucoPosition;
// double get arucoSize => data.arucoSize;
// double get arucoPosition => data.arucoPosition;
}
10 changes: 5 additions & 5 deletions lib/src/rover/video.dart
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ class RoverVideo extends VideoInterface {
@override
void updateFrame(VideoData newData) {
data = newData;
if (data.arucoDetected == BoolState.YES) {
flag = true;
Timer(const Duration(seconds: 3), () => flag = false);
collection.logger.info("Is ArUco detected: ${data.arucoDetected}");
}
// if (data.arucoDetected == BoolState.YES) {
// flag = true;
// Timer(const Duration(seconds: 3), () => flag = false);
// collection.logger.info("Is ArUco detected: ${data.arucoDetected}");
// }
hasValue = true;
}
}
Loading

0 comments on commit f262e96

Please sign in to comment.