Practicality Of Arduino Controlled Precision Power Feed?

My understanding is that the Arduino is limited to driving the stepper about 300 RPM. Don't know if you can do better than that with the Mega, it's faster than the Uno that that information was good for. You may have to modify the current code that's available for stepper driving to get the speed you want. My understanding is that the overhead of running the Arduino translator on the chip is what causes the low speed. That's not noticeable until you start doing some very time sensitive things, like bit banging a 48 kHz signal while your also trying to read inputs, count and store steps and calculate what frequency you would like to be putting out.

I wrote the program myself and I didn't find that to be the case. The physical limitations of the motor and driver were the gooseneck. I remember that 1/4 stepping it and sending a pulse every 60 micro seconds to get it up a little over 1200 RPM. The motor would start stalling much higher than that.

The program was simple, it had a while loop that would check the status of a button, if it was pressed, it sent a pulse to the driver by switching a pin from high to low, then looping back to see if the button was still pressed. I recall running a test to output the length of time for each loop, and it was in the region of 10 microseconds which means in theory, if the stepper were physically capable of it, the arduino could send it to about 7500 RPM.
 
That's good to know. I think both the existing libraries for stepper (stepper and acelstepper, I think) had this issue with the UNO. It's very limiting on what you can do with a stepper with an Arduino. I'm not a programmer, it kind of turned me off using it, as I didn't want the learning curve of trying to write one from scratch. It's nice that you got it to work, but I'm still not interested in writing the codes from scratch, so it's still off the table for me.
 
Have you ever considered the TI Launchpad MSP430 instead of Arduino ??? http://www.ti.com/lsds/ti/tools-software/launchpads/overview/overview.page
While I'm not a programmer, a good friend of mine is and he prefers the MSP over the Arduino as it has a better and faster processor from what he's told me. I believe Yuriy Krushelnytskiy prefers the MSP format as well.
From my perspective, Arduino has more types of boards to choose from, seems to have a larger community, more add-ons, possibly larger library, and seems to be easier to learn. Again, this is just my opinion.
Here's a short comparison of advantages to each I found on a website when comparing the MSP430 to the Arduino Uno.

TI LaunchPad MSP430 Advantages:
  • Much lower cost. $10+tax and you're set. Arduno's $25+tax+shipping+buy-a-USB-cable can't compare.
  • Better built in LEDs, and a button.
  • Standard header spacing for pins, no odd 0.05" gap to foil breadboard/perfboard projects.
  • Much more flexible PWM controls. The MSP430G2553 uses a 16 bit timer for PWM rather than the Atmega328P's 8bit timer.
  • Very good low power draw features for long battery life.
  • Replacement chips don't need pre-programming/bootloading before working with the Energia IDE.

Arduino Uno Advantages:
  • Massively huge community support. This is not to be under-estimated.
  • Stackable shields mean the sky is the limit for feature expansion.
  • Capable of 40mA source/sink per pin; this is enough for very bright LEDs. The MSP430 LaunchPad caps out at ~ 4mA.
  • Can run at 5V or 3.3V (or anywhere between 1.8V and 5V if you change oscillators). The MSP430 caps out at 3.6V.
  • More IO pins, 20 vs 16. It might not seem like a huge difference, but I have projects where I've used 18 of those pins after using a pin expander to gain 8 more.
There are other options like Raspberry Pi which is more like a full blown computer. Here's a link to an interesting comparison of many formats.
https://makezine.com/2014/02/07/which-board-is-right-for-me/
 
Another huge advantage of the Arduino is that it has an open source high level language development environment. I don't know about the TI, but many of the other very capable microcontrollers out there only have publicly available assembly language development environments, the high level dev kits are available at high prices. It's also easy to learn. I think that has contributed greatly to it's popularity. If you had to use Atmel's tools and documentation to program it, it would still be almost unheard of.
 
Have you ever considered the TI Launchpad MSP430 instead of Arduino ??? http://www.ti.com/lsds/ti/tools-software/launchpads/overview/overview.page
While I'm not a programmer, a good friend of mine is and he prefers the MSP over the Arduino as it has a better and faster processor from what he's told me. I believe Yuriy Krushelnytskiy prefers the MSP format as well.
From my perspective, Arduino has more types of boards to choose from, seems to have a larger community, more add-ons, possibly larger library, and seems to be easier to learn. Again, this is just my opinion.
Here's a short comparison of advantages to each I found on a website when comparing the MSP430 to the Arduino Uno.

