computePPU_Belt()

描述

在使用 config_PPU 設定 PPU(Pulse per Unit) 時,可使用協助計算函數來求得設定參數。
PPU(Pulse per Unit) 關係如下圖:
zero_size
86Duino 發送 pulse 到步進馬達驅動板,驅動板便會發送 step 使步進馬達旋轉。
micro_stepping:
- 步進馬達驅動板上的參數,若要打出一個 step,需從 86Duino 接收到的 pulse 數。
steps_per_revolution:
- 步進馬達上的參數,若要轉動一圈需從步進馬達驅動板接收到的step數。
pulses_per_revolution 之計算公式為 steps_per_revolution * micro_stepping。

參數需要測量皮帶牙距與齒輪的齒數,如下圖:
zero_size

語法


machine.computePPU_Belt(pulses_per_revolution, belt_pitch, pulley_tooth_count);

參數

machine:為 Machine物件。

pulses_per_revolution:讓步進馬達轉一圈,86Duino需要打的pulse數。

blet_pitch:皮帶牙距,單位為毫米。

pulley_tooth_count:與步進馬達同步旋轉之齒輪的齒數。

回傳

double: 回傳計算完成後的 PPU(Pulse per Unit)。

See also


函式庫參考主頁面

The text of the 86Duino reference is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.