Unexpected freezing

Hello, so my friend is working on a project and he experiences something I think is really odd, in a line of his program, he uses delay(2000); when that line is excuted based upon an input, the arduino freezes, when he changes it to delaymicroseconds(2000000); which is essentially the same thing, it doesn't freeze, how come ? PS: no interrupts are used, servo library used, wire library used.

The code is in this thread Controlling kk board with Arduino - Programming Questions - Arduino Forum
We found out that the only delay function causes the problem but we're not sure how to fix it. It's an quadcopter project, when we send 45 or 43 over TWI it should relay a message in the serial monitor. When delay is used, it works until we send 45 or 43, then it freezes. When delaymicroseconds is used with an equivalent value 2 seconds, it partailly works. Aren't both delays the samw ?

youssefaly97:
Hello, so my friend is working on a project and he experiences something I think is really odd, in a line of his program, he uses delay(2000); when that line is excuted based upon an input, the arduino freezes, when he changes it to delaymicroseconds(2000000); which is essentially the same thing, it doesn't freeze, how come ? PS: no interrupts are used, servo library used, wire library used.

http://www.arduino.cc/en/Reference/DelayMicroseconds

Currently, the largest value that will produce an accurate delay is 16383.

Aren't both delays the samw ?

Not based on the line above. You are running a quadcopter and you want to delay for 2 seconds?

youssefaly97:
The code is in this thread Controlling kk board with Arduino - Programming Questions - Arduino Forum

So this is, quite simply, a cross-post?

Should I lock this thread, or the other one?

no interrupts are used,

  Wire.onReceive(receiveEvent); // register event

That's an interrupt routine.

Ok, this is messy. You said that around 0.016 seconds is the maximum accurate delay, we need roughly 2 seconds or more so accuracy isn't needed here. Therefore they should be the same, what we don't get is why doesn't it freeze with delayMicrosceonds and freeze with delay ?

About the interrupts, I focused on the delay and value checking and didn't notice the onReceive, sorry about that.

I'm not sure what you mean by "lock" the thread ?

I'm not sure what you mean by "lock" the thread ?

Well, since this is a cross-post of another thread, we can lock this thread, forcing people to answer on the original thread.
Like this.