linuxcnc trajectory planner

More
20 Oct 2024 14:24 #312678 by Grotius
Replied by Grotius on topic linuxcnc trajectory planner
Just removed the configuration files from the repository that point to my filepaths.
 
The following user(s) said Thank You: Aciera

Please Log in or Create an account to join the conversation.

More
20 Oct 2024 15:17 #312685 by Aciera
Replied by Aciera on topic linuxcnc trajectory planner
Recloned to new repo and went through the whole process again with the same result (ie same error) so I did
user@user-iMac:~/linuxcnc_trajectory_planner/cmake/build/motion$ cp motmod.so /home/user/linuxcnc_trajectory_planner/rtlib/

and ran './build.sh' but still the same.

Anyway, thanks for the effort, I'm out of time for today.
The following user(s) said Thank You: Grotius

Please Log in or Create an account to join the conversation.

More
20 Oct 2024 15:34 - 21 Oct 2024 07:29 #312687 by Aciera
Replied by Aciera on topic linuxcnc trajectory planner
Just occured to me that you maybe missed that the error message is not about 'motion.so' anymore but about 'liblinuxcnchal.so.0'.

motmod: dlopen: liblinuxcnchal.so.0: cannot open shared object file: No such file or directory

[edit]

The file does exist in the usual place so maybe a path issue somewhere:
user@user-iMac:~/linuxcnc_trajectory_planner$ find ./ -name liblinuxcnchal.*
./lib/liblinuxcnchal.so.0
./lib/liblinuxcnchal.so
Last edit: 21 Oct 2024 07:29 by Aciera.
The following user(s) said Thank You: Grotius

Please Log in or Create an account to join the conversation.

More
21 Oct 2024 08:04 - 21 Oct 2024 08:27 #312721 by Aciera
Replied by Aciera on topic linuxcnc trajectory planner
I think I may have found the underlying issue, something in the installation process of your repo seems to point motion.so to the 'lib' directory in the root folder (ie where a deb install would put them). Since I only have rip installs on this machine the 'lib' directory in my rootfolder (ie /lib) contains nothing related to linuxcnc (eg there is no ' liblinuxcnchal.so.0' in root/lib/)

As a test I copied it into the root/lib folder:
user@user-iMac:~/linuxcnc_trajectory_planner/lib$ sudo cp liblinuxcnchal.so.0 /lib

and ran 'build.sh'. There is no longer an error about 'liblinuxcnchal.so.0' but about another one:
motmod: dlopen: libClothoids.so.3: cannot open shared object file: No such file or directory

If I now also copy that one to the root/lib directory and run ./build.sh I can start the config.

So how would I now make it load the gcode file through the optimizer? Everything looks just like it always does.
Last edit: 21 Oct 2024 08:27 by Aciera.
The following user(s) said Thank You: Grotius

Please Log in or Create an account to join the conversation.

More
21 Oct 2024 08:39 #312723 by Aciera
Replied by Aciera on topic linuxcnc trajectory planner
Just noticed this looks a bit odd:
Install the project...
-- Install configuration: ""
-- Up-to-date: /home/user/linuxcnc_trajectory_planner/cmake/motion/../../rtlib/motmod.so
-- Up-to-date: /home/user/linuxcnc_trajectory_planner/cmake/planner/../../rtlib/tpmod.so
I guess this is what made you comment that the install does not work?
The following user(s) said Thank You: Grotius

Please Log in or Create an account to join the conversation.

More
21 Oct 2024 09:38 #312727 by Grotius
Replied by Grotius on topic linuxcnc trajectory planner
Hi Arciera,

Nice you can start lcnc now.

So how would I now make it load the gcode file through the optimizer? Everything looks just like it always does.
Start lcnc with open terminal, so you can verify the optimized gcode file is written trough the terminal output.
The gcode is optimized when you press the program run button.
This then starts the optimizer and saves a file in the ~/linuxcnc_trajectory_planner/cmake directory, named validate_xx.ngc. xx=random integer value.

Best worked for me is use a gcode file included a G64 P5 Q0. Then in next line a G61.

Then load the new produced file, and verify content.

I guess this is what made you comment that the install does not work?
Yes that is wrong filepath. The relative attached path"../../rtlib/motmod.so" is ok.


