336x280(권장), 300x250(권장), 250x250, 200x200 크기의 광고 코드만 넣을 수 있습니다.


00899a.pdf

▲쿼드콥터용 Brushless Motor 드라이버 AN899 와 PIC18FXX31 MCU를 이용한 자료입니다.


참고로 Assembly 코드로 씌여있고, 혹시 C언어로 변경을 원하시는 분은

http://instructables.tistory.com/64

▲여기 링크를 눌러주세요



As seen in AN885, 

BLDC motors are electronically commutated based on the rotor position. 

Each commutation sequence has two of three phases connected

across the power supply and the third phase is left open.

AN885에서 보다시피,

BLDC모터는 전자적으로 commutated(=정류)된다. based on the rotor 포지션기반으로.

각 commutation 시퀀스는 갖고있다. 2개의 3상을 연결된 

across the 파워서플라이를 가로지르는 and the 세번째 phase는 남아있다. 열린상태로.


Using PWMs, the average voltage supplied

across the windings can be controlled, thus controlling

the speed. In this section, we will see how the peripherals

on the PIC18FXX31 can be used to control a

BLDC motor.

Figure 1 shows a typical control block diagram for

controlling a BLDC motor.

The PWM outputs from the PIC18FXX31 control the

power switches, Q0 to Q5. A matching driver circuit

should be used for supplying the required gate current

drive for the power switches. As we have seen in

AN885, the Hall Sensor signals may have 60-degree,

or 120-degree, electrical phase difference to each

other. A sequence table is entered in the program

memory based on the type of Hall Sensor placement.

The sequence can be taken from the motor data sheet.

The sequence may be different for clockwise and

counterclockwise rotations.

The following section explains how PCPWM, IC and

ADCs are used for open-loop control.


▼시퀀스에 대한 부연설명을 드리자면 아래와 같습니다.


코드를 보면 눈치 빠른 사람이라면 이해하겠지만

그렇지 못한 사람들을 위해서 아래에 그림으로 정리해봤습니다.

그리느라 힘들었으니 잘 간직해주세요 ^^

(Red means DC+, Blue means DC-)











;Commutation definition. This should be loaded to OVDCOND to realize the sequence

;The Hall Sensor makes a transition every 60 degrees

#define POSITION1 b'00010010' ;PWM1 & PWM4 are active

#define POSITION2 b'00000110' ;PWM1 & PWM2 are active

#define POSITION3 b'00100100' ;PWM5 & PWM2 are active

#define POSITION4 b'00100001' ;PWM5 & PWM0 are active

#define POSITION5 b'00001001' ;PWM3 & PWM0 are active

#define POSITION6 b'00011000' ;PWM3 & PWM4 are active

#define DUMMY_POSITION b'00000000' ;All PWM outputs are inactive

;---------------------------------------------------------------------------------

;Table initialization, Table values are loaded to RAM

;Forward sequence

MOVLW POSITION2 ;When Hall Sensor = 000,

MOVWF POSITION_TABLE_FWD ;PWM1 & PWM2 should be active

MOVLW POSITION3 ;When Hall Sensor = 001,

MOVWF POSITION_TABLE_FWD+1 ;PWM1 & PWM4 should be active

MOVLW DUMMY_POSITION ;When Hall Sensor = 002,

MOVWF POSITION_TABLE_FWD+2 ;All PWM outputs should be inactive

MOVLW POSITION4 ;When Hall Sensor = 003,

MOVWF POSITION_TABLE_FWD+3 ;PWM3 & PWM4 should be active

MOVLW POSITION1 ;When Hall Sensor = 004,

MOVWF POSITION_TABLE_FWD+4 ;PWM5 & PWM2 should be active

MOVLW DUMMY_POSITION ;When Hall Sensor = 005,

MOVWF POSITION_TABLE_FWD+5 ;All PWM outputs should be inactive

MOVLW POSITION6 ;When Hall Sensor = 006,

MOVWF POSITION_TABLE_FWD+6 ;PWM5 & PWM0 should be active

MOVLW POSITION5 ;When Hall Sensor = 007,

MOVWF POSITION_TABLE_FWD+7 ;PWM3 & PWM0 should be active

;Reverse sequence

MOVLW POSITION5 ;When Hall Sensor = 000,

MOVWF POSITION_TABLE_REV ;PWM3 & PWM0 should be active

MOVLW POSITION6 ;When Hall Sensor = 001,

MOVWF POSITION_TABLE_REV+1 ;PWM5 & PWM0 should be active

MOVLW DUMMY_POSITION ;When Hall Sensor = 002,

MOVWF POSITION_TABLE_REV+2 ;All PWM outputs should be inactive

MOVLW POSITION1 ;When Hall Sensor = 003,

MOVWF POSITION_TABLE_REV+3 ;PWM5 & PWM2 should be active

MOVLW POSITION4 ;When Hall Sensor = 004,

MOVWF POSITION_TABLE_REV+4 ;PWM3 & PWM4 should be active

MOVLW DUMMY_POSITION ;When Hall Sensor = 005,

MOVWF POSITION_TABLE_REV+5 ;All PWM outputs should be inactive

MOVLW POSITION3 ;When Hall Sensor = 006,

MOVWF POSITION_TABLE_REV+6 ;PWM1 & PWM4 should be active

MOVLW POSITION2 ;When Hall Sensor = 007,

MOVWF POSITION_TABLE_REV+7 ;PWM1 & PWM2 should be active

'졸업작품 > Brushless Motor Control (PIC)' 카테고리의 다른 글

Brushless Motor Driver (L6235N)  (0) 2016.06.01
Posted by ElectricShock
:
BLOG main image
잡동사니들(지극히 개인취향인...) (다른글에도 댓글 부탁해요♥) You May Leave English Messages on GuestBook. by ElectricShock

공지사항

카테고리

분류 전체보기 (782)
Programming(=프로그래밍) (3)
MiDi (2)
Animation (4)
Blender (3D Graphic Program.. (10)
Blendtuts.com (Series) (1)
Blender 기초 팁들 (2)
Processing (디지털미디어과) (2)
Music (1)
Books in the world (0)
Communication(CAN, UART, et.. (12)
MCU Examples (PIC 기반) (7)
Transistor (1)
Mikro C Pro (11)
Mikro Pascal (1)
Proton IDE (0)
Robot (0)
Swift 3D (1)
Dummies Series (1)
All about Hacking (0)
제2 외국어 (1)
PIC 해외서적들 (3)
AVR (25)
PIC (MikroC) (MPLAB) (4)
Assembly (2)
ARM (3)
Arduino (26)
PSpice (1)
Proteus ISIS (14)
CodeVision (2)
FPGA (15)
MPLAB (24)
PCB (the Procedure) (15)
3D Printer (5)
PICKIT3 (6)
Matlab (11)
RaspBerry PI (15)
BeagleBone (1)
Android Studio (17)
졸업작품 (172)
Korea History (0)
Issue(사회) (73)
Multimeter 리뷰 (1)
Oscilloscope (1)
A (34)
B (19)
J (6)
C (32)
P (12)
T (37)
H (12)
I (12)
M (44)
R (5)
E (5)
F (2)
D (9)
O (2)
L (7)
S (9)
W (2)
V (6)
G (14)
Visual C++ or Visual Studio (2)
Android App Development (0)

최근에 올라온 글

최근에 달린 댓글

최근에 받은 트랙백