On 9/11/2016 9:14 AM, beezerlm wrote: > I think my project would be simple enough to run through the PRU. My current > PLC loop I am running in the motion control software is just a few ifElse > statements that monitor position and change direction. Does the PRU have > access > to the eQEP without adding latency?
No and yes. :) No: Everything adds latency, even reading the PRU's direct inputs (although that only takes one clock cycle or 5 nS). Yes: Reading the eQEP from the PRU will only take a few hundred nS (during which time the PRU will be stalled), and the timing jitter will be fairly low. Unless you have particularly critical timing issues you didn't mention, the PRU can easily perform a few reads of the eQEP module while running whatever other control routines you need. > It's been a long time since I worked with a linux real time kernel and HAL. > I > did a similar project a long time ago using linuxCNC to control a Moog > hydraulic > servo-valve on an old Heald ID grinding machine. That was pretty cool to see > linux handle a Hydraulic cylinder on a PID loop. Here is a quick vid of it: > > https://www.youtube.com/watch?v=NMkNCSUJBvs > > The machinekit distro looks very similar but more streamlined and with better > hardware than what I had. I will have to dig into that a little more. If you're already somewhat familiar with HAL, this could be a good way to go. As I mentioned there are already eQEP and I/O drivers available, as well as building blocks like PID controllers, comparators, and even a classic ladder-logic control if you want to just port your PLC application. You can test things easily with the pre-built Machinekit uSD card image...just pop out the uSD if you decide you don't like using Machinekit: http://elinux.org/Beagleboard:BeagleBoneBlack_Debian#BBW.2FBBB_.28All_Revs.29_Machinekit -- Charles Steinkuehler [email protected] -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/beagleboard/3d26a443-4916-9408-e59e-a8692e2f7dbc%40steinkuehler.net. For more options, visit https://groups.google.com/d/optout.
