This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CC2530: IR Generation with Zstack

Part Number: CC2530
Other Parts Discussed in Thread: CC2591

Hi,

We want to implement a new functionality ( IR Generation) along with the router code. We have HAL_PA_LNA enabled that uses P1.1 as PA_EN for Enabling the CC2591 during transmission.
Also IR-Generation requires P1.1 as specified in the TI User guide.
We cannot change the PA_EN pin.

1) Even after disabling HAL_PA_LNA. we are not getting the IR-Gen signal
But standalone code for IR Gen is working fine.(verified on oscilloscope for both stand alone and with stack)

2) Can we use any other pin for IR Generartion?
IR Gen uses Timer 1 Ch-1 and Timer 3 Ch-1 for producing the modulated signal which is sent to P1.1 (Timer 1 Ch 1 alternative 2 pin). can we use Timer 1 Ch 1 alternative 1 pin for output?

  • Hi Aviral,

    1) You will have to make sure that there is no other timer or GPIO initialization which is interfering with your IR functionality, for example the sampleapp User Interface.

    2) IR generation can be produced with this configuration given that P0.3 is not used for any other purpose, you can confirm this with the standalone IR code.

    Regards,
    Ryan
  • I have made following changes in the HalIrGenInitNec function in the standalone code:

      // Select port direction to output
      //P1DIR |= HAL_IRGEN_P1SEL_PORT;
      P0DIR |= (1<<3);
    
      // Initially clear the port so that there will be no conflict
      //P1 &= ~HAL_IRGEN_P1SEL_PORT;
      P0 &= ~(1<<3);
      
      // Select port function to peripheral
      //P1SEL |= HAL_IRGEN_P1SEL_PORT;
      P0SEL |= (1<<3);
      
      // Select alternative 2 location for T1 CH1 output (P1.1)
      //PERCFG |= HAL_IRGEN_PERCFG_T1CFG;
      PERCFG &= ~HAL_IRGEN_PERCFG_T1CFG;

    We are not getting any  the output on P0.3. Is this all the change that needs to be done?

    we have not configured P0.3 for any other use.

  • Yes, that appears to be correct. Are you using NEC, RC5, or SIRC format? Please make sure you are using the correct project settings and build accordingly. Are you still seeing an output on P1.1 even with these changes? Verify that you are following all instructions from SWRA323: www.ti.com/.../swra323.pdf

    Regards,
    Ryan