got NetworkRobot actually working
diff --git a/aos/atom_code/input/joystick_input.cc b/aos/atom_code/input/joystick_input.cc
index 3c66606..c2b4d9c 100644
--- a/aos/atom_code/input/joystick_input.cc
+++ b/aos/atom_code/input/joystick_input.cc
@@ -50,9 +50,9 @@
{
using driver_station::JoystickFeature;
using driver_station::ButtonLocation;
- for (int joystick = 0; joystick < JoystickFeature::kJoysticks;
+ for (int joystick = 1; joystick <= JoystickFeature::kJoysticks;
++joystick) {
- for (int button = 0; button < ButtonLocation::kButtons; ++button) {
+ for (int button = 1; button <= ButtonLocation::kButtons; ++button) {
ButtonLocation location(joystick, button);
if (data.PosEdge(location)) {
LOG(INFO, "PosEdge(%d, %d)\n", joystick, button);
diff --git a/aos/common/Configuration.cpp b/aos/common/Configuration.cpp
index f379aac..2c9a7be 100644
--- a/aos/common/Configuration.cpp
+++ b/aos/common/Configuration.cpp
@@ -26,7 +26,7 @@
INFO,
WARNING,
ERROR = -1,
- FATAL,
+ FATAL = 4,
};
#define LOG(level, format, args...) do { \
fprintf(stderr, #level ": " format, ##args); \
diff --git a/aos/externals/WPILib/WPILib/NetworkRobot/NetworkRobotValues.h b/aos/externals/WPILib/WPILib/NetworkRobot/NetworkRobotValues.h
index 4b05c05..d02e8bd 100644
--- a/aos/externals/WPILib/WPILib/NetworkRobot/NetworkRobotValues.h
+++ b/aos/externals/WPILib/WPILib/NetworkRobot/NetworkRobotValues.h
@@ -83,7 +83,7 @@
}
// Returns whether or not we ran over the end.
- bool overrun() const { return current_index_ >= data_size_; }
+ bool overrun() const { return current_index_ > data_size_; }
private:
// Where we are reading or writing from. Not owned by this object.