Skip to content

Commit 3a804b2

Browse files
committed
update axis_mm.ini home
1 parent 21d8b42 commit 3a804b2

File tree

10 files changed

+54
-162
lines changed

10 files changed

+54
-162
lines changed

cmake/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ add_subdirectory(${SRC_DIR}/projects/qt_occ_draw)
173173
# Experimental scurve motion planner.
174174
# add_subdirectory(${SRC_DIR}/components/sc_tp)
175175

176-
# add_subdirectory(${SRC_DIR}/vendor/scurve)
176+
add_subdirectory(${SRC_DIR}/vendor/scurve)
177177

178178

179179

Lines changed: 6 additions & 102 deletions
Original file line numberDiff line numberDiff line change
@@ -1,107 +1,11 @@
11
# ninja log v5
2-
805 1484 1709975736146224817 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
3-
573 9143 1709971250894250648 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/scurve_construct_plot_autogen/mocs_compilation.cpp.o cb1113c0919619a2
4-
573 5655 1709971247410250668 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/main.cpp.o 4ad5561f2f93da74
5-
6 805 1709975735470224821 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
6-
1277 17162 1709967473402272402 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/qcustomplot.cpp.o 38a130e56e201187
7-
637 799 1709975735462224821 scurve_construct/scurve_construct cf03d80cb00a30d9
8-
4 573 1709971242330250697 scurve_construct_plot/scurve_construct_plot_autogen/timestamp 27ab5a4faabea0f0
9-
6 637 1709975735302224822 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
10-
6 5952 1709974161526233885 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/mainwindow.cpp.o a42b8d32b98eaf0
11-
7 851 1709974156426233915 scurve_construct/CMakeFiles/scurve_construct.dir/main.cpp.o ba672a3846e77a2e
12-
5 525 1709975804434224424 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
13-
5 582 1709975804490224424 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
14-
525 690 1709975804598224423 scurve_construct/scurve_construct cf03d80cb00a30d9
15-
582 1414 1709975805322224419 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
16-
6 570 1709975870326224044 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
17-
570 750 1709975870506224043 scurve_construct/scurve_construct cf03d80cb00a30d9
18-
6 813 1709975870570224043 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
19-
813 1528 1709975871282224039 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
20-
7 606 1709975960434223525 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
21-
606 742 1709975960570223525 scurve_construct/scurve_construct cf03d80cb00a30d9
22-
6 804 1709975960634223524 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
23-
804 1496 1709975961322223520 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
24-
5 599 1709976142102222479 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
25-
599 796 1709976142298222478 scurve_construct/scurve_construct cf03d80cb00a30d9
26-
5 815 1709976142318222478 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
27-
815 1504 1709976143002222474 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
28-
7 929 1709976156642222396 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
29-
9 1005 1709976156718222395 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
30-
1005 1225 1709976156938222394 scurve_construct/scurve_construct cf03d80cb00a30d9
31-
929 1941 1709976157650222390 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
32-
7 881 1709976193338222184 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
33-
7 903 1709976193362222184 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
34-
881 1069 1709976193526222183 scurve_construct/scurve_construct cf03d80cb00a30d9
35-
903 1844 1709976194298222179 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
36-
8 1221 1709976516482220323 scurve_construct/CMakeFiles/scurve_construct.dir/main.cpp.o ba672a3846e77a2e
37-
6 1336 1709976516598220323 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
38-
17 1543 1709976516806220321 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
39-
1543 1764 1709976517022220320 scurve_construct/scurve_construct cf03d80cb00a30d9
40-
6 6538 1709976521798220293 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/mainwindow.cpp.o a42b8d32b98eaf0
41-
6538 7190 1709976522446220289 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
42-
7 526 1709976597302219858 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
43-
6 594 1709976597370219857 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
44-
527 692 1709976597466219857 scurve_construct/scurve_construct cf03d80cb00a30d9
45-
594 1309 1709976598082219853 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
46-
6 629 1709976618898219733 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
47-
629 783 1709976619050219733 scurve_construct/scurve_construct cf03d80cb00a30d9
48-
6 821 1709976619090219732 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
49-
821 1509 1709976619774219728 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
50-
5 666 1709976669738219441 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
51-
6 779 1709976669854219440 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
52-
779 911 1709976669982219439 scurve_construct/scurve_construct cf03d80cb00a30d9
53-
666 1429 1709976670498219436 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
54-
8 948 1709976695166219294 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
55-
7 979 1709976695198219294 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
56-
948 1135 1709976695354219293 scurve_construct/scurve_construct cf03d80cb00a30d9
57-
979 2033 1709976696250219288 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
58-
5 619 1709976736802219054 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
59-
619 772 1709976736954219054 scurve_construct/scurve_construct cf03d80cb00a30d9
60-
5 793 1709976736974219053 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
61-
793 1479 1709976737658219049 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
62-
6 797 1709976781102218799 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
63-
7 811 1709976781114218799 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
64-
811 969 1709976781274218798 scurve_construct/scurve_construct cf03d80cb00a30d9
65-
797 1493 1709976781794218795 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
66-
8 732 1709977392646215277 scurve_construct/CMakeFiles/scurve_construct.dir/main.cpp.o ba672a3846e77a2e
67-
11 942 1709977392854215276 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
68-
7 956 1709977392870215276 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
69-
942 1095 1709977393010215275 scurve_construct/scurve_construct cf03d80cb00a30d9
70-
6 5981 1709977397894215247 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/mainwindow.cpp.o a42b8d32b98eaf0
71-
5981 6620 1709977398530215244 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
72-
7 660 1709977803394212912 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
73-
6 767 1709977803502212911 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
74-
660 819 1709977803554212911 scurve_construct/scurve_construct cf03d80cb00a30d9
75-
767 1486 1709977804218212907 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
76-
7 843 1709977812970212857 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
77-
843 1013 1709977813138212856 scurve_construct/scurve_construct cf03d80cb00a30d9
78-
7 1019 1709977813142212856 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
79-
1019 2086 1709977814206212850 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
80-
5 787 1709979391838203764 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
81-
5 811 1709979391866203764 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
82-
787 937 1709979391990203763 scurve_construct/scurve_construct cf03d80cb00a30d9
83-
811 1500 1709979392550203760 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
84-
6 643 1709979401538203708 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
85-
6 828 1709979401722203707 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
86-
828 1018 1709979401914203706 scurve_construct/scurve_construct cf03d80cb00a30d9
87-
643 1433 1709979402326203704 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
88-
7 631 1709980441486197719 scurve_construct/CMakeFiles/scurve_construct.dir/main.cpp.o ba672a3846e77a2e
89-
7 836 1709980441694197718 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
90-
7 874 1709980441730197718 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
91-
836 972 1709980441830197717 scurve_construct/scurve_construct cf03d80cb00a30d9
92-
6 5370 1709980446226197692 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/mainwindow.cpp.o a42b8d32b98eaf0
93-
5370 6008 1709980446862197688 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
94-
5 820 1709980566338197000 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
95-
5 845 1709980566362197000 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
96-
820 998 1709980566514196999 scurve_construct/scurve_construct cf03d80cb00a30d9
97-
845 1629 1709980567142196995 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
98-
5 661 1709980928862194912 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
99-
5 794 1709980928994194912 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
100-
794 928 1709980929130194911 scurve_construct/scurve_construct cf03d80cb00a30d9
101-
661 1527 1709980929726194907 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e
1022
5 169 1709990126478944553 scurve_construct/CMakeFiles/scurve_construct.dir/main.cpp.o ba672a3846e77a2e
103-
5 822 1709990127130944516 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
3+
4 5177 1709990131486944271 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/mainwindow.cpp.o a42b8d32b98eaf0
1044
6 831 1709990127138944515 scurve_construct/CMakeFiles/scurve_construct.dir/scurve_construct.cpp.o 753117ddd4cdc15a
5+
4 573 1709971242330250697 scurve_construct_plot/scurve_construct_plot_autogen/timestamp 27ab5a4faabea0f0
1056
831 939 1709990127246944509 scurve_construct/scurve_construct cf03d80cb00a30d9
106-
4 5177 1709990131486944271 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/mainwindow.cpp.o a42b8d32b98eaf0
7+
1277 17162 1709967473402272402 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/qcustomplot.cpp.o 38a130e56e201187
8+
5 822 1709990127130944516 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/__/scurve_construct/scurve_construct.cpp.o 5ac6aa0df3269f40
9+
573 5655 1709971247410250668 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/main.cpp.o 4ad5561f2f93da74
10+
573 9143 1709971250894250648 scurve_construct_plot/CMakeFiles/scurve_construct_plot.dir/scurve_construct_plot_autogen/mocs_compilation.cpp.o cb1113c0919619a2
10711
5177 5898 1709990132202944231 scurve_construct_plot/scurve_construct_plot 871a0abe7c229a5e

