Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
B
bpm-sw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
bpm
bpm-sw
Commits
7a8e4912
Commit
7a8e4912
authored
Jan 29, 2016
by
Lucas Russo
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'devel'
Version v0.2
parents
2856e2ea
3804d6a4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
294 changed files
with
7614 additions
and
1789 deletions
+7614
-1789
.travis.yml
.travis.yml
+9
-26
COPYING
COPYING
+668
-159
Makefile
Makefile
+106
-58
README.md
README.md
+3
-3
bpm_sw.cfg
cfg/crude_defconfig/bpm_sw.cfg
+86
-6
bpm_sw.cfg
cfg/lnls_defconfig/bpm_sw.cfg
+35
-9
ci_build.sh
ci_build.sh
+59
-1
compile.sh
compile.sh
+40
-14
bpm-sw-architecture.dia
doc/img/bpm-sw-architecture.dia
+0
-0
Makefile
examples/Makefile
+20
-9
acq.c
examples/acq.c
+20
-3
acq_gen_sw_trigger.c
examples/acq_gen_sw_trigger.c
+138
-0
acq_trigger.c
examples/acq_trigger.c
+308
-0
leds.c
examples/leds.c
+1
-1
monit_amp.c
examples/monit_amp.c
+10
-1
monit_pos.c
examples/monit_pos.c
+10
-1
rffe_ctl.c
examples/rffe_ctl.c
+39
-1
si571_ctl.c
examples/si571_ctl.c
+1
-8
libbsmp
foreign/libbsmp
+1
-1
Makefile
foreign/libsdbfs/Makefile
+5
-5
--SDB-CONFIG--
foreign/libsdbfs/tools/--SDB-CONFIG--
+16
-0
Makefile
foreign/libsdbfs/tools/Makefile
+39
-0
gensdbfs.c
foreign/libsdbfs/tools/gensdbfs.c
+590
-0
gensdbfs.h
foreign/libsdbfs/tools/gensdbfs.h
+42
-0
sdb-extract.c
foreign/libsdbfs/tools/sdb-extract.c
+202
-0
sdb-read-lnls.c
foreign/libsdbfs/tools/sdb-read-lnls.c
+313
-0
sdb-read.c
foreign/libsdbfs/tools/sdb-read.c
+349
-0
pcie-driver
foreign/pcie-driver
+1
-1
mem_layout.h
include/boards/afcv3/priv_defs/mem_layout.h
+11
-1
mem_layout.h
include/boards/ml605/priv_defs/mem_layout.h
+11
-1
bpm_server.h
include/bpm_server.h
+1
-1
bpm_server_classes.h
include/bpm_server_classes.h
+7
-31
bpm_server_prelude.h
include/bpm_server_prelude.h
+23
-1
ad9510_regs.h
include/chips/ad9510_regs.h
+1
-1
e24aa64_regs.h
include/chips/e24aa64_regs.h
+1
-1
pca9547_regs.h
include/chips/pca9547_regs.h
+1
-1
si57x_regs.h
include/chips/si57x_regs.h
+1
-1
dev_io_core.h
include/dev_io_core.h
+1
-1
dev_io_err.h
include/dev_io_err.h
+1
-1
dev_io_exports.h
include/dev_io_exports.h
+1
-1
dev_io_utils.h
include/dev_io_utils.h
+1
-1
dev_mngr.h
include/dev_mngr.h
+1
-1
dev_mngr_core.h
include/dev_mngr_core.h
+12
-3
dev_mngr_dev_info.h
include/dev_mngr_dev_info.h
+1
-1
dev_mngr_err.h
include/dev_mngr_err.h
+1
-1
epics_mapping.h
include/epics_mapping.h
+33
-0
exp_msg_zmq.h
include/exp_msg_zmq.h
+1
-1
exp_ops_codes.h
include/exp_ops_codes.h
+1
-1
hal_stddef.h
include/hal_stddef.h
+1
-1
wb_acq_core_regs.h
include/hw/wb_acq_core_regs.h
+64
-28
wb_pos_calc_regs.h
include/hw/wb_pos_calc_regs.h
+5
-1
msg.h
include/msg.h
+1
-1
msg_err.h
include/msg_err.h
+1
-1
msg_macros.h
include/msg_macros.h
+1
-1
smpr_i2c_regs.h
include/protocols/smpr_i2c_regs.h
+1
-1
smpr_spi_regs.h
include/protocols/smpr_spi_regs.h
+1
-1
revision.h
include/revision.h
+1
-1
rw_param.h
include/rw_param.h
+1
-1
rw_param_codes.h
include/rw_param_codes.h
+1
-1
sm_ch_24aa64.h
include/sm_ch_24aa64.h
+1
-1
sm_ch_ad9510.h
include/sm_ch_ad9510.h
+1
-1
sm_ch_err.h
include/sm_ch_err.h
+1
-1
sm_ch_pca9547.h
include/sm_ch_pca9547.h
+1
-1
sm_ch_rffe.h
include/sm_ch_rffe.h
+1
-1
sm_ch_si57x.h
include/sm_ch_si57x.h
+1
-1
sm_io.h
include/sm_io.h
+2
-1
sm_io_bootstrap.h
include/sm_io_bootstrap.h
+1
-1
sm_io_err.h
include/sm_io_err.h
+1
-1
sm_io_exports.h
include/sm_io_exports.h
+1
-1
sm_io_exports_helper.h
include/sm_io_exports_helper.h
+2
-2
sm_io_mod_dispatch.h
include/sm_io_mod_dispatch.h
+22
-3
sm_io_thsafe_codes.h
include/sm_io_thsafe_codes.h
+1
-1
sm_pr.h
include/sm_pr.h
+1
-1
sm_pr_bsmp.h
include/sm_pr_bsmp.h
+1
-1
sm_pr_err.h
include/sm_pr_err.h
+1
-1
sm_pr_i2c.h
include/sm_pr_i2c.h
+1
-1
sm_pr_spi.h
include/sm_pr_spi.h
+1
-1
smio_thsafe_zmq_client.h
include/smio_thsafe_zmq_client.h
+1
-1
smio_thsafe_zmq_server.h
include/smio_thsafe_zmq_server.h
+1
-1
thsafe_msg_zmq.h
include/thsafe_msg_zmq.h
+1
-1
varg_macros.h
include/varg_macros.h
+1
-1
bpm-sw.ld
linker/bpm-sw.ld
+10
-0
run_valgrind.sh
run_valgrind.sh
+3
-3
bpm-sw-shutdown.sh
scripts/bpm-sw-shutdown.sh
+0
-6
bpm-sw-start.sh
scripts/bpm-sw-start.sh
+20
-0
bpm-sw-stop.sh
scripts/bpm-sw-stop.sh
+18
-0
gitlog2changelog.py
scripts/gitlog2changelog.py
+125
-0
find_acq_non_consecutive.m
scripts/matlab/find_acq_non_consecutive.m
+10
-0
find_non_consecutive.m
scripts/matlab/find_non_consecutive.m
+6
-0
omit_wraparound.m
scripts/matlab/omit_wraparound.m
+20
-0
bpm-sw-board
scripts/systemd/etc/sysconfig/bpm-sw-board
+14
-0
bpm-sw-board@.service
scripts/systemd/etc/systemd/system/bpm-sw-board@.service
+17
-0
bpm-sw.service
scripts/systemd/etc/systemd/system/bpm-sw.service
+2
-1
bpm-sw
scripts/sysvscripts/etc/init.d/bpm-sw
+301
-0
bpm-sw-board
scripts/sysvscripts/etc/sysconfig/bpm-sw-board
+14
-0
bpm-sw.conf
scripts/upstart/etc/init/bpm-sw.conf
+1
-1
board.mk
src/boards/afcv3/board.mk
+3
-0
epics_mapping.c
src/boards/afcv3/epics_mapping.c
+92
-0
board.mk
src/boards/ml605/board.mk
+3
-0
epics_mapping.c
src/boards/ml605/epics_mapping.c
+48
-0
revision.mk
src/boards/ml605/revision.mk
+3
-0
dev_io.c
src/dev_io/dev_io.c
+222
-82
dev_io_cfg.c
src/dev_io/dev_io_cfg.c
+11
-8
dev_io_core.c
src/dev_io/dev_io_core.c
+71
-56
dev_io_err.c
src/dev_io/dev_io_err.c
+1
-1
dev_io_utils.c
src/dev_io/dev_io_utils.c
+1
-1
dev_mngr.c
src/dev_mngr/dev_mngr.c
+78
-42
dev_mngr_core.c
src/dev_mngr/dev_mngr_core.c
+73
-34
dev_mngr_dev_info.c
src/dev_mngr/dev_mngr_dev_info.c
+1
-1
dev_mngr_err.c
src/dev_mngr/dev_mngr_err.c
+1
-1
README.md
src/libs/README.md
+6
-0
Makefile
src/libs/libbpmclient/Makefile
+58
-52
README.deps
src/libs/libbpmclient/README.deps
+1
-2
compile.sh
src/libs/libbpmclient/compile.sh
+22
-3
bpm_client.h
src/libs/libbpmclient/include/bpm_client.h
+1
-1
bpm_client_classes.h
src/libs/libbpmclient/include/bpm_client_classes.h
+4
-4
bpm_client_codes.h
src/libs/libbpmclient/include/bpm_client_codes.h
+1
-1
bpm_client_core.h
src/libs/libbpmclient/include/bpm_client_core.h
+169
-35
bpm_client_err.h
src/libs/libbpmclient/include/bpm_client_err.h
+3
-1
bpm_client_prelude.h
src/libs/libbpmclient/include/bpm_client_prelude.h
+1
-1
bpm_client_revision.h
src/libs/libbpmclient/include/bpm_client_revision.h
+1
-1
bpm_client_rw_param.h
src/libs/libbpmclient/include/bpm_client_rw_param.h
+4
-1
bpm_client_rw_param_codes.h
src/libs/libbpmclient/include/bpm_client_rw_param_codes.h
+1
-1
bpm_client_core.c
src/libs/libbpmclient/src/bpm_client_core.c
+323
-458
bpm_client_err.c
src/libs/libbpmclient/src/bpm_client_err.c
+1
-1
bpm_client_revision.c
src/libs/libbpmclient/src/bpm_client_revision.c
+1
-1
bpm_client_rw_param.c
src/libs/libbpmclient/src/bpm_client_rw_param.c
+50
-5
Makefile
src/libs/libconvc/Makefile
+59
-17
README.deps
src/libs/libconvc/README.deps
+1
-0
compile.sh
src/libs/libconvc/compile.sh
+40
-0
convc.h
src/libs/libconvc/include/convc.h
+13
-0
convc_classes.h
src/libs/libconvc/include/convc_classes.h
+50
-0
convc_core.h
src/libs/libconvc/include/convc_core.h
+10
-5
convc_err.h
src/libs/libconvc/include/convc_err.h
+9
-1
convc_prelude.h
src/libs/libconvc/include/convc_prelude.h
+16
-0
convc_core.c
src/libs/libconvc/src/convc_core.c
+1
-9
convc_err.c
src/libs/libconvc/src/convc_err.c
+2
-2
version.sh
src/libs/libconvc/version.sh
+30
-0
Makefile
src/libs/libdisptable/Makefile
+59
-17
README.deps
src/libs/libdisptable/README.deps
+1
-0
compile.sh
src/libs/libdisptable/compile.sh
+40
-0
disptable.h
src/libs/libdisptable/include/disptable.h
+13
-0
disptable_classes.h
src/libs/libdisptable/include/disptable_classes.h
+53
-0
disptable_core.h
src/libs/libdisptable/include/disptable_core.h
+10
-5
disptable_err.h
src/libs/libdisptable/include/disptable_err.h
+11
-3
disptable_prelude.h
src/libs/libdisptable/include/disptable_prelude.h
+16
-0
disptable_core.c
src/libs/libdisptable/src/disptable_core.c
+17
-24
disptable_err.c
src/libs/libdisptable/src/disptable_err.c
+2
-2
version.sh
src/libs/libdisptable/version.sh
+30
-0
Makefile
src/libs/liberrhand/Makefile
+46
-22
README.deps
src/libs/liberrhand/README.deps
+1
-0
compile.sh
src/libs/liberrhand/compile.sh
+40
-0
errhand.h
src/libs/liberrhand/include/errhand.h
+13
-0
errhand_assert.h
src/libs/liberrhand/include/errhand_assert.h
+8
-3
errhand_classes.h
src/libs/liberrhand/include/errhand_classes.h
+55
-0
errhand_core.h
src/libs/liberrhand/include/errhand_core.h
+13
-0
errhand_local_print.h
src/libs/liberrhand/include/errhand_local_print.h
+9
-1
errhand_opts.h
src/libs/liberrhand/include/errhand_opts.h
+9
-1
errhand_prelude.h
src/libs/liberrhand/include/errhand_prelude.h
+16
-0
errhand_print.h
src/libs/liberrhand/include/errhand_print.h
+10
-6
errhand_subsys.h
src/libs/liberrhand/include/errhand_subsys.h
+9
-1
varg_macros.h
src/libs/liberrhand/include/varg_macros.h
+1
-1
errhand_local_print.c
src/libs/liberrhand/src/errhand_local_print.c
+2
-2
errhand_print.c
src/libs/liberrhand/src/errhand_print.c
+2
-9
errhand_subsys.c
src/libs/liberrhand/src/errhand_subsys.c
+2
-3
version.sh
src/libs/liberrhand/version.sh
+30
-0
Makefile
src/libs/libhutils/Makefile
+43
-19
README.deps
src/libs/libhutils/README.deps
+1
-0
compile.sh
src/libs/libhutils/compile.sh
+40
-0
hutils.h
src/libs/libhutils/include/hutils.h
+13
-0
hutils_classes.h
src/libs/libhutils/include/hutils_classes.h
+52
-0
hutils_core.h
src/libs/libhutils/include/hutils_core.h
+13
-0
hutils_err.h
src/libs/libhutils/include/hutils_err.h
+9
-1
hutils_math.h
src/libs/libhutils/include/hutils_math.h
+8
-3
hutils_prelude.h
src/libs/libhutils/include/hutils_prelude.h
+16
-0
hutils_utils.h
src/libs/libhutils/include/hutils_utils.h
+23
-13
hutils_err.c
src/libs/libhutils/src/hutils_err.c
+2
-2
hutils_math.c
src/libs/libhutils/src/hutils_math.c
+2
-3
hutils_utils.c
src/libs/libhutils/src/hutils_utils.c
+115
-23
version.sh
src/libs/libhutils/version.sh
+30
-0
Makefile
src/libs/libllio/Makefile
+193
-0
README.deps
src/libs/libllio/README.deps
+7
-0
compile.sh
src/libs/libllio/compile.sh
+41
-0
pcie_regs.h
src/libs/libllio/include/hw/pcie_regs.h
+1
-1
ll_io.h
src/libs/libllio/include/ll_io.h
+13
-0
ll_io_classes.h
src/libs/libllio/include/ll_io_classes.h
+65
-0
ll_io_core.h
src/libs/libllio/include/ll_io_core.h
+3
-3
ll_io_dev_info.h
src/libs/libllio/include/ll_io_dev_info.h
+1
-1
ll_io_endpoint.h
src/libs/libllio/include/ll_io_endpoint.h
+1
-1
ll_io_err.h
src/libs/libllio/include/ll_io_err.h
+3
-1
ll_io_eth.h
src/libs/libllio/include/ll_io_eth.h
+1
-1
ll_io_eth_utils.h
src/libs/libllio/include/ll_io_eth_utils.h
+3
-1
ll_io_pcie.h
src/libs/libllio/include/ll_io_pcie.h
+1
-1
ll_io_prelude.h
src/libs/libllio/include/ll_io_prelude.h
+16
-0
ll_io_utils.h
src/libs/libllio/include/ll_io_utils.h
+3
-1
ll_io_core.c
src/libs/libllio/src/ll_io_core.c
+3
-3
ll_io_dev_info.c
src/libs/libllio/src/ll_io_dev_info.c
+5
-5
ll_io_endpoint.c
src/libs/libllio/src/ll_io_endpoint.c
+2
-2
ll_io_err.c
src/libs/libllio/src/ll_io_err.c
+2
-2
ll_io_utils.c
src/libs/libllio/src/ll_io_utils.c
+2
-2
ll_io_eth.c
src/libs/libllio/src/ops/ll_io_eth.c
+2
-4
ll_io_eth_utils.c
src/libs/libllio/src/ops/ll_io_eth_utils.c
+2
-2
ll_io_pcie.c
src/libs/libllio/src/ops/ll_io_pcie.c
+26
-4
ops.mk
src/libs/libllio/src/ops/ops.mk
+1
-1
version.sh
src/libs/libllio/version.sh
+30
-0
ll_io.mk
src/ll_io/ll_io.mk
+0
-15
exp_msg_zmq.c
src/msg/exp_ops/exp_msg_zmq.c
+1
-1
msg.c
src/msg/msg.c
+2
-2
msg_err.c
src/msg/msg_err.c
+1
-1
smio_thsafe_zmq_client.c
src/msg/smio_thsafe_ops/smio_thsafe_zmq_client.c
+7
-7
smio_thsafe_zmq_server.c
src/msg/smio_thsafe_ops/smio_thsafe_zmq_server.c
+3
-3
thsafe_msg_zmq.c
src/msg/smio_thsafe_ops/thsafe_msg_zmq.c
+1
-1
revision.c
src/revision/revision.c
+1
-1
sm_ch_24aa64.c
src/sm_io/chips/sm_ch_24aa64.c
+1
-1
sm_ch_ad9510.c
src/sm_io/chips/sm_ch_ad9510.c
+1
-1
sm_ch_ad9510_defaults.h
src/sm_io/chips/sm_ch_ad9510_defaults.h
+1
-1
sm_ch_err.c
src/sm_io/chips/sm_ch_err.c
+1
-1
sm_ch_pca9547.c
src/sm_io/chips/sm_ch_pca9547.c
+1
-1
sm_ch_rffe.c
src/sm_io/chips/sm_ch_rffe.c
+1
-1
sm_ch_rffe_defaults.h
src/sm_io/chips/sm_ch_rffe_defaults.h
+1
-1
sm_ch_si57x.c
src/sm_io/chips/sm_ch_si57x.c
+1
-1
sm_ch_si57x_defaults.h
src/sm_io/chips/sm_ch_si57x_defaults.h
+1
-1
ddr3_map.c
src/sm_io/modules/acq/ddr3_map.c
+1
-1
sm_io_acq_codes.h
src/sm_io/modules/acq/sm_io_acq_codes.h
+22
-3
sm_io_acq_core.c
src/sm_io/modules/acq/sm_io_acq_core.c
+6
-3
sm_io_acq_core.h
src/sm_io/modules/acq/sm_io_acq_core.h
+29
-3
sm_io_acq_exp.c
src/sm_io/modules/acq/sm_io_acq_exp.c
+506
-71
sm_io_acq_exp.h
src/sm_io/modules/acq/sm_io_acq_exp.h
+1
-1
sm_io_acq_exports.c
src/sm_io/modules/acq/sm_io_acq_exports.c
+120
-1
sm_io_acq_exports.h
src/sm_io/modules/acq/sm_io_acq_exports.h
+11
-2
sm_io_afc_diag_codes.h
src/sm_io/modules/afc_diag/sm_io_afc_diag_codes.h
+1
-1
sm_io_afc_diag_core.c
src/sm_io/modules/afc_diag/sm_io_afc_diag_core.c
+1
-1
sm_io_afc_diag_core.h
src/sm_io/modules/afc_diag/sm_io_afc_diag_core.h
+1
-1
sm_io_afc_diag_defaults.c
src/sm_io/modules/afc_diag/sm_io_afc_diag_defaults.c
+1
-1
sm_io_afc_diag_defaults.h
src/sm_io/modules/afc_diag/sm_io_afc_diag_defaults.h
+1
-1
sm_io_afc_diag_exp.c
src/sm_io/modules/afc_diag/sm_io_afc_diag_exp.c
+3
-1
sm_io_afc_diag_exp.h
src/sm_io/modules/afc_diag/sm_io_afc_diag_exp.h
+1
-1
sm_io_afc_diag_exports.c
src/sm_io/modules/afc_diag/sm_io_afc_diag_exports.c
+1
-1
sm_io_afc_diag_exports.h
src/sm_io/modules/afc_diag/sm_io_afc_diag_exports.h
+1
-1
sm_io_dsp_codes.h
src/sm_io/modules/dsp/sm_io_dsp_codes.h
+4
-2
sm_io_dsp_core.c
src/sm_io/modules/dsp/sm_io_dsp_core.c
+1
-1
sm_io_dsp_core.h
src/sm_io/modules/dsp/sm_io_dsp_core.h
+1
-1
sm_io_dsp_defaults.c
src/sm_io/modules/dsp/sm_io_dsp_defaults.c
+1
-1
sm_io_dsp_defaults.h
src/sm_io/modules/dsp/sm_io_dsp_defaults.h
+4
-5
sm_io_dsp_exp.c
src/sm_io/modules/dsp/sm_io_dsp_exp.c
+14
-1
sm_io_dsp_exp.h
src/sm_io/modules/dsp/sm_io_dsp_exp.h
+1
-1
sm_io_dsp_exports.c
src/sm_io/modules/dsp/sm_io_dsp_exports.c
+14
-1
sm_io_dsp_exports.h
src/sm_io/modules/dsp/sm_io_dsp_exports.h
+3
-2
sm_io_fmc130m_4ch_codes.h
src/sm_io/modules/fmc130m_4ch/sm_io_fmc130m_4ch_codes.h
+1
-1
sm_io_fmc130m_4ch_core.c
src/sm_io/modules/fmc130m_4ch/sm_io_fmc130m_4ch_core.c
+1
-1
sm_io_fmc130m_4ch_core.h
src/sm_io/modules/fmc130m_4ch/sm_io_fmc130m_4ch_core.h
+1
-1
sm_io_fmc130m_4ch_defaults.c
src/sm_io/modules/fmc130m_4ch/sm_io_fmc130m_4ch_defaults.c
+2
-2
sm_io_fmc130m_4ch_defaults.h
src/sm_io/modules/fmc130m_4ch/sm_io_fmc130m_4ch_defaults.h
+1
-1
sm_io_fmc130m_4ch_exp.c
src/sm_io/modules/fmc130m_4ch/sm_io_fmc130m_4ch_exp.c
+70
-69
sm_io_fmc130m_4ch_exp.h
src/sm_io/modules/fmc130m_4ch/sm_io_fmc130m_4ch_exp.h
+1
-1
sm_io_fmc130m_4ch_exports.c
src/sm_io/modules/fmc130m_4ch/sm_io_fmc130m_4ch_exports.c
+6
-3
sm_io_fmc130m_4ch_exports.h
src/sm_io/modules/fmc130m_4ch/sm_io_fmc130m_4ch_exports.h
+2
-2
sm_io_fmc130m_4ch_structs.c
src/sm_io/modules/fmc130m_4ch/sm_io_fmc130m_4ch_structs.c
+1
-1
sm_io_fmc130m_4ch_structs.h
src/sm_io/modules/fmc130m_4ch/sm_io_fmc130m_4ch_structs.h
+1
-1
modules.mk
src/sm_io/modules/modules.mk
+1
-2
sm_io_rffe_codes.h
src/sm_io/modules/rffe/sm_io_rffe_codes.h
+1
-1
sm_io_rffe_core.c
src/sm_io/modules/rffe/sm_io_rffe_core.c
+1
-1
sm_io_rffe_core.h
src/sm_io/modules/rffe/sm_io_rffe_core.h
+1
-1
sm_io_rffe_defaults.c
src/sm_io/modules/rffe/sm_io_rffe_defaults.c
+1
-1
sm_io_rffe_defaults.h
src/sm_io/modules/rffe/sm_io_rffe_defaults.h
+1
-1
sm_io_rffe_exp.c
src/sm_io/modules/rffe/sm_io_rffe_exp.c
+3
-1
sm_io_rffe_exp.h
src/sm_io/modules/rffe/sm_io_rffe_exp.h
+1
-1
sm_io_rffe_exports.c
src/sm_io/modules/rffe/sm_io_rffe_exports.c
+1
-1
sm_io_rffe_exports.h
src/sm_io/modules/rffe/sm_io_rffe_exports.h
+2
-2
sm_io_codes.c
src/sm_io/modules/sm_io_codes.c
+1
-1
sm_io_codes.h
src/sm_io/modules/sm_io_codes.h
+1
-1
sm_io_mod_dispatch.c
src/sm_io/modules/sm_io_mod_dispatch.c
+0
-59
sm_io_swap_codes.h
src/sm_io/modules/swap/sm_io_swap_codes.h
+1
-1
sm_io_swap_core.c
src/sm_io/modules/swap/sm_io_swap_core.c
+1
-1
sm_io_swap_core.h
src/sm_io/modules/swap/sm_io_swap_core.h
+1
-1
sm_io_swap_defaults.c
src/sm_io/modules/swap/sm_io_swap_defaults.c
+5
-1
sm_io_swap_defaults.h
src/sm_io/modules/swap/sm_io_swap_defaults.h
+1
-1
sm_io_swap_exp.c
src/sm_io/modules/swap/sm_io_swap_exp.c
+4
-2
sm_io_swap_exp.h
src/sm_io/modules/swap/sm_io_swap_exp.h
+1
-1
sm_io_swap_exports.c
src/sm_io/modules/swap/sm_io_swap_exports.c
+1
-1
sm_io_swap_exports.h
src/sm_io/modules/swap/sm_io_swap_exports.h
+2
-2
sm_io_swap_useful_macros.h
src/sm_io/modules/swap/sm_io_swap_useful_macros.h
+1
-1
sm_pr_bsmp.c
src/sm_io/protocols/ops/sm_pr_bsmp.c
+1
-1
sm_pr_bsmp_defaults.h
src/sm_io/protocols/ops/sm_pr_bsmp_defaults.h
+1
-1
sm_pr_i2c.c
src/sm_io/protocols/ops/sm_pr_i2c.c
+1
-1
sm_pr_i2c_defaults.h
src/sm_io/protocols/ops/sm_pr_i2c_defaults.h
+1
-1
sm_pr_spi.c
src/sm_io/protocols/ops/sm_pr_spi.c
+1
-1
sm_pr_spi_defaults.h
src/sm_io/protocols/ops/sm_pr_spi_defaults.h
+1
-1
sm_pr.c
src/sm_io/protocols/sm_pr.c
+1
-1
sm_pr_err.c
src/sm_io/protocols/sm_pr_err.c
+1
-1
rw_param.c
src/sm_io/rw_param/rw_param.c
+1
-1
sm_io.c
src/sm_io/sm_io.c
+2
-1
sm_io_bootstrap.c
src/sm_io/sm_io_bootstrap.c
+3
-1
sm_io_err.c
src/sm_io/sm_io_err.c
+1
-1
No files found.
.travis.yml
View file @
7a8e4912
...
...
@@ -5,37 +5,20 @@ compiler:
-
clang
-
gcc
sudo
:
false
env
:
-
BOARD=ml605 WITH_EXAMPLES=with_examples
-
BOARD=afcv3 WITH_EXAMPLES=with_examples
-
BOARD=ml605 EXAMPLES=with_examples LIBS_LINK=without_libs_link
-
BOARD=afcv3 EXAMPLES=with_examples LIBS_LINK=without_libs_link
addons
:
apt
:
packages
:
-
uuid-dev
before_install
:
-
git submodule update --init --recursive
# Build-check-install all subprojects
before_script
:
-
sudo apt-get install uuid-dev
# libsodium
-
git clone git://github.com/jedisct1/libsodium.git
-
( cd libsodium; ./autogen.sh; ./configure; make check; sudo make install; sudo ldconfig )
# libzmq
-
git clone git://github.com/zeromq/libzmq.git
-
( cd libzmq; ./autogen.sh; ./configure; make check; sudo make install; sudo ldconfig )
# CZMQ
-
git clone git://github.com/zeromq/czmq.git
-
( cd czmq; ./autogen.sh; ./configure; make check; sudo make install; sudo ldconfig )
# Zyre
-
git clone git://github.com/zeromq/zyre.git
-
( cd zyre; ./autogen.sh; ./configure; make check; sudo make install; sudo ldconfig )
# Malamute
-
git clone git://github.com/zeromq/malamute.git
-
( cd malamute; ./autogen.sh; ./configure; make check; sudo make install; sudo ldconfig )
# Build and check this project
script
:
-
./ci_build.sh
COPYING
View file @
7a8e4912
This diff is collapsed.
Click to expand it.
Makefile
View file @
7a8e4912
This diff is collapsed.
Click to expand it.
README.md
View file @
7a8e4912
...
...
@@ -9,9 +9,9 @@ Software for controlling the AFC BPM boards
Make sure you have the following libraries installed, either by download
the binaries or executing the instructions below:
*
zeromq-4.2.0 (http
://zeromq.org/area:download
)
*
czmq-3.0.
1 (http://czmq.zeromq.org/page:get-the-software
)
*
mlm-0.1.
0 (https://github.com/zeromq/malamute.git
)
*
zeromq-4.2.0 (http
s://github.com/lnls-dig/libzmq/tree/v4.2.0-pre
)
*
czmq-3.0.
2 (https://github.com/zeromq/czmq/tree/v3.0.2
)
*
mlm-0.1.
2 (https://github.com/lnls-dig/malamute/tree/v0.1.2
)
## Optional libraries:
...
...
cfg/crude_defconfig/bpm_sw.cfg
View file @
7a8e4912
...
...
@@ -9,60 +9,140 @@ dev_mngr
filename = dev_mngr.log
verbose = 1 # Ask for a trace
daemonize = no # Ask for daemonize process (options are: yes or no)
workdir = . # Working directory for daemon
spawn_broker = no # Ask to spawn broker (options are: yes or no)
# Device I/O configurations
dev_io
board
0
board
1
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board
1
board
2
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board
2
board
3
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board
3
board
4
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board
4
board
5
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board5
board6
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board7
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board8
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board9
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board10
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board11
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board12
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
cfg/lnls_defconfig/bpm_sw.cfg
View file @
7a8e4912
...
...
@@ -9,114 +9,140 @@ dev_mngr
filename = dev_mngr.log
verbose = 1 # Ask for a trace
daemonize = no # Ask for daemonize process (options are: yes or no)
workdir = . # Working directory for daemon
spawn_broker = no # Ask to spawn broker (options are: yes or no)
# Device I/O configurations
dev_io
board0
bpm0
dbe
afe
bind =
bpm1
dbe
afe
bind =
board1
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board2
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind = tcp://10.2.117.210:6791
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind = tcp://10.2.117.211:6791
board3
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind = tcp://10.2.117.208:6791
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind = tcp://10.2.117.209:6791
board4
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind = tcp://10.2.117.206:6791
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind = tcp://10.2.117.207:6791
board5
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board6
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board7
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind = tcp://10.2.117.204:6791
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind = tcp://10.2.117.205:6791
board8
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind = tcp://10.2.117.202:6791
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind = tcp://10.2.117.203:6791
board9
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind = tcp://10.2.117.200:6791
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind = tcp://10.2.117.201:6791
board10
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board11
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
board12
bpm0
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
bpm1
spawn_epics_ioc = yes # Ask to spawn EPICS IOC (Options are: yes or no)
dbe
afe
bind =
ci_build.sh
View file @
7a8e4912
#!/usr/bin/env bash
./compile.sh
$BOARD
$WITH_EXAMPLES
# help debug
set
-x
# Build and local install repositories
mkdir
tmp
BUILD_PREFIX
=
$PWD
/tmp
LIBSODIUM_VER
=
1.0.3
LIBZMQ_VER
=
v4.2.0-pre
LIBCZMQ_VER
=
v3.0.2
MALAMUTE_VER
=
v0.1.1
ZYRE_VER
=
v1.1.0
CONFIG_FLAGS
=()
CONFIG_FLAGS+
=(
"CFLAGS=-I
${
BUILD_PREFIX
}
/include"
)
CONFIG_FLAGS+
=(
"CPPFLAGS=-I
${
BUILD_PREFIX
}
/include"
)
CONFIG_FLAGS+
=(
"CXXFLAGS=-I
${
BUILD_PREFIX
}
/include"
)
CONFIG_FLAGS+
=(
"LDFLAGS=-L
${
BUILD_PREFIX
}
/lib"
)
KERNEL_FLAGS
=()
KERNEL_FLAGS+
=(
"INSTALLDIR=
${
BUILD_PREFIX
}
/lib/modules/
$(
shell
uname
-r
)
/extra"
)
KERNEL_FLAGS+
=(
"INSTALLHDRDIR=
${
BUILD_PREFIX
}
/include/pciDriver/driver"
)
BPM_OPTS
=()
BPM_OPTS+
=(
${
CONFIG_FLAGS
[@]
}
)
BPM_OPTS+
=(
${
KERNEL_FLAGS
[@]
}
)
BPM_OPTS+
=(
"PREFIX=
${
BUILD_PREFIX
}
"
)
CONFIG_OPTS
=()
CONFIG_OPTS+
=(
${
CONFIG_FLAGS
[@]
}
)
CONFIG_OPTS+
=(
"PKG_CONFIG_PATH=
${
BUILD_PREFIX
}
/lib/pkgconfig"
)
CONFIG_OPTS+
=(
"--prefix=
${
BUILD_PREFIX
}
"
)
# libsodium
git clone
--branch
=
${
LIBSODIUM_VER
}
git://github.com/jedisct1/libsodium.git
&&
(
cd
libsodium
;
./autogen.sh
&&
./configure
--prefix
=
$BUILD_PREFIX
&&
make check
&&
make
install
)
||
exit
1
# libzmq
git clone
--branch
=
${
LIBZMQ_VER
}
git://github.com/lnls-dig/libzmq.git
&&
(
cd
libzmq
;
./autogen.sh
&&
./configure
"
${
CONFIG_OPTS
[@]
}
"
&&
make check
&&
make
install
)
||
exit
1
# CZMQ
git clone
--branch
=
${
LIBCZMQ_VER
}
git://github.com/zeromq/czmq.git
&&
(
cd
czmq
;
./autogen.sh
&&
./configure
"
${
CONFIG_OPTS
[@]
}
"
&&
make check
&&
make
install
)
||
exit
1
# Zyre
git clone
--branch
=
${
ZYRE_VER
}
git://github.com/zeromq/zyre.git
&&
(
cd
zyre
;
./autogen.sh
&&
./configure
"
${
CONFIG_OPTS
[@]
}
"
&&
make check
&&
make
install
)
||
exit
1
# Malamute
git clone
--branch
=
${
MALAMUTE_VER
}
git://github.com/lnls-dig/malamute.git
&&
(
cd
malamute
;
./autogen.sh
&&
./configure
"
${
CONFIG_OPTS
[@]
}
"
&&
make check
&&
make
install
)
||
exit
1
./compile.sh
$BOARD
$EXAMPLES
$LIBS_LINK
"
${
BPM_OPTS
[@]
}
"
compile.sh
View file @
7a8e4912
...
...
@@ -2,6 +2,7 @@
VALID_BOARDS_STR
=
"Valid values are:
\"
ml605
\"
and
\"
afcv3
\"
."
VALID_WITH_EXAMPLES_STR
=
"Valid values are:
\"
with_examples
\"
or
\"
without_examples
\"
."
VALID_WITH_LIBS_LINK_STR
=
"Valid values are:
\"
with_libs_link
\"
or
\"
without_libs_link
\"
."
#######################################
# All of our Makefile options
...
...
@@ -27,6 +28,20 @@ if [ -n "$WITH_EXAMPLES" ] && [ "$WITH_EXAMPLES" != "with_examples" ] && [ "$WIT
exit
1
fi
WITH_LIBS_LINK
=
$3
if
[
-n
"
$WITH_LIBS_LINK
"
]
&&
[
"
$WITH_LIBS_LINK
"
!=
"with_libs_link"
]
&&
[
"
$WITH_LIBS_LINK
"
!=
"without_libs_link"
]
;
then
echo
"Wrong variable value. "
$VALID_WITH_LIBS_LINK_STR
exit
1
fi
EXTRA_FLAGS
=()
# Get all other arguments
for
item
in
"
${
@
:4
}
"
do
EXTRA_FLAGS+
=(
"
${
item
}
"
)
done
# Select if we want to have the AFCv3 DDR memory shrink to 2^28 or the full size 2^32. Options are: (y)es ot (n)o.
# This is a TEMPORARY fix until the AFCv3 FPGA firmware is fixed. If unsure, select (y)es.
SHRINK_AFCV3_DDR_SIZE
=
y
...
...
@@ -61,11 +76,23 @@ CFG=lnls_defconfig
export
CFG
COMMAND_DEPS
=
"
\
make deps &&
\
sudo make deps_install"
make
${
EXTRA_FLAGS
[@]
}
deps &&
\
make
${
EXTRA_FLAGS
[@]
}
deps_install"
COMMAND_LIBS
=
"
\
make
\
${
EXTRA_FLAGS
[@]
}
\
BOARD=
${
BOARD
}
\
ERRHAND_DBG=
${
ERRHAND_DBG
}
\
ERRHAND_MIN_LEVEL=
${
ERRHAND_MIN_LEVEL
}
\
ERRHAND_SUBSYS_ON='"
${
ERRHAND_SUBSYS_ON
}
"'
\
LOCAL_MSG_DBG=
${
LOCAL_MSG_DBG
}
\
libs_compile_install"
COMMAND_HAL
=
"
\
make BOARD=
${
BOARD
}
\
make
\
${
EXTRA_FLAGS
[@]
}
\
BOARD=
${
BOARD
}
\
SHRINK_AFCV3_DDR_SIZE=
${
SHRINK_AFCV3_DDR_SIZE
}
\
ERRHAND_DBG=
${
ERRHAND_DBG
}
\
ERRHAND_MIN_LEVEL=
${
ERRHAND_MIN_LEVEL
}
\
...
...
@@ -77,28 +104,27 @@ COMMAND_HAL="\
AFE_RFFE_TYPE=
${
AFE_RFFE_TYPE
}
\
WITH_DEVIO_CFG=
${
WITH_DEVIO_CFG
}
\
CFG_DIR=
${
CFG_DIR
}
&&
\
sudo make CFG=
${
CFG
}
install"
COMMAND_LIBBPMCLIENT
=
"
\
make BOARD=
${
BOARD
}
\
ERRHAND_DBG=
${
ERRHAND_DBG
}
\
ERRHAND_MIN_LEVEL=
${
ERRHAND_MIN_LEVEL
}
\
ERRHAND_SUBSYS_ON='"
${
ERRHAND_SUBSYS_ON
}
"'
\
LOCAL_MSG_DBG=
${
LOCAL_MSG_DBG
}
&&
\
sudo make libbpmclient_install"
make CFG=
${
CFG
}
${
EXTRA_FLAGS
[@]
}
install"
if
[
"
$WITH_EXAMPLES
"
=
"with_examples"
]
;
then
COMMAND_EXAMPLES
=
"
\
make examples"
make
${
EXTRA_FLAGS
[@]
}
examples"
else
COMMAND_EXAMPLES
=
""
fi
if
[
"
$WITH_LIBS_LINK
"
==
"with_libs_link"
]
||
[
"
$WITH_LIBS_LINK
"
==
""
]
;
then
COMMAND_LIBS_LINK
=
"ldconfig"
else
COMMAND_LIBS_LINK
=
""
fi
COMMAND_ARRAY
=(
"
${
COMMAND_DEPS
}
"
"
${
COMMAND_LIBS
}
"
"
${
COMMAND_HAL
}
"
"
${
COMMAND_LIBBPMCLIENT
}
"
"
${
COMMAND_EXAMPLES
}
"
"
${
COMMAND_LIBS_LINK
}
"
)
for
i
in
"
${
COMMAND_ARRAY
[@]
}
"
...
...
doc/img/bpm-sw-architecture.dia
0 → 100644
View file @
7a8e4912
File added
examples/Makefile
View file @
7a8e4912
...
...
@@ -11,8 +11,12 @@ OBJCOPY ?= $(CROSS_COMPILE)objcopy
SIZE
?=
$(CROSS_COMPILE)
size
MAKE
?=
make
# General C flags
CFLAGS
=
-std
=
gnu99
-O2
# General C/CPP flags
CFLAGS_USR
=
-std
=
gnu99
-O2
# We expect tghese variables to be appended to the possible
# command-line options
override
CPPFLAGS
+=
override
CXXFLAGS
+=
LOCAL_MSG_DBG
?=
n
DBE_DBG
?=
n
...
...
@@ -33,6 +37,15 @@ CFLAGS_DEBUG += -g
CFLAGS_PLATFORM
=
-Wall
-Wextra
-Werror
\
-Wno-missing-field-initializers
\
-Wno-missing-braces
ifeq
($(notdir
$(CC)),$(filter
$(notdir
$(CC)),gcc
cc))
CFLAGS_PLATFORM
+=
-Wno-cpp
endif
ifeq
($(notdir
$(CC)),clang)
CFLAGS_PLATFORM
+=
-Wno-error
=
\#
warnings
endif
LDFLAGS_PLATFORM
=
# Libraries
...
...
@@ -43,12 +56,10 @@ LFLAGS =
# Include directories
INCLUDE_DIRS
=
-I
.
-I
/usr/local/lib
# Merge all flags. Optimize for size (-Os)
CFLAGS
+=
$(CFLAGS_PLATFORM)
$(CFLAGS_DEBUG)
#-Os
LDFLAGS
=
$(LDFLAGS_PLATFORM)
#-ffunction-sections -fdata-sections -Wl,--gc-sections
# Merge all flags. We expect tghese variables to be appended to the possible
# command-line options
override
CFLAGS
+=
$(CFLAGS_USR)
$(CFLAGS_PLATFORM)
$(CFLAGS_DEBUG)
$(CPPFLAGS)
$(CXXFLAGS)
override
LDFLAGS
+=
$(LFLAGS)
$(LDFLAGS_PLATFORM)
# Every .c file will must be a separate example
examples_SRC
=
$
(
wildcard
*
.c
)
...
...
@@ -57,7 +68,7 @@ OUT = $(basename $(examples_SRC))
all
:
$(OUT)
%
:
%.c
$(CC)
$(LFLAGS)
$(CFLAGS)
$(INCLUDE_DIRS)
$^
-o
$@
$(LIBS)
$(CC)
$(L
D
FLAGS)
$(CFLAGS)
$(INCLUDE_DIRS)
$^
-o
$@
$(LIBS)
#BAD
clean
:
...
...
examples/acq.c
View file @
7a8e4912
...
...
@@ -19,6 +19,7 @@
#define DFLT_BOARD_NUMBER 0
#define MIN_NUM_SAMPLES 4
/* Arbitrary hard limits */
#define MAX_NUM_SAMPLES (1 << 28)
#define MAX_NUM_CHANS (1 << 8)
...
...
@@ -135,7 +136,12 @@ int main (int argc, char *argv [])
else
{
num_samples
=
strtoul
(
num_samples_str
,
NULL
,
10
);
if
(
num_samples
>
MAX_NUM_SAMPLES
)
{
if
(
num_samples
<
MIN_NUM_SAMPLES
)
{
fprintf
(
stderr
,
"[client:acq]: Number of samples too small! Defaulting to: %u
\n
"
,
MIN_NUM_SAMPLES
);
num_samples
=
MIN_NUM_SAMPLES
;
}
else
if
(
num_samples
>
MAX_NUM_SAMPLES
)
{
fprintf
(
stderr
,
"[client:acq]: Number of samples too big! Defaulting to: %u
\n
"
,
MAX_NUM_SAMPLES
);
num_samples
=
MAX_NUM_SAMPLES
;
...
...
@@ -197,11 +203,21 @@ int main (int argc, char *argv [])
goto
err_bpm_client_new
;
}
/* Set trigger to skip */
uint32_t
acq_trig
=
0
;
bpm_client_err_e
err
=
bpm_set_acq_trig
(
bpm_client
,
service
,
acq_trig
);
if
(
err
!=
BPM_CLIENT_SUCCESS
){
fprintf
(
stderr
,
"[client:acq]: bpm_acq_set_trig failed
\n
"
);
goto
err_bpm_set_acq_trig
;
}
uint32_t
data_size
=
num_samples
*
acq_chan
[
chan
].
sample_size
;
uint32_t
*
data
=
(
uint32_t
*
)
zmalloc
(
data_size
*
sizeof
(
uint8_t
));
bool
new_acq
=
true
;
acq_trans_t
acq_trans
=
{.
req
=
{
.
num_samples
=
num_samples
,
.
num_samples_pre
=
num_samples
,
.
num_samples_post
=
0
,
.
num_shots
=
1
,
.
chan
=
chan
,
},
.
block
=
{
...
...
@@ -209,7 +225,7 @@ int main (int argc, char *argv [])
.
data_size
=
data_size
,
}
};
bpm_client_err_e
err
=
bpm_get_curve
(
bpm_client
,
service
,
&
acq_trans
,
err
=
bpm_get_curve
(
bpm_client
,
service
,
&
acq_trans
,
50000
,
new_acq
);
if
(
err
!=
BPM_CLIENT_SUCCESS
){
fprintf
(
stderr
,
"[client:acq]: bpm_get_curve failed
\n
"
);
...
...
@@ -221,6 +237,7 @@ int main (int argc, char *argv [])