Re: Jedicut and Arduino over USB

161
[quote=Jerome]
Hello,

I activate your account :)-D

Can you tell us more about your "AVR" solution ? What's an "AVR" and how much does this solution cost ?[/quote]

Hi, thanks for the activation :)

AVR is line of microcontrollers, the same one that arduino uses. Basically arduino is just some aditionall piece of software that is preprogrammed into AVR. So my soulotion is the same thing as with arduiono, it just doesn't need arduino preprogrammed. You can build very simple board, with for example AT90USB162 MCU and use it for cutting :)
Arduino boards are really easy to get and are quite cheap, so there might be no point to use my solution for someone who is about to purchase a board. I made it because I had my own board already and wanted to use it.

Re: Jedicut and Arduino over USB

162
I lost a week of looking why machine don't return to the start position after cut cycle.
In desperation I returned to LPT and machine began to work properly. Why?
When machine do single steps (e.g. x 100mm, y 1mm) it lost these steps (here y steps).
After inserting second delay in sendMotorCmd machine works properly.

My version:
void sendMotorCmd(byte cmd)
{
PORTD = (PORTD & 0x0F) | (cmd & 0xf0); // Directions first!

delayMicroseconds(5); // additional delay

PORTB = (PORTB & 0xF0) | (cmd & 0x0f); // and step
delayMicroseconds(5); // eventually wait a little bit
// and falling edge of step pulse
PORTB = (PORTB & 0xF0);
}
ZbigPL

Re: Jedicut and Arduino over USB

169
Hi Martin, Hi everyone in here!

I'm currently trying to help a friend (unfortunately "remote" to me in the meantime) to get a Jedicut -> Arduino -> China-TB6560 Foam-CNC to work. I have given him an Arduino Pro Mini (5V / 16mHz / ATmega328, with "China"-FTDI-Adaptor) and told him to wire it up according to the first Post in this Thread.
The CNC controller he is using is pretty much this:
http://www.ebay.de/itm/Komplette-CNC-Sc ... 51c2cb4992
With some more information on:
http://reprap.org/wiki/4_Axis_TB6560_CN ... Controller

We then proceeded to use a remote-support tool so i could connect on his Windows 7 PC and try to get this beast to run. As of now we still believe the wiring is correct.

So first lets come to the problem: We either get "smooth"(~ish...) movement on two different motors, with the others beeing activated (humming) but staying in place. This is true for cutting a test airfoil as well as "manual control" mode. Another result we obtained after some testing was very "erratic", "seldom" movement by the motors. Again only two, but two different ones.

I have tried the following:
- Unchanged Arduino code uploaded -> Only two of four motors move, but "smooth"
- Changed serial baud-rate to 57600, in both comport.ini and Arduino code -> same
- Tried to increase delay (25/30/50/75/150/300) in sendMotorCmd (with both baud-rates) -> no change
- Tried to comment out delay completel (with both baud-rates) -> no change
- Used a Serial-Port-Monitor to check what Jedi is doing. When cutting airfoils, the sequence i see is "A1FMLMLMLML...." and all ML until the end of the cut. This is NOT the "manual control" mode, but cutting an actual airfoil. This smells foul to me somehow, not sure what's going on there.
- Then using the Arduino Serial-Port-Command-Window-Thingy to send commands manually. I've tried things like "A1FMoMoMo..." ("o" ASCII is 01101111, right? So some given direction, but all motors should step). This lead to no step at all. "ML" still moved one motor ("L" is 01001100, so it should move two motors?). "Mx" should and does only move one motor -- the same as "ML", so that somehow means the two "middle" motors are the problem. Maybe more detailed testing to rule out "channels" is in order here. Checking characters could be A B D H, which are the 2nd byte in "BCD-Count-Up", right?

Then said friend checked the wiring again and apparently fixed some errors. I have yet to receive a detailed/hi-res photo to check it. The errors now were even more confusing. I've tried all of the above again, but even with the serial console, the motors would move only very erratic. Sending "ML", as a know "good" command that at least moved one motor reliably, only let it move one "click" in uneven long intervals, like, Bip ... Bip ... BipBipBip ... Bip ... BipBip ... ... ... Bip ... ... BipBip, not "even" and closely timed sending of the "ML. That also applied to manually sending long sequences of "ML", so much that i got the "S" reply and was sure i filled the buffer. When trying to use this new wiring with Jedi/Manual-Control, we would see even single "Bips" that maybe moved ~0.2mm instead of 50, as it "Bip"ed only twice per second or so -- even with cutting speed in options increased insanely. Again -- all this tested with various baud-rates and sendMotorCmd-Delays.

Now we're kind of out of ideas what else to check. We're really really desperate and need to device to replenish our hangars over winter -- as you may know yourself :D. We'd be really really really grateful for any kind of tips or hints on how to debug further, or what could possibly be wrong.
Thanks for reading!

Best Regards
-Dario Ernst
`); }); })(jQuery, window, document, phpbb);