Import LinuxCNC source tree
This commit is contained in:
15
tests/halcompile/userspace/rand.comp
Normal file
15
tests/halcompile/userspace/rand.comp
Normal file
@@ -0,0 +1,15 @@
|
||||
component rand;
|
||||
option userspace;
|
||||
|
||||
pin out float out;
|
||||
license "GPL";
|
||||
;;
|
||||
#include <unistd.h>
|
||||
|
||||
void user_mainloop(void) {
|
||||
while(1) {
|
||||
usleep(1000);
|
||||
FOR_ALL_INSTS() out = drand48();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user