查看: 1320|回复: 2

[其他] PE自动生成CAN驱动

[复制链接]

该用户从未签到

5

主题

18

帖子

0

注册会员

Rank: 2

积分
53
最后登录
1970-1-1
发表于 2015-4-20 19:39:31 | 显示全部楼层 |阅读模式
问题:编译提示,vectors.c中can0_receive_isr未定义,在CAN0.c中找到如下代码,我应该怎么解决。

/*
** ###################################################################
**
**  The interrupt service routine(s) must be implemented
**  by user in one of the following user modules.
**
**  If the "Generate ISR" option is enabled, Processor Expert generates
**  ISR templates in the CPU event module.
**
**  User modules:
**      VCU.c
**      Events.c
**
** ###################################################################
#pragma CODE_SEG __NEAR_SEG NON_BANKED
ISR(can0_receive_isr)
        {
        // NOTE: The routine should include the following actions to obtain
        //       correct functionality of the hardware.
        //
        //      The ISR is invoked by RXF flag. The RXF flag is cleared
        //      if a "1" is written to the flag in CAN0RFLG register.
        //      Example: CAN0RFLG = CAN0RFLG_RXF_MASK;
        }
#pragma CODE_SEG DEFAULT
*/
我知道答案 目前已有2人回答
回复

使用道具 举报

  • TA的每日心情
    开心
    2018-7-2 06:04
  • 签到天数: 1 天

    连续签到: 1 天

    [LV.1]初来乍到

    59

    主题

    2888

    帖子

    10

    金牌会员

    Rank: 6Rank: 6

    积分
    6031
    最后登录
    2025-8-21
    发表于 2015-4-22 14:45:18 | 显示全部楼层
    楼主你好
    请问你没有让PE自动生成中断服务函数吗?Generate ISR没enabled?


    如果使能了自动生成还不行,那么你可以将此段代码拷贝到Event.c或VCU.c里自己实现一下。


    该会员没有填写今日想说内容.
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    124

    主题

    3600

    帖子

    0

    金牌会员

    Rank: 6Rank: 6

    积分
    5781
    最后登录
    1970-1-1
    发表于 2015-5-14 09:07:23 | 显示全部楼层
    非常感谢你关于Kinetis的技术问题。如果你没有其他问题,我们将此帖默认为已解决.
    回复 支持 反对

    使用道具 举报

    您需要登录后才可以回帖 注册/登录

    本版积分规则

    关闭

    站长推荐上一条 /3 下一条

    Archiver|手机版|小黑屋|恩智浦技术社区

    GMT+8, 2025-9-12 15:08 , Processed in 0.084303 second(s), 23 queries , MemCache On.

    Powered by Discuz! X3.4

    Copyright © 2001-2024, Tencent Cloud.

    快速回复 返回顶部 返回列表