Other Parts Discussed in Thread: AM1808
I am using ECAP2 as a simple Pulse Width Modulated generator (to control a fan) with the AM1808 using StarterWare 1_00_03_03. I set it up using the following code:
HWREG(SOC_ECAP_2_REGS+ECAP_CAP1) = 0x1000;
HWREG(SOC_ECAP_2_REGS+ECAP_CTRPHS) = 0x0;
HWREG(SOC_ECAP_2_REGS+ECAP_ECCTL2) = 0x06D0;
HWREG(SOC_ECAP_2_REGS+ECAP_CAP2) = 0x0300;
When I step through the code and execute the ECCTL2 line of code, it jumps to 0xFFFF0010 and then calls the AbortHandler(). When I hover over the command above it says "(*((volatile unsigned int *)((0x01F08000)+(0x2A))))", which is the correct address.
Can anyone tell me why this fails? If I comment that line out, all the other code listed above executes fine.
Thanks,
Tim