Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Michel Roelofs
dt_ctrl
Commits
a21657e8
Commit
a21657e8
authored
Jan 14, 2021
by
Jeroen Vreeken
Browse files
Merge branch 'jeroen' of
ssh://gitlab.camras.nl:777/dijkema/dt_ctrl
into jeroen
parents
fd5f452f
8e87e96c
Changes
4
Hide whitespace changes
Inline
Side-by-side
Dockerfile
View file @
a21657e8
...
...
@@ -2,7 +2,7 @@
# Create an empty directory and cd inside it.
# Get the source code from dt_ctrl in a subdirectry, e.g. through git:
# ```
# git clone gitlab.camras.nl/dijkema/dt_ctrl
# git clone
https://
gitlab.camras.nl/dijkema/dt_ctrl
# ```
# Create the docker file with `docker build --tag consoledemo .`
# This Dockerfile is hardcoded to run the websockets server at
...
...
@@ -16,10 +16,10 @@ RUN apt-get -y update
RUN
apt-get
-y
install
vim autoconf make gcc libtool-bin libglib2.0-dev libbison-dev flex git cmake build-essential libssl-dev screen telnet libmagic-dev wget
RUN
cd
/root
&&
git clone git://git.code.sf.net/p/libnova/libnova libnova-libnova
RUN
cd
/root/libnova-libnova
&&
libtoolize
&&
autoreconf
-i
&&
./configure
&&
make
install
RUN
cd
/root/libnova-libnova
&&
git checkout 655bcd1
&&
libtoolize
&&
autoreconf
-i
&&
./configure
&&
make
install
RUN
cd
/root
&&
git clone https://github.com/warmcat/libwebsockets.git
RUN
cd
/root/libwebsockets
&&
mkdir
build
&&
cd
build
&&
cmake ..
&&
make
&&
make
install
RUN
cd
/root/libwebsockets
&&
git checkout v2.4.2
&&
mkdir
build
&&
cd
build
&&
cmake ..
&&
make
&&
make
install
RUN
cd
/root
&&
git clone https://gitlab.camras.nl/dijkema/dt_ctrl
...
...
@@ -31,11 +31,9 @@ RUN ldconfig
RUN
chmod
a+rwx /root
RUN
mkdir
-p
/var/www/
RUN
cp
-r
/root/dt_ctrl/console/htdocs /var/www/
RUN
cp
-r
/root/dt_ctrl/console/js /var/www/
RUN
mkdir
-p
/var/www/htdocs/tle
&&
touch
/var/www/htdocs/tle/amateur.txt
&&
touch
/var/www/htdocs/tle/gps-ops.txt
&&
touch
/var/www/htdocs/tle/tle-new.txt
RUN
mkdir
-p
/var/www/console/htdocs/tle
&&
cd
/var/www/console/htdocs/tle
&&
wget
"http://celestrak.com/NORAD/elements/amateur.txt"
-v
-O
amateur.txt
&&
wget
"http://celestrak.com/NORAD/elements/tle-new.txt"
-v
-O
tle-new.txt
&&
wget
"http://celestrak.com/NORAD/elements/gps-ops.txt"
-v
-O
gps-ops.txt
&&
cd
-
RUN
apt-get
-y
install
apache2 net-tools
RUN
apt-get
update
&&
apt-get
-y
install
apache2 net-tools
RUN
mkdir
-p
/var/www/console/
&&
cp
-r
/root/dt_ctrl/console/htdocs /var/www/console
&&
cp
-r
/root/dt_ctrl/console/js /var/www/console
...
...
console/js/dt_view.js
View file @
a21657e8
...
...
@@ -380,7 +380,7 @@ function satellite_view(element)
/* satellite line */
s_v_this
.
ctx
.
strokeStyle
=
"
rgb(
25
5, 0, 0)
"
;
s_v_this
.
ctx
.
strokeStyle
=
"
rgb(5
0
,
5
0,
5
0)
"
;
s_v_this
.
ctx
.
beginPath
();
coord
=
this
.
coord2xy
(
coords
[
0
]);
...
...
@@ -391,7 +391,22 @@ function satellite_view(element)
coord
=
this
.
coord2xy
(
coords
[
i
]);
s_v_this
.
ctx
.
lineTo
(
coord
.
x
,
coord
.
y
);
}
s_v_this
.
ctx
.
stroke
();
s_v_this
.
ctx
.
beginPath
();
s_v_this
.
ctx
.
strokeStyle
=
"
rgb(0, 0, 0)
"
;
s_v_this
.
ctx
.
fillStyle
=
"
rgb(0, 255, 0)
"
;
coord_start
=
this
.
coord2xy
(
coords
[
0
])
s_v_this
.
ctx
.
arc
(
coord_start
.
x
,
coord_start
.
y
,
3
,
0
,
Math
.
PI
*
2
,
true
)
s_v_this
.
ctx
.
fill
();
s_v_this
.
ctx
.
stroke
();
s_v_this
.
ctx
.
beginPath
();
s_v_this
.
ctx
.
strokeStyle
=
"
rgb(0, 0, 0)
"
;
s_v_this
.
ctx
.
fillStyle
=
"
rgb(255, 0, 0)
"
;
coord_end
=
this
.
coord2xy
(
coords
[
coords
.
length
-
1
])
s_v_this
.
ctx
.
arc
(
coord_end
.
x
,
coord_end
.
y
,
3
,
0
,
Math
.
PI
*
2
,
true
)
s_v_this
.
ctx
.
fill
();
s_v_this
.
ctx
.
stroke
();
s_v_this
.
ctx
.
restore
();
...
...
controller/dt_ctrl.param
View file @
a21657e8
params {
{ "azimuth_position_offset", "value", (float)-1.4480417 }
{ "elevation_position_offset_r", "value", (float)
40680.083371
5 }
{ "elevation_position_offset_l", "value", (float)
10783.776612094
}
{ "elevation_position_offset_r", "value", (float)
-10791.77066
5 }
{ "elevation_position_offset_l", "value", (float)
36519.7036303
}
# limit controller for elevation
{ "elevation_pid", "kp", (float)1 }
{ "elevation_pid", "ki", (float)0 }
...
...
controller/dt_ctrl_el_sim.ctrl
View file @
a21657e8
...
...
@@ -108,7 +108,7 @@ params {
{ "dt_el_speed2pos_r", "kp", (float)0.0 }
{ "dt_el_speed2pos_r", "ki", (float)1.0 }
{ "dt_el_speed2pos_r", "kd", (float)0.0 }
{ "dt_el_offset_r", "value", (float)
-40680.0833715
}
{ "dt_el_offset_r", "value", (float)
10791.770665
}
{ "dt_el_pos_quantize_r", "quantum", (float)2.0 * pi / 16384.0 }
{ "dt_el_torque_gain_l", "gain", (float)1.0 }
...
...
@@ -128,7 +128,7 @@ params {
{ "dt_el_speed2pos_l", "kp", (float)0.0 }
{ "dt_el_speed2pos_l", "ki", (float)1.0 }
{ "dt_el_speed2pos_l", "kd", (float)0.0 }
{ "dt_el_offset_l", "value", (float)-
10783.776612094
}
{ "dt_el_offset_l", "value", (float)-
36519.7036303
}
{ "dt_el_pos_quantize_l", "quantum", (float)2.0 * pi / 16384.0 }
{ "dt_el_cross_tension_r", "gain", (float)-50.0 }
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment