Hello Experts,
I'm trying to produce a set of quadrature output which is shifted at 90deg by manipulating a pair of 0-5 volt signals from an SDS device as below:
canL2->SDSWriteAO(0x27C, 1, 0x13, 5);
canL2->SDSWriteAO(0x27C, 1, 0x13, 0);
canL2->SDSWriteAO(0x27C, 2, 0x13, 5);
canL2->SDSWriteAO(0x27C, 2, 0x13, 0);
I need to achieve maximum speed 200 ft/m with above resources.
Any feedback is highly appreciated.
Thanks in advance,
mraaf
What I have tried:
int nTimout = static_cast<unsigned int>(1000/m_nSliderCtrl);
SetTimer(1, nTimout, NULL);
DWORD dwInterval = static_cast<unsigned long>(nTimout/3);
if(nIDEvent == 1)
{
canL2->SDSWriteAO(0x27C, 1, 0x13, 5);
canL2->SDSWriteAO(0x27C, 2, 0x13, 0);
Sleep(dwInterval);
canL2->SDSWriteAO(0x27C, 1, 0x13, 5);
canL2->SDSWriteAO(0x27C, 2, 0x13, 5);
Sleep(dwInterval);
canL2->SDSWriteAO(0x27C, 1, 0x13, 0);
canL2->SDSWriteAO(0x27C, 2, 0x13, 5);
Sleep(dwInterval);
canL2->SDSWriteAO(0x27C, 1, 0x13, 0);
canL2->SDSWriteAO(0x27C, 2, 0x13, 0);
Sleep(dwInterval);
}
Output:
Output volt = 1.25V
Stable output 0-25Hz = 0-10 ft/m
Unstable output 25-50Hz = 10-20 ft/m
Max out at 50Hz (20ms)
What I have discovered:
12.5Hz = 5 ft/m --> Stable
25.0Hz = 10 ft/m --> Stable
50.0Hz = 20 ft/m --> Unstable, channel B occasionally shifted ahead channel A (resulting anti-clockwise rotation)
100.0Hz = 40 ft/m --> Unachievable