diff options
| author | Giovanni Di Sirio <gdisirio@gmail.com> | 2017-02-24 12:28:49 +0000 | 
|---|---|---|
| committer | Giovanni Di Sirio <gdisirio@gmail.com> | 2017-02-24 12:28:49 +0000 | 
| commit | 552a01b5d971111bb52d66e87d63ba5f0e607aed (patch) | |
| tree | b2427952fc993acb39df6a016bb225938b81ae0d /os/hal/include | |
| parent | 3c720a33274170db6e6c99a612a936bb2e094484 (diff) | |
| download | ChibiOS-552a01b5d971111bb52d66e87d63ba5f0e607aed.tar.gz ChibiOS-552a01b5d971111bb52d66e87d63ba5f0e607aed.tar.bz2 ChibiOS-552a01b5d971111bb52d66e87d63ba5f0e607aed.zip  | |
Renamed canReceive() and canTransmit() by adding the Timeout postfix for consistency. Old names still are available as macros and deprecated.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@10112 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/hal/include')
| -rw-r--r-- | os/hal/include/hal_can.h | 36 | 
1 files changed, 26 insertions, 10 deletions
diff --git a/os/hal/include/hal_can.h b/os/hal/include/hal_can.h index 7a94827fd..e91d8bd8b 100644 --- a/os/hal/include/hal_can.h +++ b/os/hal/include/hal_can.h @@ -114,6 +114,22 @@ typedef enum {   * @brief   Converts a mailbox index to a bit mask.
   */
  #define CAN_MAILBOX_TO_MASK(mbx) (1U << ((mbx) - 1U))
 +
 +/**
 + * @brief   Legacy name for @p canTransmitTimeout().
 + *
 + * @deprecated
 + */
 +#define canTransmit(canp, mailbox, ctfp, timeout)                           \
 +  canTransmitTimeout(canp, mailbox, ctfp, timeout)
 +
 +/**
 + * @brief   Legacy name for @p canReceiveTimeout().
 + *
 + * @deprecated
 + */
 +#define canReceive(canp, mailbox, crfp, timeout)                            \
 +  canReceiveTimeout(canp, mailbox, crfp, timeout)
  /** @} */
  /*===========================================================================*/
 @@ -131,16 +147,16 @@ extern "C" {                         canmbx_t mailbox,
                         const CANTxFrame *ctfp);
    bool canTryReceiveI(CANDriver *canp,
 -                       canmbx_t mailbox,
 -                       CANRxFrame *crfp);
 -  msg_t canTransmit(CANDriver *canp,
 -                    canmbx_t mailbox,
 -                    const CANTxFrame *ctfp,
 -                    systime_t timeout);
 -  msg_t canReceive(CANDriver *canp,
 -                   canmbx_t mailbox,
 -                   CANRxFrame *crfp,
 -                   systime_t timeout);
 +                      canmbx_t mailbox,
 +                      CANRxFrame *crfp);
 +  msg_t canTransmitTimeout(CANDriver *canp,
 +                           canmbx_t mailbox,
 +                           const CANTxFrame *ctfp,
 +                           systime_t timeout);
 +  msg_t canReceiveTimeout(CANDriver *canp,
 +                          canmbx_t mailbox,
 +                          CANRxFrame *crfp,
 +                          systime_t timeout);
  #if CAN_USE_SLEEP_MODE
    void canSleep(CANDriver *canp);
    void canWakeup(CANDriver *canp);
  | 
