Merge changes I88ffb186,I7454d910
* changes:
Merge commit '0c66e38927073da588abe5d596ab9240c24519fe' as 'third_party/cimg'
Squashed 'third_party/cimg/' content from commit 4b66369
diff --git a/y2019/jevois/deploy_teensy.sh b/y2019/jevois/deploy_teensy.sh
new file mode 100755
index 0000000..50d0571
--- /dev/null
+++ b/y2019/jevois/deploy_teensy.sh
@@ -0,0 +1,5 @@
+#!/bin/bash
+
+cd "$(dirname "${BASH_SOURCE[0]}")"
+
+bazel build --cpu=cortex-m4f -c opt //y2019/jevois:teensy.hex -s && bazel run //motors/teensy_loader_cli -- --mcu=mk64fx512 -s $(readlink -f ../../bazel-bin/y2019/jevois/teensy.hex)
diff --git a/y2019/jevois/teensy.cc b/y2019/jevois/teensy.cc
index 7a0eb45..982e04b 100644
--- a/y2019/jevois/teensy.cc
+++ b/y2019/jevois/teensy.cc
@@ -673,6 +673,8 @@
CameraCommand last_roborio_camera_command = CameraCommand::kNormal;
DebugLight teensy_debug_light;
+ bool verbose = false;
+
bool first = true;
while (true) {
{
@@ -711,6 +713,10 @@
UartUnpackToTeensy(packetizers[i].received_packet());
packetizers[i].clear_received_packet();
if (decoded) {
+ if (verbose) {
+ printf("uart frame cam %d, %d targets\n", (int)i,
+ (int)decoded->targets.size());
+ }
frame_queue.UpdateFrame(i, *decoded);
light_rings[i].last_frame = aos::monotonic_clock::now();
} else {
@@ -805,6 +811,10 @@
CameraSerialNumbers()[i]);
}
break;
+ case 'v':
+ printf("Toggling verbose mode\n");
+ verbose = !verbose;
+ break;
case 'h':
printf("UART board commands:\n");
printf(" p: Send passthrough mode\n");
@@ -812,6 +822,7 @@
printf(" n: Send normal mode\n");
printf(" a: Send all-'a' mode\n");
printf(" c: Dump camera configuration\n");
+ printf(" v: Toggle verbose print\n");
break;
default:
printf("Unrecognized character\n");