Arduino Swerve Drive
👋 Hi, I’m @wayne-1211
👀 I’m interested in coding & CAD
🌱 I’m currently learning C++ & python & fusion360
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
I'm from FRC 8725, Taiwan
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
How to reach me?
建議使用淺色模式瀏覽
甚麼是SWERVE?
Swerve Drive
is a drivetrain that is specifically designed so that the robot can spin while traveling along any path across the terrain. With each wheel rotating while also pivoting on the vertical axes, the maneuverability is unstoppable.
擷取自heyiamindians
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
MK2 swerve from FRC2910
SWERVE概述
swerve底盤有三種移動方式
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
通常使用joystick來控制
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
需要三個參數
- 移動角度
- 動力
- 自轉動力
前兩項可以用以下程式得到
而自轉動力可以直接藉由搖桿的另一軸得到
優點
- 靈活性極高
- 抓地力大於 mecanum wheel
- 速度大於一般輪組
缺點
BOM
Amount |
Part Type |
4 |
Basic Servo |
1 |
Power plug |
2 |
L9110 H-bridge module |
1 |
Arduino Uno (Rev3) |
2 |
Black Joystick KY-023 |
單輪組測試
機構
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
利用兩個伺服馬達驗證搖桿指向與輪組指向、驅動輪轉向的關係是否正確
程式
宣告腳位及變數
設定腳位狀態
將搖桿訊號轉為座標
利用三角函數算出theta角
設定各輪子方向
設定各輪子轉向
遇到問題及解決方法
-
- servo只能轉180度
- 利用程式讓他轉到極限後將角度歸零並改變驅動輪轉向
-
全機測試
機構


貼上各接腳腳位可以讓寫程式時減少錯誤

程式
宣告腳位及變數
設定腳位狀態並開啟Serial
將搖桿訊號轉為座標
自轉參數
利用三角函數算出theta角
消除雜訊並計算各輪組角度
動作
遇到問題及解決方法
-
-
改進
心得
參考資料
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
本著作係採用創用 CC 姓名標示-非商業性-相同方式分享 4.0 國際 授權條款授權.