2016年2月29日 星期一

無人機電子變速器研究筆記



1.  Turnigy Multistar 10 Amp   >    http://www.hobbyking.com/hobbyking/store/__65151__Turnigy_Multistar_10A_V2_ESC_With_BLHeli_and_2A_LBEC_2_3S_V.html

$6.99

Specs:
Constant Current: 10AInput Voltage: 2-3 cell Lipoly 
BEC: Yes (linear) [Remove middle wire to dissable]
BEC Output: 5V/2APWM: 8 KHz
Max RPM: 240,000rpm for 2 Pole Brushless Motor
PCB Size: 22mm x 17mm
Discharge Plugs: Male 2mm Bullet Connector
Motor Plugs: Female 2mm Bullet Connector
Weight: 11.4g



2. 30A Simonk電變  250元
產品規格:
最大連續電流:11.1V/30A(需通風良好環境下)
電壓:2-3S(總W數為300W以下)
線性BEC:5V/3A
尺寸:35x23x8mm
兼容的信號頻率為30Hz - 550Hz
電源連接器:XT60型
電機插頭:3.5mm金插
重量:30g


sudo ./servod
Board revision:                  2
Using hardware:                PWM
Using DMA channel:              14
Idle timeout:             Disabled
Number of servos:                4
Servo cycle time:            20000us
Pulse increment step size:      10us
Minimum width value:            50 (500us)
Maximum width value:           250 (2500us)
Output levels:              Normal

Using P1 pins:               7,16,18,22
Using P5 pins:

Servo mapping:
     0 on P1-7           GPIO-4
     1 on P1-16          GPIO-23
     2 on P1-18          GPIO-24
     3 on P1-22          GPIO-25

Options:
--pcm tells servod to use PCM rather than PWM hardware
to implement delays
--idle-timeout=Nms tells servod to stop sending servo pulses for a
given output N milliseconds after the last update
--cycle-time=Nus Control pulse cycle time in microseconds, default
20000us
--step-size=Nus Pulse width increment step size in microseconds,
default 10us
--min={N|Nus|N%} specifies the minimum allowed pulse width, default
50 steps or 500us
--max={N|Nus|N%} specifies the maximum allowed pulse width, default
250 steps or 2500us
--invert Inverts outputs
--dma-chan=N tells servod which dma channel to use, default 14
--p1pins=<list> tells servod which pins on the P1 header to use
--p5pins=<list> tells servod which pins on the P5 header to use

min and max values can be specified in units of steps, in microseconds,
or as a percentage of the cycle time. So, for example, if cycle time is
20000us and step size is 10us then the following are equivalent:

--min=50 --min=500us --min=2.5%



echo 0=150 > /dev/servoblaster # Specify as a number of steps
echo 0=50% > /dev/servoblaster # Specify as a percentage
echo 0=1500us > /dev/servoblaster # Specify as microseconds
echo P1-7=150 > /dev/servoblaster # Using P1 pin number rather
echo P1-7=50% > /dev/servoblaster # ... than servo number
echo P1-7=1500us > /dev/servoblaster
定義在  servo.c

#define DEFAULT_CYCLE_TIME_US   20000
#define DEFAULT_STEP_TIME_US    10
#define DEFAULT_SERVO_MIN_US    500
#define DEFAULT_SERVO_MAX_US    2500

Servo cycle time:            20000us
Pulse increment step size:      10us
Minimum width value:            50 (500us)
Maximum width value:           250 (2500us)


電子變速器的週期為490 週期....

遙控器的油門 :  min :1100 ~ max : 1900  us.....


頭朝前面.....   左手邊為 1,  右手邊為2 ....  右後為 3.... 左後為 4....




依序接上 CC3D 的輸出....從右邊裝到左邊......從這個圖來看...CC3D 可以輸出到六軸....



遙控器的最大油門  1900 us.....最小油門  1100us....


然後我用 RPI  的PWM 來設定...發覺把 週期設成490.....  duty cycle 設成大於 50% ...

螺旋槳就開始啟動了....


順時針轉  接 正槳

逆時針轉  接 負槳





沒有留言:

張貼留言