mirror of
https://github.com/BroncBotz3481/YAGSL
synced 2026-06-25 06:51:40 +00:00
Added simple conversion factor calculation
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<!-- Generated by javadoc (17) on Thu Jan 18 15:35:15 CST 2024 -->
|
||||
<!-- Generated by javadoc (17) on Thu Jan 18 17:54:02 CST 2024 -->
|
||||
<title>SwerveMath</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
@@ -129,32 +129,43 @@ loadScripts(document, 'script');</script>
|
||||
<div class="block">Calculates the maximum acceleration allowed in a direction without tipping the robot.</div>
|
||||
</div>
|
||||
<div class="col-first odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static double</code></div>
|
||||
<div class="col-second odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#calculateDegreesPerSteeringRotation(double,double)" class="member-name-link">calculateDegreesPerSteeringRotation</a><wbr>(double angleGearRatio,
|
||||
double pulsePerRotation)</code></div>
|
||||
<div class="col-second odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#calculateDegreesPerSteeringRotation(double)" class="member-name-link">calculateDegreesPerSteeringRotation</a><wbr>(double angleGearRatio)</code></div>
|
||||
<div class="col-last odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
|
||||
<div class="block">Calculate the degrees per steering rotation for the integrated encoder.</div>
|
||||
</div>
|
||||
<div class="col-first even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static double</code></div>
|
||||
<div class="col-second even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#calculateMaxAcceleration(double)" class="member-name-link">calculateMaxAcceleration</a><wbr>(double cof)</code></div>
|
||||
<div class="col-second even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#calculateDegreesPerSteeringRotation(double,double)" class="member-name-link">calculateDegreesPerSteeringRotation</a><wbr>(double angleGearRatio,
|
||||
double pulsePerRotation)</code></div>
|
||||
<div class="col-last even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
|
||||
<div class="block">Calculate the practical maximum acceleration of the robot using the wheel coefficient of friction.</div>
|
||||
<div class="block">Calculate the degrees per steering rotation for the integrated encoder.</div>
|
||||
</div>
|
||||
<div class="col-first odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static double</code></div>
|
||||
<div class="col-second odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#calculateMaxAcceleration(double,double,double,double,double)" class="member-name-link">calculateMaxAcceleration</a><wbr>(double stallTorqueNm,
|
||||
<div class="col-second odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#calculateMaxAcceleration(double)" class="member-name-link">calculateMaxAcceleration</a><wbr>(double cof)</code></div>
|
||||
<div class="col-last odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
|
||||
<div class="block">Calculate the practical maximum acceleration of the robot using the wheel coefficient of friction.</div>
|
||||
</div>
|
||||
<div class="col-first even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static double</code></div>
|
||||
<div class="col-second even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#calculateMaxAcceleration(double,double,double,double,double)" class="member-name-link">calculateMaxAcceleration</a><wbr>(double stallTorqueNm,
|
||||
double gearRatio,
|
||||
double moduleCount,
|
||||
double wheelDiameter,
|
||||
double robotMass)</code></div>
|
||||
<div class="col-last odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
|
||||
<div class="col-last even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
|
||||
<div class="block">Calculate the maximum theoretical acceleration without friction.</div>
|
||||
</div>
|
||||
<div class="col-first even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static double</code></div>
|
||||
<div class="col-second even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#calculateMaxAngularVelocity(double,double,double)" class="member-name-link">calculateMaxAngularVelocity</a><wbr>(double maxSpeed,
|
||||
<div class="col-first odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static double</code></div>
|
||||
<div class="col-second odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#calculateMaxAngularVelocity(double,double,double)" class="member-name-link">calculateMaxAngularVelocity</a><wbr>(double maxSpeed,
|
||||
double furthestModuleX,
|
||||
double furthestModuleY)</code></div>
|
||||
<div class="col-last even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
|
||||
<div class="col-last odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
|
||||
<div class="block">Calculate the maximum angular velocity.</div>
|
||||
</div>
|
||||
<div class="col-first even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static double</code></div>
|
||||
<div class="col-second even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#calculateMetersPerRotation(double,double)" class="member-name-link">calculateMetersPerRotation</a><wbr>(double wheelDiameter,
|
||||
double driveGearRatio)</code></div>
|
||||
<div class="col-last even-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
|
||||
<div class="block">Calculate the meters per rotation for the integrated encoder.</div>
|
||||
</div>
|
||||
<div class="col-first odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static double</code></div>
|
||||
<div class="col-second odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#calculateMetersPerRotation(double,double,double)" class="member-name-link">calculateMetersPerRotation</a><wbr>(double wheelDiameter,
|
||||
double driveGearRatio,
|
||||
@@ -253,6 +264,22 @@ loadScripts(document, 'script');</script>
|
||||
</section>
|
||||
</li>
|
||||
<li>
|
||||
<section class="detail" id="calculateMetersPerRotation(double,double)">
|
||||
<h3>calculateMetersPerRotation</h3>
|
||||
<div class="member-signature"><span class="modifiers">public static</span> <span class="return-type">double</span> <span class="element-name">calculateMetersPerRotation</span><wbr><span class="parameters">(double wheelDiameter,
|
||||
double driveGearRatio)</span></div>
|
||||
<div class="block">Calculate the meters per rotation for the integrated encoder. Calculation: (PI * WHEEL DIAMETER IN METERS) / (GEAR
|
||||
RATIO)</div>
|
||||
<dl class="notes">
|
||||
<dt>Parameters:</dt>
|
||||
<dd><code>wheelDiameter</code> - Wheel diameter in meters.</dd>
|
||||
<dd><code>driveGearRatio</code> - The gear ratio of the drive motor.</dd>
|
||||
<dt>Returns:</dt>
|
||||
<dd>Meters per rotation for the drive motor.</dd>
|
||||
</dl>
|
||||
</section>
|
||||
</li>
|
||||
<li>
|
||||
<section class="detail" id="normalizeAngle(double)">
|
||||
<h3>normalizeAngle</h3>
|
||||
<div class="member-signature"><span class="modifiers">public static</span> <span class="return-type">double</span> <span class="element-name">normalizeAngle</span><wbr><span class="parameters">(double angle)</span></div>
|
||||
@@ -317,6 +344,20 @@ loadScripts(document, 'script');</script>
|
||||
</section>
|
||||
</li>
|
||||
<li>
|
||||
<section class="detail" id="calculateDegreesPerSteeringRotation(double)">
|
||||
<h3>calculateDegreesPerSteeringRotation</h3>
|
||||
<div class="member-signature"><span class="modifiers">public static</span> <span class="return-type">double</span> <span class="element-name">calculateDegreesPerSteeringRotation</span><wbr><span class="parameters">(double angleGearRatio)</span></div>
|
||||
<div class="block">Calculate the degrees per steering rotation for the integrated encoder. Encoder conversion values. Drive converts
|
||||
motor rotations to linear wheel distance and steering converts motor rotations to module azimuth.</div>
|
||||
<dl class="notes">
|
||||
<dt>Parameters:</dt>
|
||||
<dd><code>angleGearRatio</code> - The gear ratio of the steering motor.</dd>
|
||||
<dt>Returns:</dt>
|
||||
<dd>Degrees per steering rotation for the angle motor.</dd>
|
||||
</dl>
|
||||
</section>
|
||||
</li>
|
||||
<li>
|
||||
<section class="detail" id="calculateMaxAngularVelocity(double,double,double)">
|
||||
<h3>calculateMaxAngularVelocity</h3>
|
||||
<div class="member-signature"><span class="modifiers">public static</span> <span class="return-type">double</span> <span class="element-name">calculateMaxAngularVelocity</span><wbr><span class="parameters">(double maxSpeed,
|
||||
|
||||
Reference in New Issue
Block a user