SLYU064A June   2023  – December 2023 TMAG3001 , TMAG5170 , TMAG5170-Q1 , TMAG5170D-Q1 , TMAG5173-Q1 , TMAG5253 , TMAG5273

 

  1.   1
  2.   Abstract
  3.   Trademarks
  4. 1Introduction
  5. 2Joystick Design
    1. 2.1 Establishing Form Factor
      1. 2.1.1 Choosing Mechanical Implementation
      2. 2.1.2 Choosing Magnetic Implementation
    2. 2.2 Magnet Sensor Placement
    3. 2.3 Design Calculations
    4. 2.4 Post Processing
    5. 2.5 Prototyping and Bench Testing
    6. 2.6 Error Sources
      1. 2.6.1 Mechanical Hysteresis
      2. 2.6.2 Nearby Material Influence
      3. 2.6.3 Fulcrum Slippage
      4. 2.6.4 Offset
  6. 3Lever Design
    1. 3.1 Establishing a Form Factor
      1. 3.1.1 Choosing Mechanical Implementation
    2. 3.2 Magnet Sensor Placement
    3. 3.3 Design Calculations
    4. 3.4 Prototyping and Bench Testing
    5. 3.5 Error Sources
  7. 4Summary
  8. 5References
  9. 6Revision History

Prototyping and Bench Testing

With a high degree of confidence in the output format the lever design was assembled and installed into the existing automotive steering column control module.

GUID-20230525-SS0I-WWV7-VSJM-FDBPJ07PJ6SG-low.svg Figure 3-11 Automobile Turn Indicator Demo

Sensor data for all three axes was then streamed continually while the indicator stalk was moved through all operating positions. When plotting the collected X, Y, and Z component data in XYZ B-field Data, three very distinct travel arcs are revealed.

GUID-20230512-SS0I-DSWK-582M-MN0RS3GKFX8S-low.svg Figure 3-12 XYZ B-field Data

The raw X,Y, and Z component data can be used sufficiently well to create a look-up table which can be used to define each of the six operation positions. However, performing vector angle calculations from these results provides an even clearer decision tree. These vector angle calculations provide a more spherical reference which is useful in joystick and lever applications where multiple axes of data are available. These vector angle calculations are referred to as Alpha(α) and Beta(β), and when joined with a total vector magnitude are descriptive of the total field vector.

Equation 5. α = atan B z 2 + B x 2 B y
Equation 6. β = atan B z 2 + B y 2 B x
Equation 7. m a g n i t u d e =   B x 2 + B y 2 + B z 2

To better understand Equation 5 through Equation 7, consider the vector diagrams in Alpha and Beta Angle Vector Diagrams which use an identical source vector to demonstrate the each angle.

GUID-20230512-SS0I-LZ8V-RT6P-2CBXMGHM8HCJ-low.svg Figure 3-13 Alpha and Beta Angle Vector Diagrams

Applying Equation 5 through Equation 7 to the captured data in XYZ B-field Data, linear changes in angle are easily identified.

GUID-20230512-SS0I-0T82-F6XV-K477W95B6KHK-low.svg Figure 3-14 Calculated Alpha-Beta Data

After plotting the Alpha and Beta angles against the vector magnitude, it is clear that the Alpha angle result from Equation 5 defines three separate regions for each of the turn indicator positions. The vector magnitude from Equation 7 can be used to easily define the lever pull. Additionally, there is now a linear response to the lever pull action which can be used to indicate how far the lever has been pulled. If desired, Alpha and Beta together can also be used to define many more tilt angles for the indicator stalk.

Example code in TMAG5170-CODE-EXAMPLE and TMAG5x73-CODE-EXMAPLE both provide reference for how to implement these calculations.