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.

AM2612: Which peripheral can replace EQEP functionality in AM2612?

Part Number: AM2612


Tool/software:

In AM2612,I want to count external pulses (rising edges, falling edges, rising and falling edges), except the EQEP peripheral, are there any other peripherals that can achieve this function?

  • Hello Xiaoxue,

    My initial reaction is that would be best suited for the ECAP, have you looked at that peripheral and it's capabilities yet?

    Best Regards,

    Ralph Jacobi

  • I read the technical manual about ECAP, and I don't think ECAP is suitable. Because the ECAP captures the time between the edges and can not count the number of the edges.

  • Hello Xiaoxue,

    I will need to dig into this deeper on Monday, I thought the eCAP module would handle counts automatically but I can see what you are saying that this isn't outlined. Another option I would usually recommend would be timers in capture mode but the documentation around that for these MCUs isn't quite what I was expecting so need to look into the exact features available there as well.

    Best Regards,

    Ralph Jacobi

  • Hello Xiaoxue,

    I looked further into the ECAP peripheral and it looks like the signal monitor use case for edge detection is done in a manner where you'd have to monitor for the edges based on a specific time period and it wouldn't count the number of edges automatically either, even if a configuration to use it would be possible the counting aspect would have to be handled outside the peripheral and within the application structure.

    Meanwhile the RTI peripheral does not have a hook to trigger a capture / event from a GPIO rising / falling as far as I can see through the descriptions and available register settings.

    So you'd be left with the most basic approach - monitoring via a GPIO that can generate interrupts for rising edge or falling edge or on both edges and then create a subroutine to count the pulses as the GPIO peripheral registers the events and pushes the interrupts.

    Best Regards,

    Ralph Jacobi