- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In the " CDD_Sbc_fs23.c" file ,API "Sbc_fs23_SetWakeupConfig" has two lines code,as follows:
/*--------------------------------------------------*/
u16TxData = (u16RxData & (~(SBC_FS23_M_WK1_WUEN_WAKEUP_MASK | SBC_FS23_M_WK2_WUEN_WAKEUP_MASK | SBC_FS23_M_HVIO1_WUEN_WAKEUP_MASK | SBC_FS23_M_HVIO2_WUEN_WAKEUP_MASK | SBC_FS23_M_LVIO3_WUEN_WAKEUP_MASK | SBC_FS23_M_LVIO4_WUEN_WAKEUP_MASK | SBC_FS23_M_LVI5_WUEN_WAKEUP_MASK))) | (*Sbc_fs23_pConfigPtr->Sbc_fs23_WuConfig)[WakeupSettingId].IoWuEnReg;
..................................
u16TxData = (u16RxData & (~(SBC_FS23_M_CAN_WUEN_WAKEUP_MASK | SBC_FS23_M_LIN_WUEN_WAKEUP_MASK | SBC_FS23_M_LDT_WUEN_WAKEUP_MASK))) | (*Sbc_fs23_pConfigPtr->Sbc_fs23_WuConfig)[WakeupSettingId].Wu1EnReg;
/*--------------------------------------------------*/
what means about “(u16RxData & (~............))| XxxxCfg.XxxxEnReg"? why not directly use“(u16RxData | XxxxCfg.XxxxEnReg"?
I don't understand the operation of "u16RxData & (~............)".
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
By using & (~(………)) we make sure that those configurable wake-up and interrupt enable bits are first zeroed before writing a new value to them.
BR, Tomas
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I am using SBC FS23, and I am trying to configure it to CAN Wakeup. But SBC wakeup from LPOFF, with all CAN message.
How to configure it for wake up from particular CAN message? Is there a option available in SBC FS23?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
By using & (~(………)) we make sure that those configurable wake-up and interrupt enable bits are first zeroed before writing a new value to them.
BR, Tomas
