Re: [Emc-users] Capeless BBB
here's a driver which can be used as a cheat sheet to get started: https://github.com/Teknoman117/beaglebot/blob/master/encoders/patches/0001-tieqep-driver.patch -m Am 16.08.2013 um 12:58 schrieb Michael Haberler : > no reason to double up with an Arduino - two ideas: > > - you can tack on a soft encoder to Charles' PRU code; there are provisions > to tack on 'tasks' to the PRU dolist (PRU assembly, for the hardcore types) > - the AM3359 has three quadrature encoders available (eQEP0,1,2) > > two of them have all their pins broken out on the original beaglebone (eQEP1 > and eQEP2. eQEP0 only has channel B and the index pin broken out). > The Beaglebone Black has all three broken out. Those would be pretty high > speed. > > You need to write a driver for them. It boils down to the device tree magic > getting the pinmuxing right, and then setup the eQEP's as needed. > > The way I used to explore the builtin devices is to get the memory mapping in > place in Python, then fiddle registers until results make sense. Then make it > a HAL driver. > > example exploring the eCAP timer register: > https://github.com/mhaberler/linuxcnc/blob/unified-build-candidate-2/src/hal/components/pru_support/ecaptimer.py > > -m > > > > Am 16.08.2013 um 12:41 schrieb andy pugh : > >> On 16 August 2013 11:11, Andrew wrote: >>> What is the encoder pulse rate? >> >> About 10kHz. >> >> I suspect that an Arduino with interrupt-driven encoder counters might >> be a good solution. >> >> -- >> atp >> If you can't fix it, you don't own it. >> http://www.ifixit.com/Manifesto >> >> -- >> Get 100% visibility into Java/.NET code with AppDynamics Lite! >> It's a free troubleshooting tool designed for production. >> Get down to code-level detail for bottlenecks, with <2% overhead. >> Download for free and get started troubleshooting in minutes. >> http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk >> ___ >> Emc-users mailing list >> Emc-users@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/emc-users > > > -- > Get 100% visibility into Java/.NET code with AppDynamics Lite! > It's a free troubleshooting tool designed for production. > Get down to code-level detail for bottlenecks, with <2% overhead. > Download for free and get started troubleshooting in minutes. > http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/emc-users -- Get 100% visibility into Java/.NET code with AppDynamics Lite! It's a free troubleshooting tool designed for production. Get down to code-level detail for bottlenecks, with <2% overhead. Download for free and get started troubleshooting in minutes. http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] Capeless BBB
Yes. My non-cape cape is a bunch of wires connecting to a controller I already had, in this case the RAMPS board that was purchased for my printer. On Fri, Aug 16, 2013 at 5:41 AM, andy pugh wrote: > On 16 August 2013 11:11, Andrew wrote: > > What is the encoder pulse rate? > > About 10kHz. > > I suspect that an Arduino with interrupt-driven encoder counters might > be a good solution. > > -- > atp > If you can't fix it, you don't own it. > http://www.ifixit.com/Manifesto > > > -- > Get 100% visibility into Java/.NET code with AppDynamics Lite! > It's a free troubleshooting tool designed for production. > Get down to code-level detail for bottlenecks, with <2% overhead. > Download for free and get started troubleshooting in minutes. > http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/emc-users > > -- Get 100% visibility into Java/.NET code with AppDynamics Lite! It's a free troubleshooting tool designed for production. Get down to code-level detail for bottlenecks, with <2% overhead. Download for free and get started troubleshooting in minutes. http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] Capeless BBB
On 16 August 2013 11:58, Michael Haberler wrote: > no reason to double up with an Arduino - two ideas: I wasn't talking about doubling up. I was considering using _just_ an Arduino. The application is turning a stepper at a fixed ratio to an encoder. That's it. > - the AM3359 has three quadrature encoders available (eQEP0,1,2) That sounds like one project too many for me to handle. I haven't touched the tooltable since the Fest. -- atp If you can't fix it, you don't own it. http://www.ifixit.com/Manifesto -- Get 100% visibility into Java/.NET code with AppDynamics Lite! It's a free troubleshooting tool designed for production. Get down to code-level detail for bottlenecks, with <2% overhead. Download for free and get started troubleshooting in minutes. http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] Capeless BBB
On 8/16/2013 5:41 AM, andy pugh wrote: > On 16 August 2013 11:11, Andrew wrote: >> What is the encoder pulse rate? > > About 10kHz. That seems a bit fast for what's working now on the BBB and the 1 mS servo thread. The BBB does have hardware encoder inputs and the PRU, both of which could easily handle the encoder input rate, but code would need to be written. -- Charles Steinkuehler char...@steinkuehler.net signature.asc Description: OpenPGP digital signature -- Get 100% visibility into Java/.NET code with AppDynamics Lite! It's a free troubleshooting tool designed for production. Get down to code-level detail for bottlenecks, with <2% overhead. Download for free and get started troubleshooting in minutes. http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] Capeless BBB
no reason to double up with an Arduino - two ideas: - you can tack on a soft encoder to Charles' PRU code; there are provisions to tack on 'tasks' to the PRU dolist (PRU assembly, for the hardcore types) - the AM3359 has three quadrature encoders available (eQEP0,1,2) two of them have all their pins broken out on the original beaglebone (eQEP1 and eQEP2. eQEP0 only has channel B and the index pin broken out). The Beaglebone Black has all three broken out. Those would be pretty high speed. You need to write a driver for them. It boils down to the device tree magic getting the pinmuxing right, and then setup the eQEP's as needed. The way I used to explore the builtin devices is to get the memory mapping in place in Python, then fiddle registers until results make sense. Then make it a HAL driver. example exploring the eCAP timer register: https://github.com/mhaberler/linuxcnc/blob/unified-build-candidate-2/src/hal/components/pru_support/ecaptimer.py -m Am 16.08.2013 um 12:41 schrieb andy pugh : > On 16 August 2013 11:11, Andrew wrote: >> What is the encoder pulse rate? > > About 10kHz. > > I suspect that an Arduino with interrupt-driven encoder counters might > be a good solution. > > -- > atp > If you can't fix it, you don't own it. > http://www.ifixit.com/Manifesto > > -- > Get 100% visibility into Java/.NET code with AppDynamics Lite! > It's a free troubleshooting tool designed for production. > Get down to code-level detail for bottlenecks, with <2% overhead. > Download for free and get started troubleshooting in minutes. > http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk > ___ > Emc-users mailing list > Emc-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/emc-users -- Get 100% visibility into Java/.NET code with AppDynamics Lite! It's a free troubleshooting tool designed for production. Get down to code-level detail for bottlenecks, with <2% overhead. Download for free and get started troubleshooting in minutes. http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] Capeless BBB
Hi Andy, I created a DDS algorithm for our stepper-based robots that would use digital step rates of 1pps up to 300pps. This was the max speed using the battery, Freescale driver and steppers we had. The DDS interrupt algorithm ran on an Atmel 20MHz mega part with 1Hz resolution. It allowed us to set one stepper motor to 129Hz and the other to 130Hz step rates for example and they would stay in lock at these ratios. The interrupt was driven from a crystal controlled timer so the timing was pretty stable. I could have expanded the resolution of the DDS to 0.1Hz or 0.01Hz but we did not need any better resolution for our application than 1Hz. A stepgen routine running from a 1GHz processor should be capable of decent stepper timing resolution. I would set up a hardware timer interrupt and place about 30 instructions of fluff in the interrupt. Set an I/O pin low at the start of the interrupt and high at the end of the timer interrupt. This way you can scope the amount of time spent in the interrupt versus the rest of the code/OS. Increase the frequency of the timer interrupt until you are spending 20-30% of CPU time in the interrupt versus other code. This will tell you how many timer interrupts/second the CPU can run without corrupting the stack and messing with operation of the OS. A 1GHz part should run timer interrupts at 5-20MHz or so depending on the efficiency of stack entry & exit. At 10MHz you could control a number of steppers up to speeds of 1000.000Hz with a granularity of 0.001Hz. That has a nice CNC capability to it. One stepper could be running as fast as 1000.000Hz on one axis and another could run at as low 0.001Hz, tracking the first motor. For every 1M steps of the first stepper the second would step once. So I think the BBB is very capable. What kind of power drivers are you planning to use: step/dir or something else? We drove the bipolar steppers directly with Freescale MC33926 drivers using the micro's I/O pins. Dennis > ---Original Message--- > From: andy pugh > To: Enhanced Machine Controller (EMC) > Subject: [Emc-users] Capeless BBB > Sent: Aug 16 '13 04:39 > > Is it possible to use a BBB as a step generator or encoder reader > without any sort of cape at all? > > The application is synching a stepper motor to an encoder with a > variable ratio. > > -- > atp > If you can't fix it, you don't own it. > http://www.ifixit.com/Manifesto -- Get 100% visibility into Java/.NET code with AppDynamics Lite! It's a free troubleshooting tool designed for production. Get down to code-level detail for bottlenecks, with <2% overhead. Download for free and get started troubleshooting in minutes. http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] Capeless BBB
On 16 August 2013 11:11, Andrew wrote: > What is the encoder pulse rate? About 10kHz. I suspect that an Arduino with interrupt-driven encoder counters might be a good solution. -- atp If you can't fix it, you don't own it. http://www.ifixit.com/Manifesto -- Get 100% visibility into Java/.NET code with AppDynamics Lite! It's a free troubleshooting tool designed for production. Get down to code-level detail for bottlenecks, with <2% overhead. Download for free and get started troubleshooting in minutes. http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
Re: [Emc-users] Capeless BBB
2013/8/16 andy pugh > Is it possible to use a BBB as a step generator or encoder reader > without any sort of cape at all? > > The application is synching a stepper motor to an encoder with a > variable ratio. > I use BBB for stepper motor without a cape. Though I did not try encoders yet. What is the encoder pulse rate? Andrew -- Get 100% visibility into Java/.NET code with AppDynamics Lite! It's a free troubleshooting tool designed for production. Get down to code-level detail for bottlenecks, with <2% overhead. Download for free and get started troubleshooting in minutes. http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users
[Emc-users] Capeless BBB
Is it possible to use a BBB as a step generator or encoder reader without any sort of cape at all? The application is synching a stepper motor to an encoder with a variable ratio. -- atp If you can't fix it, you don't own it. http://www.ifixit.com/Manifesto -- Get 100% visibility into Java/.NET code with AppDynamics Lite! It's a free troubleshooting tool designed for production. Get down to code-level detail for bottlenecks, with <2% overhead. Download for free and get started troubleshooting in minutes. http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk ___ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users