Skip to main content
bernhard239955_stm1_stmicro_co
Associate
June 28, 2017
Question

Bug STM32CubeF1 V1.4.0: CanTxIrq

  • June 28, 2017
  • 3 replies
  • 785 views
Posted on June 28, 2017 at 13:58

The CANX_TX_IRQ is called unexpected cause the HAL_CAN_Receive_IT enables the CAN_IT_TME. As a result every can rx irq also the 

can tx irq is called. 

This costs time and i've some other side effects in my application.

In the F3 Lib the CAN_IT_TME is not enabled in the HAL_CAN_Receive_IT.

Am I wrong ?

Must STM change the Library ?

I've changed the following: 

// __HAL_CAN_ENABLE_IT(hcan, CAN_IT_EWG |

// CAN_IT_EPV |

// CAN_IT_BOF |

// CAN_IT_LEC |

// CAN_IT_ERR |

// CAN_IT_TME );

__HAL_CAN_ENABLE_IT(hcan, CAN_IT_EWG |

CAN_IT_EPV |

CAN_IT_BOF |

CAN_IT_LEC |

CAN_IT_ERR );

    This topic has been closed for replies.

    3 replies

    ST Technical Moderator
    June 28, 2017
    Posted on June 28, 2017 at 15:28

    Hi

    Silberer.Bernhard

    ,

    I will check and raise internally your reported issue, then I will keep you informed about the taken actions or explanation.

    Regards

    Imen

    In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question. Thanks
    bernhard239955_stm1_stmicro_co
    Associate
    July 12, 2017
    Posted on July 12, 2017 at 11:05

    Hi,

    Any News ?

    Regards

    Bernhard

    valentin
    Associate III
    July 13, 2017
    Posted on July 13, 2017 at 05:26

    Hmm, I just observed my F2 mcu go into TxIRQ after receiving messages, too. Found the same code in HAL_CAN_Receive_IT and changed according to your suggestion. Will test now. Sounds reasonable though - I wouldn't know why TME needs to be enabled for receiving.