the microseconds
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, LCMark
-
- VIP Livecode Opensource Backer
- Posts: 3581
- Joined: Mon Jan 22, 2007 7:36 am
- Location: Berkeley, CA, US
- Contact:
Re: the microseconds
Ah. Did you not expect a fractional part? That's the whole point of the "long" variation.
PowerDebug http://powerdebug.ahsoftware.net
PowerTools http://www.ahsoftware.net/PowerTools/PowerTools.irev
PowerTools http://www.ahsoftware.net/PowerTools/PowerTools.irev
-
- Posts: 722
- Joined: Thu Sep 11, 2014 1:49 pm
- Location: The Netherlands
-
- VIP Livecode Opensource Backer
- Posts: 3581
- Joined: Mon Jan 22, 2007 7:36 am
- Location: Berkeley, CA, US
- Contact:
Re: the microseconds
Ha! I get it now. So there is indeed cross-platform parity for "the long milliseconds". Thanks.
PowerDebug http://powerdebug.ahsoftware.net
PowerTools http://www.ahsoftware.net/PowerTools/PowerTools.irev
PowerTools http://www.ahsoftware.net/PowerTools/PowerTools.irev
Re: the microseconds
I'm not sure that "the long milliseconds" returns anything of any value. For example, whenever it shows a fractional part to me, the fraction always has this value: ".000244" .
-
- VIP Livecode Opensource Backer
- Posts: 3581
- Joined: Mon Jan 22, 2007 7:36 am
- Location: Berkeley, CA, US
- Contact:
Re: the microseconds
What OS? I'm guessing Windows, where I would pretty much guarantee it not to work, given the system calls that are being made.
PowerDebug http://powerdebug.ahsoftware.net
PowerTools http://www.ahsoftware.net/PowerTools/PowerTools.irev
PowerTools http://www.ahsoftware.net/PowerTools/PowerTools.irev
Re: the microseconds
Yep. Windows 10.
Re: the microseconds
You can use LC to control a CNC for sure, but LC wouldn't be doing the dirty low level stuff.
I once made a mobile app with LC to control 2 robotic arms from different brands. Like a remote controller, I could move them in XYZ or Joint coordenates. Both arms had different ways of being controlled. To one of them I had to send Ethernet commands, while to the other I had to send COM commands. LC isn't directly controlling the servos, doing PWM, managing voltages and so on. Both robotic arms have a dedicated hardware. That hardware takes care of servo manipulation and PID control. From LC I can even change PID values, modify speeds and basicallly modify any setting I want. But in the end, the dedicated hardware is the one who is going to controls the motors, not LC.
LCMark explained some of the reasons of why a "multi-user, pre-emptive multi-thread/process systems" is not suitable for the job, in this case very time-precise motor controlling, and instead you need a single thread system such as a microcontroller, (or FPGA for more complex projects).
In the case of your friend's home made CNC, since it is homemade I guess he is using some sort of microcontroller, like an Arduino. Micros are very cheap and suited for the task. He could write the low level stuff, burn it to the microcontroller. Then from LC build the GUI and call some scripts/commands via communications protocols. One example: he could save the G-Code commands for mechanizing the piece in the CNC into the hardware, and then from LC calling/stopping scheduling them, measuring progress, etc.
Monox
Developing a Cyber Physical System.
https://www.monoxware.com/
Developing a Cyber Physical System.
https://www.monoxware.com/