cmake/vendor/scurve/README.md

Lines changed: 25 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
### scurve_motion Library
22

3-
![S-curve Motion](screen.jpg)
3+
position control
4+
![S-curve Motion](position_control.jpg)
5+
velocity control
6+
![S-curve Motion](velocity_control.jpg)
47

58
### Overview
69

@@ -13,62 +16,36 @@ The `scurve_construct` library is a C++ library designed for jogging and positio
1316
- Support for both forward and reverse jogging.
1417
- Linear acceleration stage between concave & convex curve depending on jerk value.
1518
- Gui project to preview curve outputs in a qt-realtime-plot.
19+
- Velocity control.
1620
- Position control.
1721

1822
### Language
1923

20-
- ~/scurve_construct_c C
21-
- ~/scurve_construct C++
24+
C & C++.
2225

2326
### Example for c
2427

2528
```
26-
#include "scurve_construct.h"
27-
#include <stdio.h>
28-
#include <stdbool.h>
29-
30-
int main(int argc, char *argv[]) {
31-
32-
double jermax = 10;
33-
double accmax = 10;
34-
double maxvel = 10;
35-
double curvel = 0;
36-
double curacc = 0;
37-
double cyctim = 0.001;
38-
struct scurve_data d;
39-
40-
set_init_values(jermax,
41-
accmax,
42-
curvel,
43-
curacc,
44-
maxvel,
45-
cyctim,
46-
&d);
47-
48-
// Run up to the fwd tarpos.
49-
jog_forward_pressed(&d);
50-
51-
double vr, sr, ar;
52-
d.fwd_tarpos= 10;
53-
d.rev_tarpos = -10;
54-
55-
while(1){
56-
57-
// Update curve cycle.
58-
int state=update(&d, &vr, &ar, &sr);
59-
60-
printf("state: %i ", state);
61-
printf("vr: %f ", vr);
62-
printf("ar: %f ", ar);
63-
printf("sr: %f \n", sr);
64-
65-
if(state){
66-
break;
67-
}
68-
69-
}
70-
return 0;
29+
#include "scurve_construct.h"
30+
31+
double jermax=5;
32+
double maxacc=5;
33+
double maxvel=10;
34+
double intval=0.001;
35+
struct scurve_data s;
36+
37+
while(!s.finish){
38+
s=set_init_values_c(jermax,maxacc,maxvel,intval,s);
39+
s=jog_position_c(s,enable,tarpos); // Use position control.
40+
// s=jog_velocity_c(s,enable,tarpos); // Use velocity control.
41+
s=scurve_play_c(s);
42+
43+
// Results:
44+
s.guiacc
45+
s.guipos
46+
s.guivel
7147
}
48+
7249
```
7350

