Other Parts Discussed in Thread: CC2640R2F
Hi team,
Here's the request from the customer:
- When using BLE and Timer in SimpleBLEPeripheral in CC2540 SDK, will BLE affect the interrupt of Timer?
- CC2540 uses Timer3 or Timer4, timing 50-500 microsecond interrupt, the waveform test captured by the oscilloscope, the time is unstable, what is the problem? When he tests without BLE, the time of the timer is stable, but the time of the timer with BLE test is unstable. The test timing is 200 microseconds, and the test is 200-760 microseconds. Customer is using Down Mode, and the output of other modes is abnormal.
#pragma vector = T3_VECTOR __interrupt void t3_isr(void) { // Clears the module interrupt flag. T3OVFIF = 0; switch(outch) { case 0: DIO16(1); outch = 1; T3CTL |= 0x10; //开启 break; case 1: outch = 2; T3CTL |= 0x10; //开启 break; case 2: DIO16(0); DIO17(1); outch = 3; T3CTL |= 0x10; //开启 break; case 3: outch = 4; T3CTL |= 0x10; //开启 break; case 4: DIO17(0); T3CTL &= ~0x10; //关闭 break; } // Clears the CPU interrupt flag. T3IF = 0; } void timus_init(void) { CLKCONCMD = (CLKCONCMD & ~(0x07 << 3)); //Timer Hz = 32MHZ T3CTL = 0x08; T3IE = 1; T3CTL |= 0xA0; //32分频 T3CTL |= 0x01; T3CC0 = us / 2; EA = 1; } void timerus_setstatus(uint8 flag) { if(flag) { outch = 0; T3CTL |= 1 << 4; } else { T3CTL &= (1 << 4); } }
- Does the CC2540 SDK have similar functions to int_fast16_t Power_setDependency(uint_fast16_t resourceId); in the CC2640R2F SDK?
- CC2540 needs to keep the main frequency of the system unchanged, except for the following parameters: Cancel the project macro definition POWER_SAVING and HCI_EXT_ClkDivOnHaltCmd( HCI_EXT_ENABLE_CLK_DIVIDE_ON_HALT ); Change to DISABLE. Need to configure other parameters?
- What is the difference between HCI_EXT_HaltDuringRfCmd() and HCI_EXT_ClkDivOnHaltCmd() functions?
Could you help check this case? Thanks.
Best Regards,
Nick