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
Tammo Jan Dijkema
dt_ctrl
Commits
eefd8984
Commit
eefd8984
authored
Dec 03, 2014
by
Jeroen Vreeken
Browse files
Add trigger section to control file.
Use immediate trigger in test.ctrl files. Fix some bugs
parent
966b1736
Changes
30
Hide whitespace changes
Inline
Side-by-side
Makefile
View file @
eefd8984
...
...
@@ -129,8 +129,7 @@ TARGETS:= $$($(DIR)_TMPTARGETS) $$(TARGETS)
DIR
:=
$(DIR)
endef
CFLAGS
:=
-pthread
-Icommon
-Icommon
/include
-Icontroller
-Iconsole
/console
-Iinclude
CFLAGS
:=
-pthread
-D_GNU_SOURCE
-Icommon
-Icommon
/include
-Icontroller
-Iconsole
/console
-Iinclude
LDFLAGS
:=
-pthread
-Lcommon
/lib
-Lcontroller
/lib
-Lconsole
/console/lib
-Llib
-Wl
,--as-needed
VPATH
+=
common/lib controller/lib console/console/lib lib
VPATH
+=
include
...
...
common/trace/trace.c
View file @
eefd8984
...
...
@@ -527,7 +527,7 @@ int trace_handle_recv(struct trace *trace)
int
trace_handle
(
struct
trace
*
trace
,
fd_set
*
set
)
{
if
(
!
set
||
FD_ISSET
(
trace
->
fd
,
set
))
{
if
(
trace
->
fd
>=
0
&&
(
!
set
||
FD_ISSET
(
trace
->
fd
,
set
))
)
{
trace_handle_recv
(
trace
);
}
return
0
;
...
...
common/utils/tcp_connect.c
View file @
eefd8984
...
...
@@ -29,8 +29,9 @@
#include <netdb.h>
#include <errno.h>
#include <sys/ioctl.h>
#include <sys/socket.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <sys/select.h>
#ifdef __linux__
#include <linux/sockios.h>
...
...
console/console/console_httpd.c
View file @
eefd8984
...
...
@@ -14,7 +14,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
...
...
@@ -189,7 +188,7 @@ static int status_reconnect(struct status *status)
{
int
fd
;
printf
(
"reconnect
\n
"
);
printf
(
"reconnect
: %s
\n
"
,
status
->
ident
);
fd
=
tcp_connect
(
status
->
host
,
status
->
port
);
if
(
fd
>=
0
)
{
poll_add
(
fd
,
POLLIN
|
POLLERR
);
...
...
console/console/log_proxy.c
View file @
eefd8984
...
...
@@ -17,8 +17,6 @@
*/
#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
...
...
console/console/mod_websocket_dt/mod_websocket_dt.c
View file @
eefd8984
...
...
@@ -15,8 +15,6 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#define _GNU_SOURCE
#include <stdlib.h>
#include <stdio.h>
#include <pthread.h>
...
...
console/console/start_console.sh
View file @
eefd8984
...
...
@@ -22,3 +22,4 @@ screen -S console -X screen -t console_azel console_azel
screen
-S
console
-X
screen
-t
console_manual console_manual
screen
-S
console
-X
screen
-t
console_sattracker console_sattracker
screen
-S
console
-X
screen
-t
console_weather console_weather
screen
-S
console
-X
screen
-t
console_httpd console_httpd
controller/block/block_filter_iir.test.ctrl
View file @
eefd8984
frequency 250
trigger {
{ "immediate" }
}
blocks {
{ "random", "noise" }
{ "filter_iir", "iir" }
...
...
controller/block/block_gain.test.ctrl
View file @
eefd8984
frequency 100
trigger {
{ "immediate" }
}
blocks {
{ "gain", "gain" }
...
...
controller/block/block_limit.test.ctrl
View file @
eefd8984
frequency 10
trigger {
{ "immediate" }
}
blocks {
{ "limit", "limit" }
...
...
controller/block/block_matrix_2x2.test.ctrl
View file @
eefd8984
frequency 10
trigger {
{ "immediate" }
}
blocks {
{ "matrix_2x2", "matrix" }
...
...
controller/block/block_not.test.ctrl
View file @
eefd8984
frequency 100
trigger {
{ "immediate" }
}
blocks {
{ "not", "not" }
...
...
controller/block/block_pid_aw.test.ctrl
View file @
eefd8984
frequency 100
trigger {
{ "immediate" }
}
blocks {
{ "pid_aw", "pid" }
...
...
controller/block/block_quantize.test.ctrl
View file @
eefd8984
frequency 10
trigger {
{ "immediate" }
}
blocks {
{ "quantize", "quantize" }
...
...
controller/block/block_rangecheck.test.ctrl
View file @
eefd8984
frequency 10
trigger {
{ "immediate" }
}
blocks {
{ "rangecheck", "rangecheck" }
...
...
controller/block/block_servo_state.test.ctrl
View file @
eefd8984
frequency 10
trigger {
{ "immediate" }
}
blocks {
{ "servo_state", "servo_state" }
...
...
controller/block/block_setpoint_generator_1d.c
View file @
eefd8984
...
...
@@ -101,6 +101,8 @@ static void setpoint_generator_1d_calculate(struct controller_block *spg)
cur_v
=
priv
->
cur_v
;
if
(
*
priv
->
reset
)
{
struct
command_entry
entry
;
priv
->
cmd_x
=
*
priv
->
reset_x
;
priv
->
cur_x
=
priv
->
cmd_x
;
priv
->
cur_done
=
true
;
...
...
@@ -108,6 +110,9 @@ static void setpoint_generator_1d_calculate(struct controller_block *spg)
priv
->
cmd_v
=
0
.
0
;
priv
->
cur_v
=
0
.
0
;
priv
->
id
=
COMMAND_ID_NONE
;
controller_command_queue_read
(
priv
->
command
,
&
entry
);
return
;
}
...
...
controller/block/block_setpoint_generator_1d.test.ctrl
View file @
eefd8984
frequency 10
trigger {
{ "immediate" }
}
blocks {
{ "setpoint_generator_1d", "spg", "spg", "na" }
...
...
controller/block/block_setpoint_generator_3d.c
View file @
eefd8984
...
...
@@ -233,6 +233,8 @@ static void setpoint_generator_3d_calculate(struct controller_block *spg)
t_max_a
=
priv
->
t_max_a
;
if
(
*
priv
->
reset
)
{
struct
command_entry
entry
;
priv
->
cmd_x
=
*
priv
->
reset_x
;
cur_x
=
priv
->
cmd_x
;
priv
->
cur_done
=
true
;
...
...
@@ -248,6 +250,8 @@ static void setpoint_generator_3d_calculate(struct controller_block *spg)
priv
->
start_t
=
0
;
priv
->
id
=
COMMAND_ID_NONE
;
controller_command_queue_read
(
priv
->
command
,
&
entry
);
goto
set_output
;
}
...
...
controller/block/block_setpoint_generator_3d.test.ctrl
View file @
eefd8984
frequency 10
trigger {
{ "immediate" }
}
blocks {
{ "setpoint_generator_3d", "spg", "spg", "na" }
...
...
Prev
1
2
Next
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