Commit 923d0aca authored by Lucas Russo's avatar Lucas Russo

sm_io/modules/acq/*: add new data-driven trigger channel operation

parent 03496289
......@@ -41,7 +41,9 @@ struct _smio_acq_data_block_t {
#define ACQ_NAME_SW_TRIG "acq_sw_trig"
#define ACQ_OPCODE_FSM_STOP 10
#define ACQ_NAME_FSM_STOP "acq_fsm_stop"
#define ACQ_OPCODE_END 11
#define ACQ_OPCODE_HW_DATA_TRIG_CHAN 11
#define ACQ_NAME_HW_DATA_TRIG_CHAN "acq_hw_data_trig_chan"
#define ACQ_OPCODE_END 12
/* Messaging Reply OPCODES */
#define ACQ_REPLY_TYPE uint32_t
......
......@@ -721,6 +721,14 @@ RW_PARAM_FUNC(acq, fsm_stop) {
ACQ_FSM_STOP_MAX, NO_CHK_FUNC, NO_FMT_FUNC, SET_FIELD);
}
#define ACQ_DATA_DRIVEN_CHAN_MIN 0
#define ACQ_DATA_DRIVEN_CHAN_MAX (SMIO_ACQ_NUM_CHANNELS-1)
RW_PARAM_FUNC(acq, hw_data_trig_chan) {
SET_GET_PARAM(acq, WB_ACQ_CORE_CTRL_REGS_OFFS, ACQ_CORE, ACQ_CHAN_CTL,
DTRIG_WHICH, MULT_BIT_PARAM, ACQ_DATA_DRIVEN_CHAN_MIN,
ACQ_DATA_DRIVEN_CHAN_MAX, NO_CHK_FUNC, NO_FMT_FUNC, SET_FIELD);
}
/* Exported function pointers */
const disp_table_func_fp acq_exp_fp [] = {
_acq_data_acquire,
......@@ -734,6 +742,7 @@ const disp_table_func_fp acq_exp_fp [] = {
RW_PARAM_FUNC_NAME(acq, hw_trig_dly),
RW_PARAM_FUNC_NAME(acq, sw_trig),
RW_PARAM_FUNC_NAME(acq, fsm_stop),
RW_PARAM_FUNC_NAME(acq, hw_data_trig_chan),
NULL
};
......
......@@ -142,6 +142,18 @@ disp_op_t acq_fsm_stop_exp = {
}
};
disp_op_t acq_hw_data_trig_chan_exp = {
.name = ACQ_NAME_HW_DATA_TRIG_CHAN,
.opcode = ACQ_OPCODE_HW_DATA_TRIG_CHAN,
.retval = DISP_ARG_ENCODE(DISP_ATYPE_UINT32, uint32_t),
.retval_owner = DISP_OWNER_OTHER,
.args = {
DISP_ARG_ENCODE(DISP_ATYPE_UINT32, uint32_t),
DISP_ARG_ENCODE(DISP_ATYPE_UINT32, uint32_t),
DISP_ARG_END
}
};
/* Exported function description */
const disp_op_t *acq_exp_ops [] = {
&acq_data_acquire_exp,
......@@ -155,6 +167,7 @@ const disp_op_t *acq_exp_ops [] = {
&acq_hw_trig_dly_exp,
&acq_sw_trig_exp,
&acq_fsm_stop_exp,
&acq_hw_data_trig_chan_exp,
NULL
};
......@@ -21,6 +21,7 @@ extern disp_op_t acq_hw_data_trig_thres_exp;
extern disp_op_t acq_hw_trig_dly_exp;
extern disp_op_t acq_sw_trig_exp;
extern disp_op_t acq_fsm_stop_exp;
extern disp_op_t acq_hw_data_trig_chan_exp;
extern const disp_op_t *acq_exp_ops [];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment