Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: Freedman_v2 Nucleo_i2c_OLED_BME280_copy
Fork of mbed-src by
Diff: targets/hal/TARGET_NXP/TARGET_LPC23XX/can_api.c
- Revision:
- 227:7bd0639b8911
- Parent:
- 41:e8b66477f5bf
diff -r b062af740e40 -r 7bd0639b8911 targets/hal/TARGET_NXP/TARGET_LPC23XX/can_api.c
--- a/targets/hal/TARGET_NXP/TARGET_LPC23XX/can_api.c Wed Jun 11 09:45:09 2014 +0100
+++ b/targets/hal/TARGET_NXP/TARGET_LPC23XX/can_api.c Wed Jun 11 16:00:09 2014 +0100
@@ -13,10 +13,10 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
+#include "mbed_assert.h"
#include "can_api.h"
#include "cmsis.h"
#include "pinmap.h"
-#include "error.h"
#include <math.h>
#include <string.h>
@@ -161,9 +161,7 @@
CANName can_rd = (CANName)pinmap_peripheral(rd, PinMap_CAN_RD);
CANName can_td = (CANName)pinmap_peripheral(td, PinMap_CAN_TD);
obj->dev = (LPC_CAN_TypeDef *)pinmap_merge(can_rd, can_td);
- if ((int)obj->dev == NC) {
- error("CAN pin mapping failed");
- }
+ MBED_ASSERT((int)obj->dev != NC);
switch ((int)obj->dev) {
case CAN_1: LPC_SC->PCONP |= 1 << 13; break;
