• slider image 442
  • slider image 483
  • slider image 484
  • slider image 485
  • slider image 486
  • slider image 487
  • slider image 488
  • slider image 491
:::

論壇索引


Board index » All Posts (hello074)




Re: 計數時間
#21
初級會員
初級會員


感謝R大的回覆
可是我目前用的dsPIC30F4011這顆晶片
計數器的Timer3
就會用到PR3

發表於: 2008/6/19 2:27
頂部


計數時間
#22
初級會員
初級會員


請問
PR3=0xFFFF;
代表計數時間為多少秒阿?
(外部頻率為FCY 7372800*2)

發表於: 2008/6/16 14:01
頂部


ICD2的問題
#23
初級會員
初級會員


如題
我的ICD2每次開啟電源後
都會出現BUSY
後來程式BUILDING
就會如下
MPLAB ICD 2 Ready
ICD0060: Failed to bulk read target memory (Data) (Address:0x81E) (Size:0x2)
ICD0151: Failed to sync memory (MT = Data) (Dir = 0x0)
ICD0082: Failed MPLAB ICD 2 operation
ICD0082: Failed MPLAB ICD 2 operation
Resetting Target
ICD0082: Failed MPLAB ICD 2 operation
...Failed to reset target

請問這是什麼問題?
該如何解決?

發表於: 2008/5/11 21:47
頂部


PIC16F877 V.S PIC30F4011
#24
初級會員
初級會員


PIC16F877 V.S PIC30F4011
16F877的程式語言寫法
和30F4011的寫法相同嗎?
還有哪些差異呢

發表於: 2008/5/6 20:43
頂部


[請教]用dsPIC30F4011如何產生截波?
#25
初級會員
初級會員


#define __dsPIC30F4011__

#include <p30f4011.h>

#define FCY 7372800*2 //one instruction frequency
//constract initial
_FOSC(CSW_FSCM_OFF & XT_PLL8);
_FWDT(WDT_OFF);
_FBORPOR(0x008300); //enable MCLR, PWMPIN=1(controlled by port at device reset),HPOL=1 and LPOL=1 active high output polarity
_FGS(CODE_PROT_OFF);

int main(void)
{
ADPCFG=0xFFFF;

initial_PWM();

while(1);
}

void initial_PWM(void)
{
PTCONbits.PTEN=0; //base timer close
IFS2bits.PWMIF=0; //PWM interrupt flag clear
IFS2bits.FLTAIF=0; //PWM fault interrupt clear
IEC2bits.FLTAIE=0; //disable PWM interrupt
IEC2bits.PWMIE=0; //disable PWM fault

PTCONbits.PTSIDL=1; //PWM halt when idle mode
PTCONbits.PTOPS=0x0; //interrupt 1:1 postscale
PTCONbits.PTCKPS=0x0; //1:1 prescale
PTCONbits.PTMOD=0x0; //operating in a free running mode

PTPERbits.PTPER=0x024D; //PWM time base period register
PDC1=0x024D; //PWM1 50%
PDC2=0x024D; //PWM2 50%

PWMCON1bits.PMOD1=1; //independent PWM 1H 1L output mode
PWMCON1bits.PMOD2=1; //independent PWM 2H 2L output mode
PWMCON1bits.PEN1H=1; //PWM1H enabled for PWM output
PWMCON1bits.PEN1L=1; //PWM1L enabled for PWM output
PWMCON1bits.PEN2H=1; //PWM2H enabled for PWM output
PWMCON1bits.PEN2L=1; //PWM2L enabled for PWM output

PWMCON2bits.SEVOPS=0x0; //special event trigger 1:1 postscale
PWMCON2bits.OSYNC=1; //overrides synchronous PWM time base
PWMCON2bits.UDIS=0; //enable updata duty cycle
PTCONbits.PTEN=1; //base timer open
}


這是我目前的程式
我想控制無刷馬達
請問OVDCON要如何設定
(放在哪個程式段)
才能得到講義上的波形?
(應該是說如何產生截波)
講義我已經下載看過了
都說要在獨立輸出模式
可是試了很久都弄不出來
不知該如何設定
還是我的程式有錯?


發表於: 2008/4/29 18:13
頂部


Re: 燒錄時的問題??
#26
初級會員
初級會員


學了不少...3Q

發表於: 2008/4/17 11:57
頂部


Re: 燒錄時的問題??
#27
初級會員
初級會員


ICD2 Firmware 如何更新?
FAE是什麼阿?

發表於: 2008/4/16 19:06
頂部


燒錄時的問題??
#28
初級會員
初級會員


我build完後,按燒入鍵時,出現下列文字
請問我的燒錄器怎麼了?
還是哪邊設定有問題?


Connecting to MPLAB ICD 2
...Connected
Setting Vdd source to target
Target Device dsPIC30F4011 found, revision = Rev 0x1002
...Reading ICD Product ID
Running ICD Self Test
...Passed
MPLAB ICD 2 Ready
Resetting Target
MPLAB ICD 2 Ready
ICD0060: Failed to bulk read target memory (Data) (Address:0x81E) (Size:0x2)
ICD0151: Failed to sync memory (MT = Data) (Dir = 0x0)
ICD0082: Failed MPLAB ICD 2 operation
ICD0082: Failed MPLAB ICD 2 operation
Programming Target...
ICD0082: Failed MPLAB ICD 2 operation
ICD0275: Programming failed.
MPLAB ICD 2 Ready
Resetting Target
ICD0082: Failed MPLAB ICD 2 operation
...Failed to reset target
MPLAB ICD 2 Ready
ICD0082: Failed MPLAB ICD 2 operation
ICD0082: Failed MPLAB ICD 2 operation
ICD0082: Failed MPLAB ICD 2 operation
Programming Target...
ICD0082: Failed MPLAB ICD 2 operation
ICD0275: Programming failed.
MPLAB ICD 2 Ready

發表於: 2008/4/11 15:43
頂部


如何使用PWM輸出強制Override?
#29
初級會員
初級會員


小弟我目前正在寫用於無刷直流馬達的PWM
我試過OVDCON暫存器
也在設定了在獨立的PWM輸出
可是還是波形出不來
請教各位高手
教一下吧
如有範例程式最好
謝謝!

發表於: 2008/4/10 22:13
頂部



« 1 2 (3)



:::

Microchip連結

https://www.facebook.com/microchiptechnologytaiwan/
http://www.microchip.com.tw/modules/tad_uploader/index.php?of_cat_sn=13
https://mu.microchip.com/page/tmu
http://elearning.microchip.com.tw/modules/tad_link/index.php?cate_sn=1
https://page.microchip.com/APAC-PrefCenters-TW.html
http://www.microchip.com/
http://www.microchip.com/treelink
http://www.microchipdirect.com/
http://www.microchip.com.cn/newcommunity/index.php?m=Video&a=index&id=103
http://www.microchip.com.tw/modules/tad_uploader/index.php?of_cat_sn=2
http://www.microchip.com.tw/Data_CD/eLearning/index.html
http://www.microchip.com.tw/RTC/RTC_DVD/
https://www.microchip.com/development-tools/
https://www.youtube.com/user/MicrochipTechnology
[ more... ]

教育訓練中心

!開發工具購買
辦法說明 [業界客戶] [教育單位]
----------------------------------
!校園樣品申請
辦法說明 [教師資格] [學生資格]
----------------------------------