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.

RTOS/CC2650: Can CMD_IEEE_TX and CMD_IEEE_RX

Part Number: CC2650

Tool/software: TI-RTOS

In IEEE 802.15.4 mode, the radio CPU accepts two levels of radio operation commands. Operations can
run in the background level or in the foreground level. Each operation can run in only one of these levels.
Operations in the foreground level normally require a background-level operation running at the same
time.
The background-level operations are the receive and energy detect scan operations. Only one of these
operations can run at a time. The foreground-level operations are the CSMA-CA operation, the receive
ACK operation, the transmit operation, the abort background level operation, and the modify radio setup
operation. These can be entered as one command or a command chain, even if a background-level
operation is running. The CSMA-CA and receive ACK operations run simultaneously with the backgroundlevel
operation. The transmit operation causes suspension of the background level operation until the
transmission is done. Table 23-78 shows the allowed combinations of background and foreground-level
operations. Violation of these combinations causes an error when the foreground-level command is about
to start, signaled by the ERROR_WRONG_BG status in the status field of the foreground-level command
structure.

Is this means that the  CMD_IEEE_TX and CMD_IEEE_RX  command can operate at the same time?

The program wants to achieve the following functions, cc2650 has been receiving, and then every certain time to send a packet. At present, there is no problem with sending and receiving packets alone. But in the program, if the reception is turned on, then it cannot be sent out.

How to realize the switch between sending and receiving?

@

@

@

@

  • Thank you for you reply.

    But that post is a example about Tx mode in IEEE.

    Now I can send or receive packet alone.

    But when I open Rx (because it is blackgroud command), then I send a packet (foregroud command), the program is stop in RF_pendCmd

      tx_handle = RF_scheduleCmd(
                                              &RadioIF_RF_Obj,
                                              (RF_Op *)&Ieee154_0_cmdIeeeTx,
                                              &sched_params,
                                              NULL,
                                              (RF_EventLastCmdDone | RF_EventLastFGCmdDone));
        /* Wait until TX operation finishes */
      RF_EventMask tx_events = RF_pendCmd(&RadioIF_RF_Obj, tx_handle, 0);

    the rx command is

    // Issue Rf Core RX command to start RX
        RadioIF_Cmd_Handle = RF_postCmd(RadioIF_Rf_Handle, (RF_Op*)&Ieee154_0_cmdIeeeRx, RF_PriorityNormal, &RadioIF_rfCoreEventCallback, IRQ_RX_BUF_FULL | IRQ_RX_ENTRY_DONE);
    or

      RF_ScheduleCmdParams sched_params;
      RF_ScheduleCmdParams_init(&sched_params);
      
      sched_params.priority = RF_PriorityNormal;
      sched_params.endTime = 0;
      sched_params.allowDelay = RF_AllowDelayAny;
      
      
      rx_handle = RF_scheduleCmd(
                                     &RadioIF_RF_Obj,
                                     (RF_Op*)&Ieee154_0_cmdIeeeRx,
                                     &sched_params,
                                     &RadioIF_rfCoreEventCallback,
                                     IRQ_RX_BUF_FULL | IRQ_RX_ENTRY_DONE);
       /* Wait until RX operation finishes */
      RF_EventMask rx_events = RF_pendCmd(&RadioIF_RF_Obj, rx_handle, 0);

  • With IEEE you need to use the RF_scheduleCmd() API, not the RF_postCmd() API.
  • I have tested two of them.
    When I use Rx mode alone,they are the same. These two command can get receive packets.
    My question is:
    The program wants to achieve the following function: cc2650 has been receiving (because it is blackgroud command), and then every certain time to send a packet (foregroud command). At present, there is no problem with sending and receiving packets alone. But in the program, if the reception is turned on, then it cannot be sent out.
    In datasheet, it said "The transmit operation causes suspension of the background level operation until the
    transmission is done. "
    So I think cc2650 should also be able to send out data if it keeps on receiving.
  • Hi Ocnp,

    Are you trying to implement a proprietary application using the IEEE commands, or are you basing this of a stack such as the Zigbee stack?

    Either way, I suggest you look at this thread (and the thread linked from within) regarding using IEEE commands in the CC2650:
    e2e.ti.com/.../760024

    This is especially interesting for you in the sense of background/foreground commands, as this is not supported in the CC2650 version of the RF Driver that is available in the TI-RTOS release.