7451
### Prerequisites

cmake/vendor/scurve/gitnotes.txt

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# This are notes to run some git commands from terminal.
2+
3+
git init
4+
git config --global init.defaultBranch master
5+
git remote add origin https://github.com/grotius-cnc/scurve_construct.git
6+
git add .
7+
git branch -M main
8+
git push -u origin main
9+
10+
git add .
11+
git commit -m "commit"
12+
13+
git push -f origin main # this is force, will destroy history.
14+
git push -u origin main
15+
16+
git pull # To update the local clone
17+
18+
>> .gitignore # Add .gitingore file to the project to skip upload of dirs & files.

cmake/vendor/scurve/info.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
the scurve_struct.h is duplicated in /emc/motion/ dir.
74.6 KB
Loading

cmake/vendor/scurve/scurve_construct_plot/mainwindow.cpp

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ double maxacc=10;
1010
double maxvel=10;
1111
double intval=0.01;
1212
int enable=0;
13-
int mode=0;
1413
double tarpos=0;
1514
extern "C" struct scurve_data set_init_values_c(double jermax,
1615
double accmax,
@@ -81,11 +80,6 @@ MainWindow::MainWindow(QWidget *parent) :
8180
timer = new QTimer(this);
8281
connect(timer, SIGNAL( timeout() ), this, SLOT( updatePlot() ) );
8382
timer->start( timeInterval );
84-
85-
86-
87-
// scurve_construct().set_init_values(jermax,maxacc,curvel,curacc,maxvel,intval,s);
88-
8983
}
9084

9185
MainWindow::~MainWindow()
@@ -104,7 +98,6 @@ void MainWindow::updatePlot()
10498
m_XData.append( timeValue );
10599

106100
s=set_init_values_c(jermax,maxacc,maxvel,intval,s);
107-
// s=jog_velocity_c(s,enable,tarpos);
108101
s=jog_position_c(s,enable,tarpos);
109102
s=scurve_play_c(s);
110103

74.6 KB
Loading

configs/sim/axis/axis_mm.ini

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ HOME_LATCH_VEL = 25.4
220220
HOME_USE_INDEX = NO
221221
HOME_IGNORE_LIMITS = NO
222222
HOME_SEQUENCE = 1
223-
HOME_IS_SHARED = 1
223+
HOME_IS_SHARED = 0
224224
MAX_JERK = 500
225225

226226
[JOINT_1]
@@ -260,6 +260,6 @@ HOME_SEARCH_VEL = 127
260260
HOME_LATCH_VEL = 25.4
261261
HOME_USE_INDEX = NO
262262
HOME_IGNORE_LIMITS = NO
263-
HOME_SEQUENCE = 0
264-
HOME_IS_SHARED = 1
263+
HOME_SEQUENCE = 1
264+
HOME_IS_SHARED = 0
265265
MAX_JERK = 500

src/emc/motion/simple_tp.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ typedef struct simple_tp_t {
3939
double curr_acc;
4040
double max_jerk;
4141

42-
int init;
4342
struct scurve_data data;
4443
} simple_tp_t;
4544

0 commit comments

Comments
 (0)