30.10.2014 Views

o_195h4n6al16jb186b1b2qs7fgssa.pdf

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

sptime = 0x0;<br />

config1 = PWM_EN & PWM_PTSIDL_DIS &<br />

PWM_OP_SCALE16 &<br />

PWM_IPCLK_SCALE16 &<br />

PWM_MOD_UPDN;<br />

config2 = PWM_MOD1_COMP & PWM_PDIS4H &<br />

PWM_PDIS3H & PWM_PDIS2H &<br />

PWM_PEN1H & PWM_PDIS4L &<br />

PWM_PDIS3L & PWM_PDIS2L &<br />

PWM_PEN1L;<br />

config3 = PWM_SEVOPS1 & PWM_OSYNC_PWM &<br />

PWM_UEN;<br />

OpenMCPWM(period, sptime, config1,<br />

config2, config3);<br />

OverrideMCPWM<br />

Description: This function configures the OVDCON register.<br />

Include: pwm.h<br />

Prototype: void OverrideMCPWM(unsigned int config);<br />

Arguments: config This contains the parametersto be configured in the<br />

OVDCON register as defined below:<br />

Output controlled by PWM generator<br />

PWM_GEN_4H<br />

PWM_GEN_3H<br />

PWM_GEN_2H<br />

PWM_GEN_1H<br />

PWM_GEN_4L<br />

PWM_GEN_3L<br />

PWM_GEN_2L<br />

PWM_GEN_1L<br />

Bit defines related to PWM4 is available only for certain<br />

devices and the suitable data sheet should be referred to.<br />

Output controlled by POUT bits<br />

PWM_POUT_4H<br />

PWM_POUT_4L<br />

PWM_POUT_3H<br />

PWM_POUT_3L<br />

PWM_POUT_2H<br />

PWM_POUT_2L<br />

PWM_POUT_1H<br />

Bit xác định liên quan đến PWM4 chỉ có sẵn cho một số<br />

thiết bị và các bảng dữ liệu phù hợp nên được chuyển đến.<br />

Dead Thời gian Chọn bit cho tín hiệu PWM3<br />

PWM_DTS3A_UA<br />

PWM_DTS3A_UB<br />

PWM_DTS3I_UA<br />

PWM_DTS3I_UB<br />

Dead Thời gian Chọn bit cho tín hiệu PWM2<br />

PWM_DTS2A_UA<br />

PWM_DTS2A_UB<br />

PWM_DTS2I_UA<br />

PWM_DTS2I_UB<br />

Dead Thời gian Chọn bit cho tín hiệu pwm1<br />

PWM_DTS1A_UA<br />

PWM_DTS1A_UB<br />

PWM_DTS1I_UA<br />

PWM_DTS1I_UB<br />

Trở lại giá trị Không<br />

Bình luận: Không có<br />

Source File: SetMCPWMDeadTimeAssignment.c<br />

Mã số Ví dụ: SetMCPWMDeadTimeAssignment (PWM_DTS3A_UA &<br />

PWM_DTS2I_UA & PWM_DTS1I_UA);<br />

dsPIC Thư viện ngoại vi<br />

2004 Microchip Technology Inc DS51456B trang 177<br />

SetMCPWMDeadTimeGeneration<br />

Mô tả: Chức năng này cấu hình các giá trị thời gian chết và prescalers đồng hồ.<br />

Bao gồm: pwm.h<br />

Prototype: void SetMCPWMDeadTimeGeneration (<br />

int config);<br />

Đối số: cấu hình này bao gồm các thông số phải được cấu hình trong DTCON1<br />

đăng ký theo quy định dưới đây:<br />

Dead Thời gian Đơn vị B prescale Chọn bit<br />

PWM_DTBPS8<br />

PWM_DTBPS4<br />

PWM_DTBPS2<br />

PWM_DTBPS1<br />

Dead Thời gian Đơn vị A prescale Chọn hằng số<br />

PWM_DTA0<br />

PWM_DTA1

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!