TI LaunchPad MSP430 Advantages:
  • Much lower cost. $10+tax and you're set. Arduno's $25+tax+shipping+buy-a-USB-cable can't compare.
  • Better built in LEDs, and a button.
  • Standard header spacing for pins, no odd 0.05" gap to foil breadboard/perfboard projects.
  • Much more flexible PWM controls. The MSP430G2553 uses a 16 bit timer for PWM rather than the Atmega328P's 8bit timer.
  • Very good low power draw features for long battery life.
  • Replacement chips don't need pre-programming/bootloading before working with the Energia IDE.

Arduino Uno Advantages:
  • Massively huge community support. This is not to be under-estimated.
  • Stackable shields mean the sky is the limit for feature expansion.
  • Capable of 40mA source/sink per pin; this is enough for very bright LEDs. The MSP430 LaunchPad caps out at ~ 4mA.
  • Can run at 5V or 3.3V (or anywhere between 1.8V and 5V if you change oscillators). The MSP430 caps out at 3.6V.
  • More IO pins, 20 vs 16. It might not seem like a huge difference, but I have projects where I've used 18 of those pins after using a pin expander to gain 8 more.
There are other options like Raspberry Pi which is more like a full blown computer. Here's a link to an interesting comparison of many formats.
https://makezine.com/2014/02/07/which-board-is-right-for-me/

I did consider the MSP430 over the Arduino Mega but I went with the Arduino for a bunch of reasons.

First is that is has 54 I/O pins and 16 analog input pins. That gave plenty of space for all of the buttons and switches I wanted as well as multiple sensors and a screen.

Second is the ease of programming. The programmer is very easy to use, you connect your arduino to your computer with the USB, the programmer finds it and you upload your program. Easy peasy. Writing the programs also isn't hard if you have basic programming knowledge. You tell it what your variables are, what each pin is doing, and then who it should do to those variables and those pins in response to inputs.

It also has plenty of low cost board alternatives for $10 or even less. For a beginner that has no idea what they are doing, its a lot easier to risk a $4 imported board than a $25 one.

Everything wasn't as up front and easy with the MSP430. It wasn't super obvious what you needed to be able to program it, what the board can do, what accessories would work for it, etc. Now that I have figured out the arduino, I could probably manage the MSP430, but I stick with arduino because thats where I started and its what I know now. Though if I need more performance than the arduinos can offer, I may just end up using an MSP430.
 
I wasn't putting down your choice for using Arduino. I was just posting other options available for the same or similar projects.
All platforms have their +'s and -'s, the end user have to make an informed decision on which to use.
Based on some of the replies here worrying about the Arduino being able to handle the task (valid or invalid), other option definitely will.
In as far as ease of programming, the last link in my previous post talks about the newer Energia prototyping platform for MSP which (according to the article):
"Energia lets you take your Arduino source code — your sketch — and simply drop it directly onto the MSP430".
While I haven't used it, may be worth a check for anyone able to code for Arduino, but wanting to use the MSP430.
 
There is something to be said about a manual machine with power feeds on all axis. You will find if done right you can machine as fast or faster than cnc it is just not lights off. Personally I like to have my manual machines setup this way I like my rotator cuffs and already had those and carpel tunnel surgeries and don’t need to go back. So I get the point. Hopefully you had gotten it all worked out the way you wanted.

I would like to CNC one day but one of my favorite things about machining is finding ways to complete operations manually and accurately. I have wanted a power feed for a while and after learning what I have about steppers and arduino, I thought I could make a better power feed for the same cost. I think the full CNC after all 3 motors, 3 drivers, power supply(ies?), ball screws, PC to run it, mounts, wiring, etc, will cost $600 - $700 which is a good bit more than I have to spend at the moment. The plan is to use this machine manually for another year or two then get a G0704 or similar and do a full CNC conversion on that one.
 
The OP now has his PM25 making chips.

 
Back
Top