I think I may have found the underlying issue, something in the installation process of your repo seems to point motion.so to the 'lib' directory in the root folder (ie where a deb install would put them).
Maybe, the system would find them always in root lib dirs. I can remember me doing a "export" terminal command adding a
search dir to the system. Something like "sudo ldconfig".

In the link you can set your settings for the G64 P & Q values. With some more settings.
This is now compiled as fixed. To avoid confusion for me in earlyer stages of writing and testing the code.
Link

Good luck. I hope you can get something out.





 
The following user(s) said Thank You: Aciera

Please Log in or Create an account to join the conversation.

More
21 Oct 2024 12:25 #312737 by Aciera
Replied by Aciera on topic linuxcnc trajectory planner
Ok, so just so we are on the same page, here is what I get.

It creates the validate_<...>.ngc :
gcode loaded items: 1
gcode loaded items: 44
gcode loaded items: 135
gcode ready to be processed in thread.
set your gui maxvel to zero. Then the machine won't move when saving the gcode.
init curves done.
trim curves done.
added inbetween segments:178
Gcode file ready, filename:../../../cmake/validate_1048567314.ngc
thread completed.
vector pointer is not valid.
vector pointer is not valid.

Not sure if 'vector pointer is not valid' is a problem but I notice that when I run the created file it gets hung up after having run the first maybe 500 lines (this changes from one try to another). At this point linuxcnc cannot be recovered and has to be restarted.
 
 

Meanwhile more validate_<...>.ngc files have been created:


 


Are you seeing these hangups as well?
Attachments:
The following user(s) said Thank You: Grotius

Please Log in or Create an account to join the conversation.

More
21 Oct 2024 12:31 - 21 Oct 2024 12:46 #312738 by Aciera
Replied by Aciera on topic linuxcnc trajectory planner

 At this point linuxcnc cannot be recovered and has to be restarted


Correction: If I wait long enough after hitting the 'Stop program execution' button it does actually stop the program and the GUI is responsive again but loading another ngc file (not even running it) makes it hang again.

termial output:

USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 1 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 53 timeout
USRMOT: ERROR: command 1 timeout
USRMOT: ERROR: command 38 timeout
task: main loop took 35.003955 seconds
USRMOT: ERROR: command 11 timeout
task: main loop took 1.001118 seconds

 

Last edit: 21 Oct 2024 12:46 by Aciera.
The following user(s) said Thank You: Grotius

Please Log in or Create an account to join the conversation.

More
21 Oct 2024 12:40 - 21 Oct 2024 14:07 #312741 by Aciera
Replied by Aciera on topic linuxcnc trajectory planner
[edit]

I guess I haven't really thought through the process yet as it probably starts to reoptimize the validate_<...>.ngc code in the background when I hit the run button with the already optimized code loaded.


Looks cool.

So are you thinking of moving on to the planner now or are you still thinking about representing the clothoid fillets in a more concise form rather than a bunch of G1 line segments? 
Last edit: 21 Oct 2024 14:07 by Aciera.
The following user(s) said Thank You: Grotius

Please Log in or Create an account to join the conversation.

More
21 Oct 2024 16:49 #312774 by Grotius
Replied by Grotius on topic linuxcnc trajectory planner
Hi Arciera,

Yes once you pressed the run button it optimizes in the background.
Once you see terminal output: file created, you are ready to load the result file "validation_xx.ngc".
If you have the validation file loaded and press run again, it optimzes the validation file.
In theory this should not fail. But i have seen it can fail. So why it should fail i don't know yet.
Have to figur out this.

The pointer is not valid, is a message that the memory is released for the entire operation. This is good.

Looks cool.
Yeah. looks cool. You can write down any bug's related to the algo. For example lines over lines. Are there exceptions to make?
Testing is welcome.

So are you thinking of moving on to the planner now or are you still thinking about representing the clothoid fillets in a more concise form rather than a bunch of G1 line segments? 
Before moving to the planner, testing the scurve algo is now in progress for 2 day's. I had some problems today. So it can take a while.

When we have ready :
1. Filletizer
2. Scurve

Then we move to the trajectory planner itself. In this planner clothoid's are represented by only 2 points and 4 double values.
So the clothoid linestrips as you see now, are just for representation, validation. In the planner you won't see them anymore.

 
The following user(s) said Thank You: akb1212, Lcvette

Please Log in or Create an account to join the conversation.

Time to create page: 0.123 seconds
Powered by Kunena Forum