Fixed issue with angle optimization

This commit is contained in:
thenetworkgrinch
2023-08-29 19:59:07 -05:00
parent 38c7bdba7d
commit 12f6e0ed38
138 changed files with 8913 additions and 1020 deletions

View File

@@ -1,17 +1,18 @@
<!DOCTYPE HTML>
<html lang="en">
<head>
<!-- Generated by javadoc (17) -->
<title>PhysicalPropertiesJson (YAGSL-Lib API)</title>
<!-- Generated by javadoc (17) on Tue Aug 29 19:54:45 CDT 2023 -->
<title>PhysicalPropertiesJson</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="dc.created" content="2023-08-29">
<meta name="description" content="declaration: package: swervelib.parser.json, class: PhysicalPropertiesJson">
<meta name="generator" content="javadoc/ClassWriterImpl">
<link rel="stylesheet" type="text/css" href="../../../stylesheet.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../script-dir/jquery-ui.min.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../jquery-ui.overrides.css" title="Style">
<script type="text/javascript" src="../../../script.js"></script>
<script type="text/javascript" src="../../../script-dir/jquery-3.6.1.min.js"></script>
<script type="text/javascript" src="../../../script-dir/jquery-3.5.1.min.js"></script>
<script type="text/javascript" src="../../../script-dir/jquery-ui.min.js"></script>
</head>
<body class="class-declaration-page">
@@ -35,7 +36,7 @@ loadScripts(document, 'script');</script>
<li><a href="package-summary.html">Package</a></li>
<li class="nav-bar-cell1-rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../index-all.html">Index</a></li>
<li><a href="../../../index-files/index-1.html">Index</a></li>
<li><a href="../../../help-doc.html#class">Help</a></li>
</ul>
</div>
@@ -77,8 +78,7 @@ loadScripts(document, 'script');</script>
<hr>
<div class="type-signature"><span class="modifiers">public class </span><span class="element-name type-name-label">PhysicalPropertiesJson</span>
<span class="extends-implements">extends <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a></span></div>
<div class="block"><a href="../SwerveModulePhysicalCharacteristics.html" title="class in swervelib.parser"><code>SwerveModulePhysicalCharacteristics</code></a> parsed data. Used to configure the
SwerveModule.</div>
<div class="block"><a href="../SwerveModulePhysicalCharacteristics.html" title="class in swervelib.parser"><code>SwerveModulePhysicalCharacteristics</code></a> parsed data. Used to configure the SwerveModule.</div>
</section>
<section class="summary">
<ul class="summary-list">
@@ -94,33 +94,30 @@ loadScripts(document, 'script');</script>
<div class="col-first even-row-color"><code>double</code></div>
<div class="col-second even-row-color"><code><a href="#angleMotorFreeSpeedRPM" class="member-name-link">angleMotorFreeSpeedRPM</a></code></div>
<div class="col-last even-row-color">
<div class="block">DEPRECATED: No longer needed, tune <a href="#moduleFeedForwardClosedLoop"><code>moduleFeedForwardClosedLoop</code></a>
instead.</div>
<div class="block">DEPRECATED: No longer needed, tune <a href="#moduleFeedForwardClosedLoop"><code>moduleFeedForwardClosedLoop</code></a> instead.</div>
</div>
<div class="col-first odd-row-color"><code>swervelib.parser.json.MotorConfigInt</code></div>
<div class="col-first odd-row-color"><code><a href="MotorConfigInt.html" title="class in swervelib.parser.json">MotorConfigInt</a></code></div>
<div class="col-second odd-row-color"><code><a href="#currentLimit" class="member-name-link">currentLimit</a></code></div>
<div class="col-last odd-row-color">
<div class="block">The current limit in AMPs to apply to the motors.</div>
</div>
<div class="col-first even-row-color"><code>swervelib.parser.json.MotorConfigInt</code></div>
<div class="col-first even-row-color"><code><a href="MotorConfigInt.html" title="class in swervelib.parser.json">MotorConfigInt</a></code></div>
<div class="col-second even-row-color"><code><a href="#encoderPulsePerRotation" class="member-name-link">encoderPulsePerRotation</a></code></div>
<div class="col-last even-row-color">
<div class="block">Encoder pulse per rotation for non-integrated encoders.</div>
</div>
<div class="col-first odd-row-color"><code>swervelib.parser.json.MotorConfigDouble</code></div>
<div class="col-first odd-row-color"><code><a href="MotorConfigDouble.html" title="class in swervelib.parser.json">MotorConfigDouble</a></code></div>
<div class="col-second odd-row-color"><code><a href="#gearRatio" class="member-name-link">gearRatio</a></code></div>
<div class="col-last odd-row-color">
<div class="block">Gear ratio for the motors, number of times the motor has to spin before the wheel rotates a
single time.</div>
<div class="block">Gear ratio for the motors, number of times the motor has to spin before the wheel rotates a single time.</div>
</div>
<div class="col-first even-row-color"><code>double</code></div>
<div class="col-second even-row-color"><code><a href="#moduleFeedForwardClosedLoop" class="member-name-link">moduleFeedForwardClosedLoop</a></code></div>
<div class="col-last even-row-color">
<div class="block">Angle motor kV used for second order kinematics to tune the feedforward, this variable should
be adjusted so that your drive train does not drift towards the direction you are rotating
while you translate.</div>
<div class="block">Angle motor kV used for second order kinematics to tune the feedforward, this variable should be adjusted so that
your drive train does not drift towards the direction you are rotating while you translate.</div>
</div>
<div class="col-first odd-row-color"><code>swervelib.parser.json.MotorConfigDouble</code></div>
<div class="col-first odd-row-color"><code><a href="MotorConfigDouble.html" title="class in swervelib.parser.json">MotorConfigDouble</a></code></div>
<div class="col-second odd-row-color"><code><a href="#rampRate" class="member-name-link">rampRate</a></code></div>
<div class="col-last odd-row-color">
<div class="block">The minimum number of seconds to take for the motor to go from 0 to full throttle.</div>
@@ -194,29 +191,28 @@ loadScripts(document, 'script');</script>
<li>
<section class="detail" id="gearRatio">
<h3>gearRatio</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">swervelib.parser.json.MotorConfigDouble</span>&nbsp;<span class="element-name">gearRatio</span></div>
<div class="block">Gear ratio for the motors, number of times the motor has to spin before the wheel rotates a
single time.</div>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type"><a href="MotorConfigDouble.html" title="class in swervelib.parser.json">MotorConfigDouble</a></span>&nbsp;<span class="element-name">gearRatio</span></div>
<div class="block">Gear ratio for the motors, number of times the motor has to spin before the wheel rotates a single time.</div>
</section>
</li>
<li>
<section class="detail" id="encoderPulsePerRotation">
<h3>encoderPulsePerRotation</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">swervelib.parser.json.MotorConfigInt</span>&nbsp;<span class="element-name">encoderPulsePerRotation</span></div>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type"><a href="MotorConfigInt.html" title="class in swervelib.parser.json">MotorConfigInt</a></span>&nbsp;<span class="element-name">encoderPulsePerRotation</span></div>
<div class="block">Encoder pulse per rotation for non-integrated encoders. 1 for integrated encoders.</div>
</section>
</li>
<li>
<section class="detail" id="currentLimit">
<h3>currentLimit</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">swervelib.parser.json.MotorConfigInt</span>&nbsp;<span class="element-name">currentLimit</span></div>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type"><a href="MotorConfigInt.html" title="class in swervelib.parser.json">MotorConfigInt</a></span>&nbsp;<span class="element-name">currentLimit</span></div>
<div class="block">The current limit in AMPs to apply to the motors.</div>
</section>
</li>
<li>
<section class="detail" id="rampRate">
<h3>rampRate</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">swervelib.parser.json.MotorConfigDouble</span>&nbsp;<span class="element-name">rampRate</span></div>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type"><a href="MotorConfigDouble.html" title="class in swervelib.parser.json">MotorConfigDouble</a></span>&nbsp;<span class="element-name">rampRate</span></div>
<div class="block">The minimum number of seconds to take for the motor to go from 0 to full throttle.</div>
</section>
</li>
@@ -224,26 +220,23 @@ loadScripts(document, 'script');</script>
<section class="detail" id="wheelGripCoefficientOfFriction">
<h3>wheelGripCoefficientOfFriction</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">double</span>&nbsp;<span class="element-name">wheelGripCoefficientOfFriction</span></div>
<div class="block">The grip tape coefficient of friction on carpet. Used to calculate the practical maximum
acceleration.</div>
<div class="block">The grip tape coefficient of friction on carpet. Used to calculate the practical maximum acceleration.</div>
</section>
</li>
<li>
<section class="detail" id="moduleFeedForwardClosedLoop">
<h3>moduleFeedForwardClosedLoop</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">double</span>&nbsp;<span class="element-name">moduleFeedForwardClosedLoop</span></div>
<div class="block">Angle motor kV used for second order kinematics to tune the feedforward, this variable should
be adjusted so that your drive train does not drift towards the direction you are rotating
while you translate. Default value is 0. If robot arcs while translating and rotating negate
this.</div>
<div class="block">Angle motor kV used for second order kinematics to tune the feedforward, this variable should be adjusted so that
your drive train does not drift towards the direction you are rotating while you translate. Default value is 0. If
robot arcs while translating and rotating negate this.</div>
</section>
</li>
<li>
<section class="detail" id="angleMotorFreeSpeedRPM">
<h3>angleMotorFreeSpeedRPM</h3>
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">double</span>&nbsp;<span class="element-name">angleMotorFreeSpeedRPM</span></div>
<div class="block">DEPRECATED: No longer needed, tune <a href="#moduleFeedForwardClosedLoop"><code>moduleFeedForwardClosedLoop</code></a>
instead.</div>
<div class="block">DEPRECATED: No longer needed, tune <a href="#moduleFeedForwardClosedLoop"><code>moduleFeedForwardClosedLoop</code></a> instead.</div>
</section>
</li>
</ul>
@@ -275,8 +268,7 @@ loadScripts(document, 'script');</script>
<div class="block">Create the physical characteristics based off the parsed data.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>optimalVoltage</code> - Optimal voltage to compensate for and use to calculate drive motor
feedforward.</dd>
<dd><code>optimalVoltage</code> - Optimal voltage to compensate for and use to calculate drive motor feedforward.</dd>
<dt>Returns:</dt>
<dd><a href="../SwerveModulePhysicalCharacteristics.html" title="class in swervelib.parser"><code>SwerveModulePhysicalCharacteristics</code></a> based on parsed data.</dd>
</dl>