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.

AM625: PRU-EQEP/PTO issues

Part Number: AM625

Edited 2023-11-17

Hi experts

I want to know if PRUSS on AM62 can expand one eQEP and one PTU PTO output. Do we have any training materials?

BR

Ethan

  • Hello Ethan,

    A couple of clarification questions:

    1) I am not familiar with the "PTU" acronym. What does that stand for? 

    2) Please add additional information about what you are asking.

    It sounds like you want the PRU to directly control the eQEP module. This is definitely possible. However, we would need to have some discussion here, because I do not have a premade example that I can point you to of the PRU core controlling one of the on-chip peripherals for our K3 devices (AM62x, AM64x, AM65x).

    There is an example of how to do it on AM335x / AM437x / AM57x here: https://git.ti.com/cgit/pru-software-support-package/pru-software-support-package/tree/examples/am335x/PRU_ADC_onChip. The difference for K3 devices is that the separate DMSC firmware on K3 devices mean that the PRU would need to request ownership of the peripheral from the DM firmware instead of just manually turning everything on for the peripheral.

    Regards,

    Nick

  • Hello Nick

    Sorry for typo, it is PTO.

    1. The customer plans to use 4 * eQEP, but there are only three eQEP on the AM62x, so they want to use PRUSS to simulate one  eQEP.

    2. In addition, they also want to use PRUSS to simulate one PTO (pulse train output)  which speed is 100k at the same time.

    Is it possible?

  • Hello Ethan,

    PRU instructions on AM62x can execute in 3ns / instruction if the cores are running at 333MHz. So a PWM output signal with a clock frequency of 100kHz = a period of 10 us means ~3,000 PRU clock cycles per PWM output period.

    Thus, the output signal of a pulse train output is absolutely possible. Whether the PRU can do it depends on whether there is a lot of additional processing that needs to be done within that period. See this FAQ for more: https://e2e.ti.com/support/processors-group/processors/f/processors-forum/1241894/faq-can-the-pru-implement-my-interface-protocol

    I have not heard of any PRU projects written by a TIer to simulate an eQEP, but I will ask around just in case. If the customer needed to look into implementing the eQEP firmware themselves, I would refer them to the same FAQ for guidance on testing whether the PRU is a good fit for the usecase.

    Regards,

    Nick

  • It does not look like there is a finished PRU EQEP example implemented that I can point you to. I heard that someone might be looking at a PRU EQEP project on AM243x (PRU_ICSSG, different from PRUSS on AM62x) early next year. Feel free to ask back around February / March timeframe and reference this thread if you want me to check in on whether that project got done or not.

    I do not know much about motor control protocols, but it looks like the Tamagawa code from the https://www.ti.com/tool/PRU-ICSS-INDUSTRIAL-SW might be able to be used as a template?

    Regards,

    Nick

  • Hi Nick

    Thank you for your support and I will keep up to date with the latest developments on AM243x