Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
P
PPSi
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
50
Issues
50
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
PPSi
Commits
d74fda13
Commit
d74fda13
authored
Apr 09, 2019
by
baujc
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update wrs_dump_shmem to report all changes made in PPSi
parent
84fc8c10
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
31 additions
and
33 deletions
+31
-33
wrs_dump_shmem_ppsi.c
tools/wrs_dump_shmem_ppsi.c
+31
-33
No files found.
tools/wrs_dump_shmem_ppsi.c
View file @
d74fda13
...
@@ -103,10 +103,10 @@ struct dump_info servo_state_info [] = {
...
@@ -103,10 +103,10 @@ struct dump_info servo_state_info [] = {
DUMP_FIELD
(
int
,
servo_locked
),
DUMP_FIELD
(
int
,
servo_locked
),
};
};
#if CONFIG_HAS_EXT_L1SYNC
#if CONFIG_HAS_EXT_L1SYNC
|| CONFIG_HAS_EXT_WR
#undef DUMP_STRUCT
#undef DUMP_STRUCT
#define DUMP_STRUCT
struct l1e_servo_state
#define DUMP_STRUCT
wrh_servo_t
struct
dump_info
l1e_servo_state
_info
[]
=
{
struct
dump_info
wrh_servo
_info
[]
=
{
DUMP_FIELD
(
Integer32
,
clock_period_ps
),
DUMP_FIELD
(
Integer32
,
clock_period_ps
),
DUMP_FIELD
(
Integer64
,
delayMM_ps
),
DUMP_FIELD
(
Integer64
,
delayMM_ps
),
DUMP_FIELD
(
Integer32
,
cur_setpoint_ps
),
DUMP_FIELD
(
Integer32
,
cur_setpoint_ps
),
...
@@ -121,6 +121,9 @@ struct dump_info l1e_servo_state_info [] = {
...
@@ -121,6 +121,9 @@ struct dump_info l1e_servo_state_info [] = {
DUMP_FIELD
(
int
,
missed_iters
),
DUMP_FIELD
(
int
,
missed_iters
),
};
};
#endif
#if CONFIG_HAS_EXT_L1SYNC
#undef DUMP_STRUCT
#undef DUMP_STRUCT
#define DUMP_STRUCT l1e_ext_portDS_t
#define DUMP_STRUCT l1e_ext_portDS_t
struct
dump_info
l1e_ext_portDS_info
[]
=
{
struct
dump_info
l1e_ext_portDS_info
[]
=
{
...
@@ -168,32 +171,12 @@ struct dump_info l1e_local_portDS_info [] = {
...
@@ -168,32 +171,12 @@ struct dump_info l1e_local_portDS_info [] = {
#if CONFIG_HAS_EXT_WR == 1
#if CONFIG_HAS_EXT_WR == 1
#undef DUMP_STRUCT
#undef DUMP_STRUCT
#define DUMP_STRUCT struct wr_servo_state
#define DUMP_STRUCT wr_servo_ext_t
struct
dump_info
wr_servo_state_info
[]
=
{
struct
dump_info
wr_servo_ext_info
[]
=
{
DUMP_FIELD
(
Integer32
,
delta_txm_ps
),
DUMP_FIELD
(
time
,
delta_txm
),
DUMP_FIELD
(
Integer32
,
delta_rxm_ps
),
DUMP_FIELD
(
time
,
delta_rxm
),
DUMP_FIELD
(
Integer32
,
delta_txs_ps
),
DUMP_FIELD
(
time
,
delta_txs
),
DUMP_FIELD
(
Integer32
,
delta_rxs_ps
),
DUMP_FIELD
(
time
,
delta_rxs
),
DUMP_FIELD
(
Integer32
,
fiber_fix_alpha
),
DUMP_FIELD
(
Integer32
,
clock_period_ps
),
DUMP_FIELD
(
time
,
delayMM
),
DUMP_FIELD
(
Integer64
,
delayMM_ps
),
DUMP_FIELD
(
Integer32
,
cur_setpoint
),
DUMP_FIELD
(
Integer64
,
delayMS_ps
),
DUMP_FIELD
(
int
,
tracking_enabled
),
DUMP_FIELD
(
Integer64
,
skew
),
DUMP_FIELD
(
UInteger32
,
n_err_state
),
DUMP_FIELD
(
UInteger32
,
n_err_offset
),
DUMP_FIELD
(
UInteger32
,
n_err_delta_rtt
),
DUMP_FIELD
(
time
,
update_time
),
DUMP_FIELD
(
time
,
t1
),
DUMP_FIELD
(
time
,
t2
),
DUMP_FIELD
(
time
,
t3
),
DUMP_FIELD
(
time
,
t4
),
DUMP_FIELD
(
time
,
t5
),
DUMP_FIELD
(
time
,
t6
),
DUMP_FIELD
(
Integer64
,
prev_delayMS_ps
),
DUMP_FIELD
(
int
,
missed_iters
),
};
};
#endif
#endif
...
@@ -307,16 +290,22 @@ struct dump_info ppi_info [] = {
...
@@ -307,16 +290,22 @@ struct dump_info ppi_info [] = {
DUMP_FIELD
(
unsigned_long
,
ptp_rx_count
),
DUMP_FIELD
(
unsigned_long
,
ptp_rx_count
),
};
};
#if CONFIG_HAS_EXT_WR == 1
#undef DUMP_STRUCT
#undef DUMP_STRUCT
#define DUMP_STRUCT struct wr_dsport
#define DUMP_STRUCT struct wr_dsport
struct
dump_info
wr_dsport_info
[]
=
{
struct
dump_info
wr_ext_portDS_info
[]
=
{
DUMP_FIELD
(
int
,
state
),
DUMP_FIELD
(
Boolean
,
wrModeOn
),
DUMP_FIELD
(
Boolean
,
parentWrModeOn
),
DUMP_FIELD
(
scaledPicoseconds
,
deltaTx
),
DUMP_FIELD
(
scaledPicoseconds
,
deltaRx
),
DUMP_FIELD
(
UInteger16
,
otherNodeCalSendPattern
),
DUMP_FIELD
(
UInteger16
,
otherNodeCalSendPattern
),
DUMP_FIELD
(
UInteger8
,
otherNodeCalRetry
),
DUMP_FIELD
(
UInteger8
,
otherNodeCalRetry
),
DUMP_FIELD
(
UInteger32
,
otherNodeCalPeriod
),
DUMP_FIELD
(
UInteger32
,
otherNodeCalPeriod
),
DUMP_FIELD
(
scaledPicoseconds
,
otherNodeDeltaTx
),
DUMP_FIELD
(
scaledPicoseconds
,
otherNodeDeltaTx
),
DUMP_FIELD
(
scaledPicoseconds
,
otherNodeDeltaRx
),
DUMP_FIELD
(
scaledPicoseconds
,
otherNodeDeltaRx
),
};
};
#endif
int
dump_ppsi_mem
(
struct
wrs_shm_head
*
head
)
int
dump_ppsi_mem
(
struct
wrs_shm_head
*
head
)
{
{
...
@@ -369,7 +358,8 @@ int dump_ppsi_mem(struct wrs_shm_head *head)
...
@@ -369,7 +358,8 @@ int dump_ppsi_mem(struct wrs_shm_head *head)
struct
wr_data
*
data
;
struct
wr_data
*
data
;
data
=
wrs_shm_follow
(
head
,
ppi
->
ext_data
);
data
=
wrs_shm_follow
(
head
,
ppi
->
ext_data
);
sprintf
(
prefix
,
"ppsi.inst.%d.servo.wr"
,
i
);
sprintf
(
prefix
,
"ppsi.inst.%d.servo.wr"
,
i
);
dump_many_fields
(
&
data
->
servo_state
,
wr_servo_state_info
,
ARRAY_SIZE
(
wr_servo_state_info
),
prefix
);
dump_many_fields
(
&
data
->
servo
,
wrh_servo_info
,
ARRAY_SIZE
(
wrh_servo_info
),
prefix
);
dump_many_fields
(
&
data
->
servo
,
wr_servo_ext_info
,
ARRAY_SIZE
(
wr_servo_ext_info
),
prefix
);
}
}
#endif
#endif
#if CONFIG_HAS_EXT_L1SYNC == 1
#if CONFIG_HAS_EXT_L1SYNC == 1
...
@@ -377,7 +367,7 @@ int dump_ppsi_mem(struct wrs_shm_head *head)
...
@@ -377,7 +367,7 @@ int dump_ppsi_mem(struct wrs_shm_head *head)
struct
l1e_data
*
data
;
struct
l1e_data
*
data
;
data
=
wrs_shm_follow
(
head
,
ppi
->
ext_data
);
data
=
wrs_shm_follow
(
head
,
ppi
->
ext_data
);
sprintf
(
prefix
,
"ppsi.inst.%d.servo.l1sync"
,
i
);
sprintf
(
prefix
,
"ppsi.inst.%d.servo.l1sync"
,
i
);
dump_many_fields
(
&
data
->
servo
_state
,
l1e_servo_state_info
,
ARRAY_SIZE
(
l1e_servo_state
_info
),
prefix
);
dump_many_fields
(
&
data
->
servo
,
wrh_servo_info
,
ARRAY_SIZE
(
wrh_servo
_info
),
prefix
);
}
}
#endif
#endif
}
}
...
@@ -397,6 +387,14 @@ int dump_ppsi_mem(struct wrs_shm_head *head)
...
@@ -397,6 +387,14 @@ int dump_ppsi_mem(struct wrs_shm_head *head)
}
else
{
}
else
{
dump_many_fields
(
&
l1eLocalPortDS
,
l1e_local_portDS_info
,
ARRAY_SIZE
(
l1e_local_portDS_info
),
prefix
);
dump_many_fields
(
&
l1eLocalPortDS
,
l1e_local_portDS_info
,
ARRAY_SIZE
(
l1e_local_portDS_info
),
prefix
);
}
}
#endif
#if CONFIG_HAS_EXT_WR
if
(
ppi
->
protocol_extension
==
PPSI_EXT_WR
)
{
sprintf
(
prefix
,
"ppsi.inst.%d.wr"
,
i
);
portDS_t
*
portDS
=
wrs_shm_follow
(
head
,
ppi
->
portDS
);
struct
wr_dsport
*
data
=
wrs_shm_follow
(
head
,
portDS
->
ext_dsport
);
dump_many_fields
(
data
,
wr_ext_portDS_info
,
ARRAY_SIZE
(
wr_ext_portDS_info
),
prefix
);
}
#endif
#endif
}
}
return
0
;
/* this is complete */
return
0
;
/* this is complete */
...
...
Write
Preview
Markdown
is supported
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