Create a function to populate a SZSDPS goal

This lets us do the equivalent of
CreateStaticZeroingSingleDOFProfiledSubsystemGoal but for static
buffers.

Signed-off-by: Maxwell Henderson <mxwhenderson@gmail.com>
Change-Id: I194b0fd9601bc9f44b6ced59835fb2fee57ac08c
diff --git a/frc971/control_loops/static_zeroing_single_dof_profiled_subsystem.h b/frc971/control_loops/static_zeroing_single_dof_profiled_subsystem.h
index b26f69c..05a011a 100644
--- a/frc971/control_loops/static_zeroing_single_dof_profiled_subsystem.h
+++ b/frc971/control_loops/static_zeroing_single_dof_profiled_subsystem.h
@@ -3,11 +3,27 @@
 
 #include "aos/flatbuffer_merge.h"
 #include "frc971/control_loops/profiled_subsystem.h"
+#include "frc971/control_loops/profiled_subsystem_static.h"
 #include "frc971/control_loops/state_feedback_loop_converters.h"
 
 namespace frc971 {
 namespace control_loops {
 
+inline void PopulateStaticZeroingSingleDOFProfiledSubsystemGoal(
+    StaticZeroingSingleDOFProfiledSubsystemGoalStatic *goal_table,
+    double unsafe_goal = 0.0, float max_velocity = 0.0,
+    float max_acceleration = 0.0, double goal_velocity = 0.0,
+    bool ignore_profile = false) {
+  goal_table->set_unsafe_goal(unsafe_goal);
+  goal_table->set_goal_velocity(goal_velocity);
+  goal_table->set_ignore_profile(ignore_profile);
+
+  frc971::ProfileParametersStatic *profile_parameters =
+      goal_table->add_profile_params();
+  profile_parameters->set_max_velocity(max_velocity);
+  profile_parameters->set_max_acceleration(max_acceleration);
+}
+
 template <typename ZeroingEstimator>
 struct StaticZeroingSingleDOFProfiledSubsystemParams {
   // Maximum voltage while the subsystem is zeroing