TI E2E™ 设计支持论坛将于 5 月 30 日至 6 月 1 日进行维护。如果您在此期间需要技术支持,请联系 TI 的客户支持中心寻求帮助。

This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

omapL-138 中dsplink的MSGQ_put函数 会导致iic 出现iic input/output error

在omapL138的dsplink开发 arm端:

如果是dsp端MSGQ_alloc  的申请一个msg ,然后arm端   执行MSGQ_put函数  ,  就不会导致iic   input/output error!!

但是在arm 端 MSGQ_alloc申请一个msg ,然后执行  MSGQ_put函数  ,就会导致 致iic   input/output error的错误,

初步怀疑是中断冲突,不知道各位大侠有木有关于  MSGQ_put函数到底用到哪些中断的文章啊?

或者有其他的可能?谢谢!

MSGQ_alloc (POOL_makePoolId(processorId, SAMPLE_POOL_ID),

                                 myAPP_BUFFER_SIZE ,

                                 (MSGQ_Msg *) &msg);

 

MSGQ_put (SampleDspMsgq,  (MSGQ_Msg)msg) ;

  • 您好,我想知道您的MSGQ_put函数的返回值是什么?以及程序运行到哪一步和程序的报错信息? 还有I2C总线传输的是什么内容?

  • 您好:

    我的i2c操作 用的是linux自带的驱动,使用ioctl函数从应用层传输一些数据。

    MSGQ_put函数的返回值是 status=8000

    代码如下:

    get_IIc();//此函数是实现对iic设备的一次读写;

      //且此次能成功读写。

    status = MSGQ_put (SampleDspMsgq,  (MSGQ_Msg)msg) ;

    printf("main  msg_put %x \n",status);

    get_IIc();//执行完上面的MSGQ_put就会出现下面的错误了。

    ioctl error1: Input/output error

    ioctl error2: Connection timed out

  • 而且我的程序中加了一个

    status = MSGQ_alloc (POOL_makePoolId(processorId, SAMPLE_POOL_ID),                                myAPP_BUFFER_SIZE , (MSGQ_Msg *) &msg);//新加了一个msg;

    ............

    ............

    status = MSGQ_put (SampleDspMsgq,  (MSGQ_Msg)msg) ;

    而且发现MSGQ_alloc去掉后,像dsplink例程message.c一样,就不会出现io error!

    然后MSGQ_put () failed. Status = [0x80008008]

  • 您好,将MSGQ_put的参数 SampleDspMsgq改为SampleGppMsgq试试。

  • 您好:

    MSGQ_put的参数 SampleDspMsgq改为SampleGppMsgq后,能用iic了,

    但由于

    我的status = MSGQ_get (SampleGppMsgq, WAIT_FOREVER, (MSGQ_Msg*)&msg) ;

    已经使用SampleGppMsgq,会让dsp端混乱掉,没有回复

    有时还会

    MSGQ_get () failed. Status = [0x80008002]

    不过,十分感谢您的建议,这个问题算是可以解决了。

  • 参数 SampleGppMsgq是arm端申请的,使用没有问题,

    但SampleDspMsgq却是dsp端申请的,但与i2c冲突,

    由于 这两个MSGQ都需要用到,所以不可能改为一个SampleGppMsgq,那么请问:

    MSGQ申请的中断的地方在那呢,CFG_OMAPL138GEM_SHMEM.c中貌似没有?

    那么还有其他的方法吗?

  • 您好,‘’The MessageQ module supports the structured sending and receiving of variable length messages. This module can be used for homogeneous (DSP to DSP) or heterogeneous (Arm to DSP) multi-processor messaging.‘’

    这是syslink中的MessageQ模块的说明,它的MessageQ不支持DSP to ARM, dsplink中的MessageQ模块应该也不支持DSP to ARM。

  • 感谢你解答

    我参照的是下面SDK

    dsplink_linux_1_65_00_01\dsplink\doc

    的文档,并没有说MSGQ是单向的啊,而且例程中MSGQ都是由DSP端建立的,不知道是否与你参考的文档有冲突。

    MSGQ_get () failed. Status = [0x80008002] 这个错误代号是什么意思??

  • 您好,MSGQ_get () failed. Status = [0x80008002] 这个错误代号的意思是‘’The GPP process is not attached to the specific processor‘’。