Skip to content

Commit

Permalink
fix: list nesting
Browse files Browse the repository at this point in the history
Closes #309
  • Loading branch information
sethfischer committed Jun 21, 2021
1 parent 281ba5e commit ee710dd
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 22 deletions.
42 changes: 21 additions & 21 deletions electrical/calibration.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ We will now go through and check the encoders and motors one at a time and perfo

![](../images/calibration/ion_sutudio_1.png)
**Figure 1: Ion Studio Firmware Update**

1.1.4 Click the ’Connect Selected Unit’ box in the upper left

1.1.5 Verify that all the motor control parameters are roughly nominal:
Expand All @@ -47,18 +47,18 @@ As you perform the calibration and testing outlined in this document, make sure
**Figure 3**

(a) Setup:

* Control Mode: Packet Serial
* Multi-Unit: Check Enable Multi-Unit Mode
* Multi-Unit: Check Enable Multi-Unit Mode

(b) Serial:

* Set the address to 128,129,130,131,132 for each respective RoboClaw
* (Robo- Claw 1 is address 128, 2 is address 129, etc)
* Baudrate: 115200

(c) Battery:

* Max Main Battery: 17.5V
* Min Main Battery: 11.5V
* Max Logic Battery: 5.5V
Expand Down Expand Up @@ -87,7 +87,7 @@ As you perform the calibration and testing outlined in this document, make sure

![](../images/calibration/is5.png)
**Figure 4**

(a) Under the control pane, slowly move the slider bar up for Motor1.

![](../images/calibration/is5.png)
Expand All @@ -96,9 +96,9 @@ As you perform the calibration and testing outlined in this document, make sure
(b) Verify that when the forward signal is sent to the motor (the Motor1 slider is above 0), the wheel spins in the direction that would move the rover as a whole forward (note this is different clockwise vs counterclockwise based on which wheel you are testing). **If the wheel moves backwards with respect to the rover direction, then under the General Settings tab click the checkbox labeled ’Reverse M Relative Direction based on which motor is wrong.**

(c) Now as you drive M1 motor forward (which now corresponds to the rover moving forward), verify that M1 Encoder value increases1. **If the encoder value decreases go to the General tab and under I/O click the Invert checkbox for the Encoder Mode.**

(d) Repeat steps 1.2.1 b) and 1.2.1 c) for M2 motor.

1.2.2 Once both motors are spinning the correct direction and the encoders respond accordingly when commanded through the PWM Signal tab, move on to the Velocity Settings tab.

![](../images/calibration/is6.png)
Expand All @@ -122,7 +122,7 @@ There has been significant feedback that the BasicMicro Motion Studio auto tune
**Figure 8**

(c) Once both motors on this motor controller have been tuned go back to the General settings tab and update the Motor Parameters to have a Max current of 3.0 Amps. Then go to Device − > Save Settings and then exit. Repeat all of steps 6 through 8 for the other drive motors.

## 1.3 Corner Motor Calibration
1.3.1 Perform the following for the **RoboClaw addresses 131 and 132**:

Expand All @@ -137,8 +137,9 @@ There has been significant feedback that the BasicMicro Motion Studio auto tune
* Navigate to the PWM Settings tab to move the corner to its ”center” position, which is where the wheel is directly forward.

* Unscrew the small gear at the bottom of the absolute encoder
* Once the absolute encoder shaft is uncoupled from the robot, spin the encoder until you determine the max value. This should be somewhere in the range of 1400-18004.

* Once the absolute encoder shaft is uncoupled from the robot, spin the encoder until you determine the max value. This should be somewhere in the range of 1400-18004.

* As opposed to the drive motors, the corners use absolute encoders that are defined in one direction only, so you cannot switch the direction of the encoder.

Clipping occurs when you go past the 360 deg mark on the encoder and it starts again at 0.
Expand All @@ -148,7 +149,7 @@ If you are getting encoder values of close to 2000 and the value stays above 200
* Spin the encoder until it reads a value of roughly half its max value and reattach the gear, coupling it back to the rover.

(e) For each motor M1 and M2, we now need to obtain what is the new min and max encoder values. Using the PWM Settings tab, move the motors until they run into the physical hard stops. Record the min and max encoder values for each, but for the min values add at least 15 and the max subtract at least 155.

(f) Navigate to the Position Settings tab.

![](../images/calibration/is10.png)
Expand All @@ -158,7 +159,7 @@ If you are getting encoder values of close to 2000 and the value stays above 200

![](../images/calibration/is11.png)
**Figure 10**

(h) Change the Autotune type to **PD** and then tune the M1 and M2 motors by clicking the ’Tune M1’ and ’Tune M2’ buttons. We’ve found that this autotuning process is more successful if you run it with the wheels down on a smooth surface, but still supporting the weight of the robot.

![](../images/calibration/is12.png)
Expand All @@ -184,15 +185,14 @@ These steps assume you have already set the max/min values of the encoders in th
5. Increase the P value and then use the position slider to command the setpoint of the motor. Initially I started my P value at 10 for the first increment. The motor should move to this position. If it stops immediately at the value then the system is over-damped. Keep increasing the P value until the motor beings to have a stead-state oscillation which doe NOT damp out to the setpoint. This value is called Kc. I found mine to be usually between 10-20 for values of P, which I incremented in steps of 0.5 at a time.
6. Now that the system is oscillating back and forth you have to get the period of the oscillation. Do this by starting a timer and timing how long it takes to do 30 oscillations. For mine it was around 10 seconds. Divide that time by the number of oscillations, this gives you the period, which is called Pcr. I found this to be generally around 0.3s
7. The approximate gains can be found using the following equations:
<!-- Maybe convert the equations to graphics -->
<!-- Maybe convert the equations to graphics -->

P = 0.6Kc
<!-- (1)-->
P = 0.6Kc
<!-- (1)-->

I = 0.5Pcr
<!-- (2) -->

D = 0.125Pcr
<!-- (3)-->
I = 0.5Pcr
<!-- (2) -->

D = 0.125Pcr
<!-- (3)-->
8. Enter in these values into the GUI and use the slid bar to set the setpoint and see the motor response on the graph. More than likely what will happen is it will overshoot and do one oscillation. This means that the P value is slightly too high. Decrease the P value in small steps until you see no overshoot of the setpoint in the graph. Once that happens your corner motors will be appropriately tuned.
2 changes: 1 addition & 1 deletion parts_list/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ start of a section.
This CSV file is a standard text file; do not use Excel or Numbers to edit it as
doing so will change the encoding. The format is:

> Part Name,Project Ref Code,Model/Config,Site,Link,Sold in Packs of,Total Used in Project,Quantity to Buy,Price Each,Price Total,Used in Sections
> Part Name,Project Ref Code,Model/Config,Site,Link,Sold in Packs of,Total Used in Project,Quantity to Buy,Price Each,Price Total,Used in Sections

0 comments on commit ee710dd

Please sign in to comment.