Skip to content

Remove the deprecated CAN APIs. #12420

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 26, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 0 additions & 40 deletions drivers/CAN.h
Original file line number Diff line number Diff line change
Expand Up @@ -301,46 +301,6 @@ class CAN : private NonCopyable<CAN> {
*/
void attach(Callback<void()> func, IrqType type = RxIrq);

/** Attach a member function to call whenever a CAN frame received interrupt
* is generated.
*
* @param obj pointer to the object to call the member function on
* @param method pointer to the member function to be called
* @param type Which CAN interrupt to attach the member function to (CAN::RxIrq for message received, TxIrq for transmitted or aborted, EwIrq for error warning, DoIrq for data overrun, WuIrq for wake-up, EpIrq for error passive, AlIrq for arbitration lost, BeIrq for bus error)
* @deprecated
* The attach function does not support cv-qualifiers. Replaced by
* attach(callback(obj, method), type).
*/
template<typename T>
MBED_DEPRECATED_SINCE("mbed-os-5.1",
"The attach function does not support cv-qualifiers. Replaced by "
"attach(callback(obj, method), type).")
void attach(T *obj, void (T::*method)(), IrqType type = RxIrq)
{
// Underlying call thread safe
attach(callback(obj, method), type);
}

/** Attach a member function to call whenever a CAN frame received interrupt
* is generated.
*
* @param obj pointer to the object to call the member function on
* @param method pointer to the member function to be called
* @param type Which CAN interrupt to attach the member function to (CAN::RxIrq for message received, TxIrq for transmitted or aborted, EwIrq for error warning, DoIrq for data overrun, WuIrq for wake-up, EpIrq for error passive, AlIrq for arbitration lost, BeIrq for bus error)
* @deprecated
* The attach function does not support cv-qualifiers. Replaced by
* attach(callback(obj, method), type).
*/
template<typename T>
MBED_DEPRECATED_SINCE("mbed-os-5.1",
"The attach function does not support cv-qualifiers. Replaced by "
"attach(callback(obj, method), type).")
void attach(T *obj, void (*method)(T *), IrqType type = RxIrq)
{
// Underlying call thread safe
attach(callback(obj, method), type);
}

static void _irq_handler(uint32_t id, CanIrqType type);

#if !defined(DOXYGEN_ONLY)
Expand Down