AM261x Motor Control SDK  10.02.00
hdsl_drv.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2021-2023 Texas Instruments Incorporated
3  *
4  * Redistribution and use in source and binary forms, with or without
5  * modification, are permitted provided that the following conditions
6  * are met:
7  *
8  * Redistributions of source code must retain the above copyright
9  * notice, this list of conditions and the following disclaimer.
10  *
11  * Redistributions in binary form must reproduce the above copyright
12  * notice, this list of conditions and the following disclaimer in the
13  * documentation and/or other materials provided with the
14  * distribution.
15  *
16  * Neither the name of Texas Instruments Incorporated nor the names of
17  * its contributors may be used to endorse or promote products derived
18  * from this software without specific prior written permission.
19  *
20  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
21  * "AS IS" AND ANY EXPS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
22  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
23  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
24  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
25  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
26  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31  */
32 
33 #ifndef HDSL_DRV_H_
34 #define HDSL_DRV_H_
35 
45 /* ========================================================================== */
46 /* Include Files */
47 /* ========================================================================== */
48 
49 #include <stdio.h>
50 #include <stdlib.h>
51 
52 #include <kernel/dpl/DebugP.h>
53 
54 #include <drivers/pruicss.h>
55 #include <drivers/hw_include/cslr_soc.h>
56 #include <drivers/hw_include/hw_types.h>
57 
58 #ifdef __cplusplus
59 extern "C" {
60 #endif
61 
62 /* ========================================================================== */
63 /* Macros & Typedefs */
64 /* ========================================================================== */
65 
66 
67 #define HDSL_MAX_CHANNELS (3U)
68 #define CHANNEL_0_ENABLED (1<<0)
69 #define CHANNEL_1_ENABLED (1<<1)
70 #define CHANNEL_2_ENABLED (1<<2)
71 
80 #define HDSL_LONG_MSG_ADDR_DIRECT (0U)
81 
82 #define HDSL_LONG_MSG_ADDR_INDIRECT (1U)
83 
93 #define HDSL_LONG_MSG_ADDR_WITHOUT_OFFSET (0U)
94 
95 #define HDSL_LONG_MSG_ADDR_WITH_OFFSET (1U)
96 
107 #define HDSL_LONG_MSG_LENGTH_0 (0U)
108 
109 #define HDSL_LONG_MSG_LENGTH_2 (1U)
110 
111 #define HDSL_LONG_MSG_LENGTH_4 (2U)
112 
113 #define HDSL_LONG_MSG_LENGTH_8 (3U)
114 
116 #define MAX_WAIT 20000
117 
118 /*TSR configuration:*/
119 
120 /*inEvent value:*/
121 /* ICSSG_0_EDC1_SYNC0 ICSSG0 IEP1 sync event 0 Pulse */
122 #define SYNCEVENT_INTRTR_IN_27 27
123 
124 /*outEvent values:*/
125 /*SYNC0_OUT Pin Selectable timesync event 24 Edge (4+(24*4)) */
126 #define SYNCEVT_RTR_SYNC28_EVT 0x64
127 /* SYNC1_OUT Pin Selectable timesync event 25 Edge (4+(25*4)) */
128 #define SYNCEVT_RTR_SYNC29_EVT 0x68
129 /* SYNC2_OUT Pin Selectable timesync event 26 Edge (4+(26*4)) */
130 #define SYNCEVT_RTR_SYNC30_EVT 0x6C
131 /* SYNC3_OUT Pin Selectable timesync event 27 Edge (4+(27*4)) */
132 #define SYNCEVT_RTR_SYNC31_EVT 0x70
133 /* ICSSG0_PR1_EDC1_LATCH0_IN PRU_ICSSG0 (4+(10*4)) */
134 #define SYNCEVT_RTR_SYNC10_EVT 0x2C
135 
136 enum {
153 };
154 
155 typedef struct HDSL_Config_s *HDSL_Handle;
156 
157 /* ========================================================================== */
158 /* Structure Declarations & Definitions */
159 /* ========================================================================== */
160 
166 typedef struct {
167  volatile uint8_t SYS_CTRL;
168  volatile uint8_t SYNC_CTRL;
169  volatile uint8_t resvd0;
170  volatile uint8_t MASTER_QM;
171  volatile uint8_t EVENT_H;
172  volatile uint8_t EVENT_L;
173  volatile uint8_t MASK_H;
174  volatile uint8_t MASK_L;
175  volatile uint8_t MASK_SUM;
176  volatile uint8_t EDGES;
177  volatile uint8_t DELAY;
178  volatile uint8_t VERSION;
179  volatile uint8_t resvd1;
180  volatile uint8_t ENC_ID2;
181  volatile uint8_t ENC_ID1;
182  volatile uint8_t ENC_ID0;
183  volatile uint8_t POS4;
184  volatile uint8_t POS3;
185  volatile uint8_t POS2;
186  volatile uint8_t POS1;
187  volatile uint8_t POS0;
188  volatile uint8_t VEL2;
189  volatile uint8_t VEL1;
190  volatile uint8_t VEL0;
191  volatile uint8_t resvd2;
192  volatile uint8_t VPOS4;
193  volatile uint8_t VPOS3;
194  volatile uint8_t VPOS2;
195  volatile uint8_t VPOS1;
196  volatile uint8_t VPOS0;
197  volatile uint8_t VPOSCRC_H;
198  volatile uint8_t VPOSCRC_L;
199  volatile uint8_t PC_BUFFER0;
200  volatile uint8_t PC_BUFFER1;
201  volatile uint8_t PC_BUFFER2;
202  volatile uint8_t PC_BUFFER3;
203  volatile uint8_t PC_BUFFER4;
204  volatile uint8_t PC_BUFFER5;
205  volatile uint8_t PC_BUFFER6;
206  volatile uint8_t PC_BUFFER7;
207  volatile uint8_t PC_ADD_H;
208  volatile uint8_t PC_ADD_L;
209  volatile uint8_t PC_OFF_H;
210  volatile uint8_t PC_OFF_L;
211  volatile uint8_t PC_CTRL;
212  volatile uint8_t PIPE_S;
213  volatile uint8_t PIPE_D;
214  volatile uint8_t PC_DATA;
215  volatile uint8_t resvd3;
216  volatile uint8_t resvd4;
217  volatile uint8_t resvd5;
218  volatile uint8_t resvd6;
219  volatile uint8_t resvd7;
220  volatile uint8_t SAFE_CTRL;
221  volatile uint8_t SAFE_SUM;
222  volatile uint8_t S_PC_DATA;
223  volatile uint8_t ACC_ERR_CNT;
224  volatile uint8_t resvd8;
225  volatile uint8_t resvd9;
226  volatile uint8_t resvd10;
227  volatile uint8_t resvd11;
228  volatile uint8_t EVENT_S;
229  volatile uint8_t MASK_S;
230  volatile uint8_t DUMMY;
231  volatile uint8_t SLAVE_REG_CTRL;
232  volatile uint8_t ACC_ERR_CNT_THRESH;
233  volatile uint8_t resvd12;
234  volatile uint8_t resvd13;
235  /*Safe 2 Interface */
236  volatile uint8_t VERSION2;
237  volatile uint8_t ENC2_ID;
238  volatile uint8_t STATUS2;
239  volatile uint8_t VPOS24;
240  volatile uint8_t VPOS23;
241  volatile uint8_t VPOS22;
242  volatile uint8_t VPOS21;
243  volatile uint8_t VPOS20;
244  volatile uint8_t VPOSCRC2_H;
245  volatile uint8_t VPOSCRC2_L;
246  volatile uint8_t POSTX;
247  volatile uint8_t resvd14;
248  /* Online Status*/
249  volatile uint8_t ONLINE_STATUS_D_H;
250  volatile uint8_t ONLINE_STATUS_D_L;
251  volatile uint8_t ONLINE_STATUS_1_H;
252  volatile uint8_t ONLINE_STATUS_1_L;
253  volatile uint8_t ONLINE_STATUS_2_H;
254  volatile uint8_t ONLINE_STATUS_2_L;
263 typedef struct HDSL_Config_s {
264  PRUICSS_Handle icssHandle;
266  uint32_t icssCore;
270  uint32_t *baseMemAddr; // icssHandle->hwAttrs->baseAddr + PRUICSS_DATARAM(PRUICSS_PRUx)
274  uint32_t multi_turn;
276  uint32_t res;
278  uint64_t mask;
281  // intc_initdata // ** - needs to be common for all channels and fixed (configure for all 3 channels in starting)
282 
283 } HDSL_Config;
292 typedef struct HDSL_CopyTable_s {
293  uint32_t reserved1;
294  uint32_t loadAddr1;
295  uint32_t runAddr1;
296  uint32_t size1;
297  uint32_t reserved2;
298  uint32_t loadAddr2;
299  uint32_t runAddr2;
300  uint32_t size2;
304 /* ========================================================================== */
305 /* Function Declarations */
306 /* ========================================================================== */
314 void hdsl_enable_load_share_mode(void *pruCfg ,uint32_t pruSlice);
315 
326 HDSL_Handle HDSL_open(PRUICSS_Handle icssHandle, uint32_t icssCore, uint8_t pruMode);
327 
328 
337 uint64_t HDSL_get_pos(HDSL_Handle hdslHandle, int position_id);
338 
345 uint8_t HDSL_get_qm(HDSL_Handle hdslHandle);
346 
354 uint16_t HDSL_get_events(HDSL_Handle hdslHandle);
355 
364 uint8_t HDSL_get_safe_events(HDSL_Handle hdslHandle);
365 
366 
376 
386 
396 
404 uint8_t HDSL_get_sum(HDSL_Handle hdslHandle);
405 
413 uint8_t HDSL_get_acc_err_cnt(HDSL_Handle hdslHandle);
414 
422 uint8_t HDSL_get_rssi(HDSL_Handle hdslHandle);
423 
437 int32_t HDSL_write_pc_short_msg(HDSL_Handle hdslHandle, uint8_t addr, uint8_t data, uint64_t timeout);
438 
452 int32_t HDSL_read_pc_short_msg(HDSL_Handle hdslHandle, uint8_t addr, uint8_t *data, uint64_t timeout);
453 
471 int32_t HDSL_write_pc_long_msg(HDSL_Handle hdslHandle, uint16_t addr, uint8_t offsetEnable, uint8_t addrType, uint8_t length, uint16_t offset, uint64_t timeout);
472 
489 int32_t HDSL_read_pc_long_msg(HDSL_Handle hdslHandle, uint16_t addr, uint8_t offsetEnable, uint8_t addrType, uint8_t length, uint16_t offset, uint64_t timeout);
490 
499 void HDSL_write_pc_buffer(HDSL_Handle hdslHandle, uint8_t buff_off, uint8_t data);
500 
509 uint8_t HDSL_read_pc_buffer(HDSL_Handle hdslHandle, uint8_t buff_off);
510 
519 uint8_t HDSL_get_sync_ctrl(HDSL_Handle hdslHandle);
520 
528 void HDSL_set_sync_ctrl(HDSL_Handle hdslHandle, uint8_t val);
529 
537 uint8_t HDSL_get_master_qm(HDSL_Handle hdslHandle);
538 
546 uint8_t HDSL_get_edges(HDSL_Handle hdslHandle);
547 
555 uint8_t HDSL_get_delay(HDSL_Handle hdslHandle);
556 
565 uint8_t HDSL_get_enc_id(HDSL_Handle hdslHandle, int byte);
566 
574 
582 void* HDSL_get_src_loc(HDSL_Handle hdslHandle);
583 
591 uint32_t HDSL_get_length(HDSL_Handle hdslHandle);
592 
602 int32_t HDSL_config_copy_table(HDSL_Handle hdslHandle, HDSL_CopyTable *copyTable);
603 
604 
614 int32_t HDSL_config_channel_mask(HDSL_Handle hdslHandle, uint8_t channelMask);
615 
616 #ifdef __cplusplus
617 }
618 #endif
619 
621 #endif
HDSL_Config
Definition: hdsl_drv.h:263
HDSL_Interface::POSTX
volatile uint8_t POSTX
Definition: hdsl_drv.h:246
HDSL_Interface::resvd3
volatile uint8_t resvd3
Definition: hdsl_drv.h:215
MENU_SAFE_POSITION
@ MENU_SAFE_POSITION
Definition: hdsl_drv.h:137
HDSL_Interface::VPOSCRC2_L
volatile uint8_t VPOSCRC2_L
Definition: hdsl_drv.h:245
HDSL_Interface::PC_OFF_H
volatile uint8_t PC_OFF_H
Definition: hdsl_drv.h:209
HDSL_Interface::VERSION
volatile uint8_t VERSION
Definition: hdsl_drv.h:178
HDSL_read_pc_long_msg
int32_t HDSL_read_pc_long_msg(HDSL_Handle hdslHandle, uint16_t addr, uint8_t offsetEnable, uint8_t addrType, uint8_t length, uint16_t offset, uint64_t timeout)
Trigger a long message read operation using parameters channel If this API returns SystemP_SUCCESS,...
HDSL_Interface::resvd2
volatile uint8_t resvd2
Definition: hdsl_drv.h:191
HDSL_Interface::ONLINE_STATUS_D_H
volatile uint8_t ONLINE_STATUS_D_H
Definition: hdsl_drv.h:249
HDSL_Interface::VPOS20
volatile uint8_t VPOS20
Definition: hdsl_drv.h:243
HDSL_CopyTable::reserved2
uint32_t reserved2
Definition: hdsl_drv.h:297
HDSL_Interface::VPOS23
volatile uint8_t VPOS23
Definition: hdsl_drv.h:240
HDSL_Config::baseMemAddr
uint32_t * baseMemAddr
Definition: hdsl_drv.h:270
MENU_DIRECT_READ_RID81_LENGTH8
@ MENU_DIRECT_READ_RID81_LENGTH8
Definition: hdsl_drv.h:146
HDSL_Interface::SAFE_CTRL
volatile uint8_t SAFE_CTRL
Definition: hdsl_drv.h:220
HDSL_Interface::EVENT_L
volatile uint8_t EVENT_L
Definition: hdsl_drv.h:172
HDSL_Interface::resvd14
volatile uint8_t resvd14
Definition: hdsl_drv.h:247
HDSL_Interface::resvd11
volatile uint8_t resvd11
Definition: hdsl_drv.h:227
HDSL_Config::icssCore
uint32_t icssCore
Definition: hdsl_drv.h:266
HDSL_Interface::resvd1
volatile uint8_t resvd1
Definition: hdsl_drv.h:179
HDSL_Interface::EDGES
volatile uint8_t EDGES
Definition: hdsl_drv.h:176
HDSL_write_pc_buffer
void HDSL_write_pc_buffer(HDSL_Handle hdslHandle, uint8_t buff_off, uint8_t data)
Write Parameters channel buffer for different bytes(bytes 0-7)
HDSL_Interface::PC_BUFFER5
volatile uint8_t PC_BUFFER5
Definition: hdsl_drv.h:204
HDSL_get_sync_ctrl
uint8_t HDSL_get_sync_ctrl(HDSL_Handle hdslHandle)
Returns Synchronization control value.
HDSL_Config::mask
uint64_t mask
Definition: hdsl_drv.h:278
HDSL_Interface::PC_ADD_H
volatile uint8_t PC_ADD_H
Definition: hdsl_drv.h:207
MENU_PC_SHORT_MSG_WRITE
@ MENU_PC_SHORT_MSG_WRITE
Definition: hdsl_drv.h:143
HDSL_Interface::ONLINE_STATUS_1_H
volatile uint8_t ONLINE_STATUS_1_H
Definition: hdsl_drv.h:251
HDSL_Interface::VPOS0
volatile uint8_t VPOS0
Definition: hdsl_drv.h:196
HDSL_Interface::resvd10
volatile uint8_t resvd10
Definition: hdsl_drv.h:226
HDSL_Interface
Definition: hdsl_drv.h:166
HDSL_Interface::VPOSCRC_H
volatile uint8_t VPOSCRC_H
Definition: hdsl_drv.h:197
HDSL_Interface::VPOS3
volatile uint8_t VPOS3
Definition: hdsl_drv.h:193
HDSL_Interface::resvd0
volatile uint8_t resvd0
Definition: hdsl_drv.h:169
MENU_DIRECT_READ_RID0_LENGTH4
@ MENU_DIRECT_READ_RID0_LENGTH4
Definition: hdsl_drv.h:145
HDSL_config_channel_mask
int32_t HDSL_config_channel_mask(HDSL_Handle hdslHandle, uint8_t channelMask)
Configure the channel mask.
HDSL_Config::res
uint32_t res
Definition: hdsl_drv.h:276
HDSL_CopyTable::loadAddr2
uint32_t loadAddr2
Definition: hdsl_drv.h:298
HDSL_get_acc_err_cnt
uint8_t HDSL_get_acc_err_cnt(HDSL_Handle hdslHandle)
Acceleration error counter.
HDSL_Interface::resvd6
volatile uint8_t resvd6
Definition: hdsl_drv.h:218
HDSL_set_sync_ctrl
void HDSL_set_sync_ctrl(HDSL_Handle hdslHandle, uint8_t val)
Writes Synchronization control value.
HDSL_Interface::ENC_ID2
volatile uint8_t ENC_ID2
Definition: hdsl_drv.h:180
HDSL_get_sum
uint8_t HDSL_get_sum(HDSL_Handle hdslHandle)
Getting Summarized slave status.
HDSL_Interface::ONLINE_STATUS_2_H
volatile uint8_t ONLINE_STATUS_2_H
Definition: hdsl_drv.h:253
HDSL_Interface::POS0
volatile uint8_t POS0
Definition: hdsl_drv.h:187
HDSL_Interface::PC_DATA
volatile uint8_t PC_DATA
Definition: hdsl_drv.h:214
HDSL_Interface::S_PC_DATA
volatile uint8_t S_PC_DATA
Definition: hdsl_drv.h:222
HDSL_Interface::MASTER_QM
volatile uint8_t MASTER_QM
Definition: hdsl_drv.h:170
HDSL_Interface::SAFE_SUM
volatile uint8_t SAFE_SUM
Definition: hdsl_drv.h:221
HDSL_Interface::EVENT_H
volatile uint8_t EVENT_H
Definition: hdsl_drv.h:171
HDSL_get_src_loc
void * HDSL_get_src_loc(HDSL_Handle hdslHandle)
Get memory location for HDSL interface struct.
HDSL_Interface::ONLINE_STATUS_1_L
volatile uint8_t ONLINE_STATUS_1_L
Definition: hdsl_drv.h:252
MENU_HDSL_REG_INTO_MEMORY
@ MENU_HDSL_REG_INTO_MEMORY
Definition: hdsl_drv.h:150
HDSL_Interface::resvd5
volatile uint8_t resvd5
Definition: hdsl_drv.h:217
HDSL_Interface::PIPE_S
volatile uint8_t PIPE_S
Definition: hdsl_drv.h:212
MENU_EVENTS
@ MENU_EVENTS
Definition: hdsl_drv.h:139
HDSL_Interface::resvd4
volatile uint8_t resvd4
Definition: hdsl_drv.h:216
HDSL_Interface::ACC_ERR_CNT
volatile uint8_t ACC_ERR_CNT
Definition: hdsl_drv.h:223
HDSL_get_edges
uint8_t HDSL_get_edges(HDSL_Handle hdslHandle)
Returns Cable bit sampling time control.
HDSL_Interface::PC_OFF_L
volatile uint8_t PC_OFF_L
Definition: hdsl_drv.h:210
HDSL_Config::multi_turn
uint32_t multi_turn
Definition: hdsl_drv.h:274
HDSL_Interface::VPOS1
volatile uint8_t VPOS1
Definition: hdsl_drv.h:195
HDSL_Interface::SLAVE_REG_CTRL
volatile uint8_t SLAVE_REG_CTRL
Definition: hdsl_drv.h:231
HDSL_Config::icssHandle
PRUICSS_Handle icssHandle
Definition: hdsl_drv.h:264
MENU_INVALID
@ MENU_INVALID
Definition: hdsl_drv.h:152
HDSL_get_pos
uint64_t HDSL_get_pos(HDSL_Handle hdslHandle, int position_id)
Calculate fast position,safe position1,safe position2.
HDSL_Interface::PC_BUFFER2
volatile uint8_t PC_BUFFER2
Definition: hdsl_drv.h:201
HDSL_Interface::VPOS24
volatile uint8_t VPOS24
Definition: hdsl_drv.h:239
HDSL_Interface::VPOSCRC_L
volatile uint8_t VPOSCRC_L
Definition: hdsl_drv.h:198
HDSL_Interface::MASK_H
volatile uint8_t MASK_H
Definition: hdsl_drv.h:173
HDSL_Interface::MASK_S
volatile uint8_t MASK_S
Definition: hdsl_drv.h:229
HDSL_Interface::resvd7
volatile uint8_t resvd7
Definition: hdsl_drv.h:219
HDSL_get_enc_id
uint8_t HDSL_get_enc_id(HDSL_Handle hdslHandle, int byte)
Read encoder id bytes(byte no. 0-2)
HDSL_Interface::PC_BUFFER1
volatile uint8_t PC_BUFFER1
Definition: hdsl_drv.h:200
MENU_INDIRECT_WRITE_RID0_LENGTH8
@ MENU_INDIRECT_WRITE_RID0_LENGTH8
Definition: hdsl_drv.h:149
HDSL_Interface::PC_BUFFER6
volatile uint8_t PC_BUFFER6
Definition: hdsl_drv.h:205
HDSL_Interface::PC_BUFFER0
volatile uint8_t PC_BUFFER0
Definition: hdsl_drv.h:199
HDSL_get_rssi
uint8_t HDSL_get_rssi(HDSL_Handle hdslHandle)
Read RSSI value.
HDSL_Interface::resvd13
volatile uint8_t resvd13
Definition: hdsl_drv.h:234
HDSL_Interface::ENC_ID0
volatile uint8_t ENC_ID0
Definition: hdsl_drv.h:182
HDSL_Interface::PIPE_D
volatile uint8_t PIPE_D
Definition: hdsl_drv.h:213
HDSL_open
HDSL_Handle HDSL_open(PRUICSS_Handle icssHandle, uint32_t icssCore, uint8_t pruMode)
Open HDSL handle for the specified core (interrupt mapping should already be completed)
HDSL_Interface::ONLINE_STATUS_D_L
volatile uint8_t ONLINE_STATUS_D_L
Definition: hdsl_drv.h:250
HDSL_config_copy_table
int32_t HDSL_config_copy_table(HDSL_Handle hdslHandle, HDSL_CopyTable *copyTable)
Configure the copy table entries for two overlayed firmware parts for channel 2.
HDSL_Handle
struct HDSL_Config_s * HDSL_Handle
Definition: hdsl_drv.h:155
MENU_INDIRECT_WRITE_RID0_LENGTH8_OFFSET0
@ MENU_INDIRECT_WRITE_RID0_LENGTH8_OFFSET0
Definition: hdsl_drv.h:148
HDSL_Interface::resvd9
volatile uint8_t resvd9
Definition: hdsl_drv.h:225
HDSL_get_qm
uint8_t HDSL_get_qm(HDSL_Handle hdslHandle)
Getting quality monitoring value.
HDSL_Interface::VERSION2
volatile uint8_t VERSION2
Definition: hdsl_drv.h:236
HDSL_get_length
uint32_t HDSL_get_length(HDSL_Handle hdslHandle)
Get size of memory used by HDSL interface struct.
HDSL_CopyTable::size1
uint32_t size1
Definition: hdsl_drv.h:296
HDSL_write_pc_long_msg
int32_t HDSL_write_pc_long_msg(HDSL_Handle hdslHandle, uint16_t addr, uint8_t offsetEnable, uint8_t addrType, uint8_t length, uint16_t offset, uint64_t timeout)
Trigger a long message write operation using parameters channel. Call HDSL_write_pc_buffer before thi...
HDSL_Interface::MASK_SUM
volatile uint8_t MASK_SUM
Definition: hdsl_drv.h:175
HDSL_get_online_status_d
uint16_t HDSL_get_online_status_d(HDSL_Handle hdslHandle)
Taking values of Online Status D (ONLINE_STATUS_D) register.
HDSL_Interface::EVENT_S
volatile uint8_t EVENT_S
Definition: hdsl_drv.h:228
HDSL_Interface::DELAY
volatile uint8_t DELAY
Definition: hdsl_drv.h:177
HDSL_Interface::ENC_ID1
volatile uint8_t ENC_ID1
Definition: hdsl_drv.h:181
HDSL_Interface::VPOS2
volatile uint8_t VPOS2
Definition: hdsl_drv.h:194
HDSL_Interface::PC_ADD_L
volatile uint8_t PC_ADD_L
Definition: hdsl_drv.h:208
HDSL_Interface::ACC_ERR_CNT_THRESH
volatile uint8_t ACC_ERR_CNT_THRESH
Definition: hdsl_drv.h:232
HDSL_CopyTable::loadAddr1
uint32_t loadAddr1
Definition: hdsl_drv.h:294
HDSL_get_online_status_1
uint16_t HDSL_get_online_status_1(HDSL_Handle hdslHandle)
Taking values of Online Status D (ONLINE_STATUS_D) register.
HDSL_Interface::POS3
volatile uint8_t POS3
Definition: hdsl_drv.h:184
HDSL_Interface::PC_BUFFER4
volatile uint8_t PC_BUFFER4
Definition: hdsl_drv.h:203
HDSL_Interface::resvd8
volatile uint8_t resvd8
Definition: hdsl_drv.h:224
HDSL_read_pc_buffer
uint8_t HDSL_read_pc_buffer(HDSL_Handle hdslHandle, uint8_t buff_off)
Returns Parameters channel buffer for different bytes(bytes 0-7)
HDSL_get_safe_events
uint8_t HDSL_get_safe_events(HDSL_Handle hdslHandle)
Taking values of Safe Event (EVENT_S) register.
HDSL_CopyTable::runAddr1
uint32_t runAddr1
Definition: hdsl_drv.h:295
HDSL_get_online_status_2
uint16_t HDSL_get_online_status_2(HDSL_Handle hdslHandle)
Taking values of Online Status D (ONLINE_STATUS_D) register.
HDSL_Interface::VPOS4
volatile uint8_t VPOS4
Definition: hdsl_drv.h:192
HDSL_Interface::VEL1
volatile uint8_t VEL1
Definition: hdsl_drv.h:189
HDSL_Interface::resvd12
volatile uint8_t resvd12
Definition: hdsl_drv.h:233
HDSL_Interface::ONLINE_STATUS_2_L
volatile uint8_t ONLINE_STATUS_2_L
Definition: hdsl_drv.h:254
HDSL_read_pc_short_msg
int32_t HDSL_read_pc_short_msg(HDSL_Handle hdslHandle, uint8_t addr, uint8_t *data, uint64_t timeout)
Trigger a short message read operation using parameters channel. After the required registers are wri...
HDSL_CopyTable::runAddr2
uint32_t runAddr2
Definition: hdsl_drv.h:299
MENU_SUMMARY
@ MENU_SUMMARY
Definition: hdsl_drv.h:140
HDSL_CopyTable
Definition: hdsl_drv.h:292
hdsl_enable_load_share_mode
void hdsl_enable_load_share_mode(void *pruCfg, uint32_t pruSlice)
enable load share mode for multi-channel HDSL
HDSL_get_delay
uint8_t HDSL_get_delay(HDSL_Handle hdslHandle)
Returns Run time delay of system cable and signal strength.
HDSL_Config::hdslInterface
HDSL_Interface * hdslInterface
Definition: hdsl_drv.h:272
MENU_LIMIT
@ MENU_LIMIT
Definition: hdsl_drv.h:151
MENU_DIRECT_READ_RID81_LENGTH2
@ MENU_DIRECT_READ_RID81_LENGTH2
Definition: hdsl_drv.h:147
HDSL_Interface::SYS_CTRL
volatile uint8_t SYS_CTRL
Definition: hdsl_drv.h:167
HDSL_Interface::POS2
volatile uint8_t POS2
Definition: hdsl_drv.h:185
MENU_RSSI
@ MENU_RSSI
Definition: hdsl_drv.h:142
HDSL_Interface::PC_CTRL
volatile uint8_t PC_CTRL
Definition: hdsl_drv.h:211
HDSL_Interface::POS4
volatile uint8_t POS4
Definition: hdsl_drv.h:183
HDSL_Interface::PC_BUFFER7
volatile uint8_t PC_BUFFER7
Definition: hdsl_drv.h:206
HDSL_Interface::POS1
volatile uint8_t POS1
Definition: hdsl_drv.h:186
HDSL_Interface::VPOS21
volatile uint8_t VPOS21
Definition: hdsl_drv.h:242
HDSL_generate_memory_image
void HDSL_generate_memory_image(HDSL_Handle hdslHandle)
Generates memory image.
HDSL_Interface::SYNC_CTRL
volatile uint8_t SYNC_CTRL
Definition: hdsl_drv.h:168
HDSL_Interface::ENC2_ID
volatile uint8_t ENC2_ID
Definition: hdsl_drv.h:237
HDSL_get_events
uint16_t HDSL_get_events(HDSL_Handle hdslHandle)
Taking values of High bytes event (EVENT_H) and Low bytes event(EVENT_L)
MENU_QUALITY_MONITORING
@ MENU_QUALITY_MONITORING
Definition: hdsl_drv.h:138
HDSL_Interface::PC_BUFFER3
volatile uint8_t PC_BUFFER3
Definition: hdsl_drv.h:202
MENU_ACC_ERR_CNT
@ MENU_ACC_ERR_CNT
Definition: hdsl_drv.h:141
HDSL_Interface::VEL0
volatile uint8_t VEL0
Definition: hdsl_drv.h:190
HDSL_CopyTable::reserved1
uint32_t reserved1
Definition: hdsl_drv.h:293
HDSL_Interface::MASK_L
volatile uint8_t MASK_L
Definition: hdsl_drv.h:174
MENU_PC_SHORT_MSG_READ
@ MENU_PC_SHORT_MSG_READ
Definition: hdsl_drv.h:144
HDSL_Interface::DUMMY
volatile uint8_t DUMMY
Definition: hdsl_drv.h:230
HDSL_CopyTable::size2
uint32_t size2
Definition: hdsl_drv.h:300
HDSL_Interface::VPOSCRC2_H
volatile uint8_t VPOSCRC2_H
Definition: hdsl_drv.h:244
HDSL_write_pc_short_msg
int32_t HDSL_write_pc_short_msg(HDSL_Handle hdslHandle, uint8_t addr, uint8_t data, uint64_t timeout)
Trigger a short message write operation using parameters channel After the required registers are wri...
HDSL_Interface::STATUS2
volatile uint8_t STATUS2
Definition: hdsl_drv.h:238
HDSL_Interface::VPOS22
volatile uint8_t VPOS22
Definition: hdsl_drv.h:241
HDSL_get_master_qm
uint8_t HDSL_get_master_qm(HDSL_Handle hdslHandle)
Returns Quality monitoring value.
HDSL_Interface::VEL2
volatile uint8_t VEL2
Definition: hdsl_drv.h:188