Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
proview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Esteban Blanc
proview
Commits
8a04a63c
Commit
8a04a63c
authored
Jul 15, 2020
by
Claes
Committed by
Esteban Blanc
Dec 23, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pwrtest01 modifications
parent
bde48ec8
Changes
18
Hide whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
167 additions
and
527 deletions
+167
-527
project/pwrtest01/build_from_git.sh
project/pwrtest01/build_from_git.sh
+26
-9
project/pwrtest01/src/appl/ra_aproctest.cpp
project/pwrtest01/src/appl/ra_aproctest.cpp
+1
-1
project/pwrtest01/src/appl/ra_ccmtest.rtt_com
project/pwrtest01/src/appl/ra_ccmtest.rtt_com
+1
-1
project/pwrtest01/src/appl/ra_cdhtest.cpp
project/pwrtest01/src/appl/ra_cdhtest.cpp
+1
-1
project/pwrtest01/src/appl/ra_errhtest.cpp
project/pwrtest01/src/appl/ra_errhtest.cpp
+1
-1
project/pwrtest01/src/appl/ra_gdhtest.cpp
project/pwrtest01/src/appl/ra_gdhtest.cpp
+124
-502
project/pwrtest01/src/appl/ra_mhappltest.cpp
project/pwrtest01/src/appl/ra_mhappltest.cpp
+1
-1
project/pwrtest01/src/appl/ra_mhtest.cpp
project/pwrtest01/src/appl/ra_mhtest.cpp
+1
-1
project/pwrtest01/src/appl/ra_nettimetest.cpp
project/pwrtest01/src/appl/ra_nettimetest.cpp
+1
-1
project/pwrtest01/src/appl/ra_plctest.cpp
project/pwrtest01/src/appl/ra_plctest.cpp
+1
-1
project/pwrtest01/src/appl/ra_pwrrttest.py
project/pwrtest01/src/appl/ra_pwrrttest.py
+1
-1
project/pwrtest01/src/appl/ra_qcomtest.cpp
project/pwrtest01/src/appl/ra_qcomtest.cpp
+1
-1
project/pwrtest01/src/appl/ra_qmontest.cpp
project/pwrtest01/src/appl/ra_qmontest.cpp
+2
-2
project/pwrtest01/src/appl/ra_status.cpp
project/pwrtest01/src/appl/ra_status.cpp
+1
-1
project/pwrtest01/src/appl/ra_testall_c.sh
project/pwrtest01/src/appl/ra_testall_c.sh
+1
-0
project/pwrtest01/src/appl/ra_timetest.cpp
project/pwrtest01/src/appl/ra_timetest.cpp
+1
-1
project/pwrtest01/src/appl/ra_xttscripttest.rtt_com
project/pwrtest01/src/appl/ra_xttscripttest.rtt_com
+1
-1
project/pwrtest01/src/login/login.sh
project/pwrtest01/src/login/login.sh
+1
-1
No files found.
project/pwrtest01/build_from_git.sh
View file @
8a04a63c
...
@@ -89,16 +89,33 @@ echo "* Configure adm"
...
@@ -89,16 +89,33 @@ echo "* Configure adm"
export
pwra_db
=
$pwre_broot
/
$os
/
$hw
/bld/project/adm/db
export
pwra_db
=
$pwre_broot
/
$os
/
$hw
/bld/project/adm/db
if
[
!
-e
$pwra_db
]
;
then
if
[
!
-e
$pwra_db
]
;
then
mkdir
-p
$pwra_db
mkdir
-p
$pwra_db
cp
$pwre_croot
/src/tools/pkg/deb/adm/
*
$pwra_db
/
fi
if
[
!
-e
$pwra_db
]
;
then
mkdir
-p
$pwra_db
cp
$pwre_croot
/src/tools/pkg/deb/adm/
*
$pwra_db
/
fi
if
[
"
`
eval grep
CVolPwrtest01
$pwra_db
/pwr_volumelist.dat
`
"
==
""
]
;
then
echo
"CVolPwrtest01 0.0.254.254 pwrtest01"
>>
$pwra_db
/pwr_volumelist.dat
fi
if
[
"
`
eval grep
VolPwrTest01a
$pwra_db
/pwr_volumelist.dat
`
"
==
""
]
;
then
echo
"VolPwrTest01a 0.254.254.201 pwrtest01"
>>
$pwra_db
/pwr_volumelist.dat
fi
if
[
"
`
eval grep
VolPwrTest01b
$pwra_db
/pwr_volumelist.dat
`
"
==
""
]
;
then
echo
"VolPwrTest01b 0.254.254.202 pwrtest01"
>>
$pwra_db
/pwr_volumelist.dat
fi
if
[
"
`
eval grep
VolPwrTest01c
$pwra_db
/pwr_volumelist.dat
`
"
==
""
]
;
then
echo
"VolPwrTest01c 0.254.254.203 pwrtest01"
>>
$pwra_db
/pwr_volumelist.dat
fi
if
[
"
`
eval grep
VolPwrTest01d
$pwra_db
/pwr_volumelist.dat
`
"
==
""
]
;
then
echo
"VolPwrTest01d 0.254.254.204 pwrtest01"
>>
$pwra_db
/pwr_volumelist.dat
fi
if
[
!
-e
$pwra_db
/pwr_projectlist.dat
]
||
[
"
`
eval grep
base
$pwra_db
/pwr_projectlist.dat
`
"
==
""
]
;
then
echo
"%base V0.0.0
$pwre_broot
"
>
$pwra_db
/pwr_projectlist.dat
fi
if
[
"
`
eval grep
pwrtest01
$pwra_db
/pwr_projectlist.dat
`
"
==
""
]
;
then
echo
"pwrtest01 V0.0.0
$pwrp_root
Test-pwrtest01
\"\"
"
>>
$pwra_db
/pwr_projectlist.dat
fi
fi
echo
"pwra_db
$pwra_db
"
cp
$pwre_croot
/src/tools/pkg/deb/adm/
*
$pwra_db
/
echo
"CVolPwrtest01 0.0.254.254 pwrtest01"
>>
$pwra_db
/pwr_volumelist.dat
echo
"VolPwrTest01a 0.254.254.201 pwrtest01"
>>
$pwra_db
/pwr_volumelist.dat
echo
"VolPwrTest01b 0.254.254.202 pwrtest01"
>>
$pwra_db
/pwr_volumelist.dat
echo
"VolPwrTest01c 0.254.254.203 pwrtest01"
>>
$pwra_db
/pwr_volumelist.dat
echo
"VolPwrTest01d 0.254.254.204 pwrtest01"
>>
$pwra_db
/pwr_volumelist.dat
echo
"%base V0.0.0
$pwre_broot
"
>
$pwra_db
/pwr_projectlist.dat
echo
"pwrtest01 V0.0.0
$pwrp_root
Test-pwrtest01
\"\"
"
>>
$pwra_db
/pwr_projectlist.dat
source
$pwra_db
/pwr_setup.sh
source
$pwra_db
/pwr_setup.sh
source
$pwra_db
/pwra_env.sh
set
project pwrtest01
source
$pwra_db
/pwra_env.sh
set
project pwrtest01
...
...
project/pwrtest01/src/appl/ra_aproctest.cpp
View file @
8a04a63c
...
@@ -76,7 +76,7 @@ ra_aproctest::ra_aproctest()
...
@@ -76,7 +76,7 @@ ra_aproctest::ra_aproctest()
pwr_tOid
oid
;
pwr_tOid
oid
;
m_anix
=
errh_eAnix_appl3
;
m_anix
=
errh_eAnix_appl3
;
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Aproc"
,
"$pwrp_log/aproc.log"
);
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Aproc"
,
"$pwrp_log/aproc.
t
log"
);
if
(
EVEN
(
m_sts
))
if
(
EVEN
(
m_sts
))
printf
(
"** Unable to open log file"
);
printf
(
"** Unable to open log file"
);
m_sts
=
gdh_Init
(
"ra_aproctest"
);
m_sts
=
gdh_Init
(
"ra_aproctest"
);
...
...
project/pwrtest01/src/appl/ra_ccmtest.rtt_com
View file @
8a04a63c
...
@@ -990,7 +990,7 @@ main()
...
@@ -990,7 +990,7 @@ main()
int log;
int log;
verify(0);
verify(0);
log = tstlog_open("co-Ccm", "$pwrp_log/ccm.log");
log = tstlog_open("co-Ccm", "$pwrp_log/ccm.
t
log");
ccm_declarations(log);
ccm_declarations(log);
ccm_operators(log);
ccm_operators(log);
...
...
project/pwrtest01/src/appl/ra_cdhtest.cpp
View file @
8a04a63c
...
@@ -1277,7 +1277,7 @@ void ra_cdhtest::AttrElemSize(void)
...
@@ -1277,7 +1277,7 @@ void ra_cdhtest::AttrElemSize(void)
// Constructor
// Constructor
ra_cdhtest
::
ra_cdhtest
()
ra_cdhtest
::
ra_cdhtest
()
{
{
m_log
=
new
tst_log
(
&
m_sts
,
"co-Cdh"
,
"$pwrp_log/cdh.log"
);
m_log
=
new
tst_log
(
&
m_sts
,
"co-Cdh"
,
"$pwrp_log/cdh.
t
log"
);
if
(
EVEN
(
m_sts
))
if
(
EVEN
(
m_sts
))
printf
(
"** Unable to open log file"
);
printf
(
"** Unable to open log file"
);
}
}
...
...
project/pwrtest01/src/appl/ra_errhtest.cpp
View file @
8a04a63c
...
@@ -561,7 +561,7 @@ ra_errhtest::ra_errhtest()
...
@@ -561,7 +561,7 @@ ra_errhtest::ra_errhtest()
pwr_tOid
oid
;
pwr_tOid
oid
;
m_anix
=
errh_eAnix_appl1
;
m_anix
=
errh_eAnix_appl1
;
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Errh"
,
"$pwrp_log/errh.log"
);
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Errh"
,
"$pwrp_log/errh.
t
log"
);
if
(
EVEN
(
m_sts
))
if
(
EVEN
(
m_sts
))
printf
(
"** Unable to open log file"
);
printf
(
"** Unable to open log file"
);
m_sts
=
gdh_Init
(
"ra_errhtest"
);
m_sts
=
gdh_Init
(
"ra_errhtest"
);
...
...
project/pwrtest01/src/appl/ra_gdhtest.cpp
View file @
8a04a63c
...
@@ -928,55 +928,6 @@ void ra_gdhtest::GetPreviousSibling(void)
...
@@ -928,55 +928,6 @@ void ra_gdhtest::GetPreviousSibling(void)
}
}
#if 0
void ra_gdhtest::GetPreviousSibling(void)
{
pwr_tOName name;
pwr_tOid oid;
// Get last sibling of first child
m_sts = gdh_GetNextSibling(m_child, &oid);
if (ODD(m_sts))
m_sts = gdh_GetNextSibling(oid, &oid);
if (ODD(m_sts))
m_sts = gdh_GetNextSibling(oid, &oid);
if (ODD(m_sts))
m_sts = gdh_GetNextSibling(oid, &oid);
m_sts = gdh_GetPreviousSibling(oid, &oid);
if (EVEN(m_sts)) {
m_log->log('E', "GetPreviousSibling", m_sts);
return;
}
m_sts = gdh_ObjidToName(oid, name, sizeof(name), cdh_mNName);
if (EVEN(m_sts)) {
m_log->log('E', "GetPreviousSibling", "ObjidToName failed", m_sts);
return;
}
if (strcmp(name, "RootObject-Child3") != 0) {
m_log->log('E', "GetPreviousSibling", "Wrong silbing");
return;
}
// Get nonexisting child
m_sts = gdh_GetPreviousSibling(oid, &oid);
if (ODD(m_sts))
m_sts = gdh_GetPreviousSibling(oid, &oid);
if (ODD(m_sts))
m_sts = gdh_GetPreviousSibling(oid, &oid);
if (ODD(m_sts)) {
m_log->log('E', "GetPreviousSibling returned noexisting object");
return;
}
else if (m_sts != GDH__NO_SIBLING) {
m_log->log('E', "GetPreviousSibling wrong sts", m_sts);
return;
}
m_log->log('S', "GetPreviousSibling", GDH__SUCCESS);
}
#endif
void
ra_gdhtest
::
GetNodeIndex
(
void
)
void
ra_gdhtest
::
GetNodeIndex
(
void
)
{
{
pwr_tNid
nid
;
pwr_tNid
nid
;
...
@@ -1325,409 +1276,111 @@ void ra_gdhtest::GetAttributeCharAttrref(void)
...
@@ -1325,409 +1276,111 @@ void ra_gdhtest::GetAttributeCharAttrref(void)
m_log
->
log
(
'S'
,
"GetAttributeCharAttrref"
,
GDH__SUCCESS
);
m_log
->
log
(
'S'
,
"GetAttributeCharAttrref"
,
GDH__SUCCESS
);
}
}
void
ra_gdhtest
::
NameToAttrref
(
void
)
{
pwr_tAttrRef
aref
;
pwr_tAName
aname
;
// Get ordinary attribute
typedef
struct
{
sprintf
(
aname
,
"RootObject-Child1.Photo"
);
pwr_tOName
aname
;
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
aname
,
&
aref
);
pwr_tOName
result
;
if
(
EVEN
(
m_sts
))
{
pwr_tStatus
sts
;
m_log
->
log
(
'E'
,
"NameToAttrref, can't get aref"
,
m_sts
);
}
sNameToAttrRef
;
return
;
}
// Get object attribute
void
ra_gdhtest
::
NameToAttrref
(
void
)
sprintf
(
aname
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
);
{
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
aname
,
&
aref
);
sNameToAttrRef
d
[]
=
{
if
(
EVEN
(
m_sts
))
{
{
"RootObject-Child1.Photo"
,
"RootObject-Child1.Photo"
,
GDH__SUCCESS
},
m_log
->
log
(
'E'
,
"NameToAttrref"
,
m_sts
);
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
GDH__SUCCESS
},
return
;
{
"RootObject-Child1-A1.Value"
,
"RootObject-Child1-A1.Value"
,
GDH__SUCCESS
},
}
{
"RootObject-Child1-A1.Value[99]"
,
"RootObject-Child1-A1.Value[99]"
,
GDH__SUCCESS
}
};
// Get array attribute
pwr_tAttrRef
aref
;
sprintf
(
aname
,
"RootObject-Child1-A1.Value"
);
pwr_tAName
aname2
;
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
aname
,
&
aref
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"NameToAttrref, can't get aref"
,
m_sts
);
return
;
}
// Get array element attributes
for
(
unsigned
int
i
=
0
;
i
<
sizeof
(
d
)
/
sizeof
(
d
[
0
]);
i
++
)
{
for
(
int
i
=
0
;
i
<
100
;
i
++
)
{
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
d
[
i
].
aname
,
&
aref
);
sprintf
(
aname
,
"RootObject-Child1-A1.Value[%d]"
,
i
);
if
(
m_sts
!=
d
[
i
].
sts
)
{
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
aname
,
&
aref
);
m_log
->
log
(
'E'
,
"NameToAttrref, wrong sts"
,
d
[
i
].
aname
,
m_sts
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"NameToAttrref, can't get aref"
,
m_sts
);
return
;
return
;
}
}
if
(
ODD
(
m_sts
))
{
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mNName
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"NameToAttrref, gdh_AttrrefToName"
,
d
[
i
].
aname
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
d
[
i
].
result
)
!=
0
)
{
m_log
->
vlog
(
'E'
,
"NameToAttrref, %s != %s, idx %d"
,
aname2
,
d
[
i
].
result
,
i
);
return
;
}
}
}
}
m_log
->
log
(
'S'
,
"NameToAttrref"
,
GDH__SUCCESS
);
m_log
->
log
(
'S'
,
"NameToAttrref"
,
GDH__SUCCESS
);
}
}
typedef
struct
{
pwr_tOName
aname
;
int
nametype
;
pwr_tOName
result
;
pwr_tStatus
sts
;
}
sAttrRefToName
;
void
ra_gdhtest
::
AttrrefToName
(
void
)
void
ra_gdhtest
::
AttrrefToName
(
void
)
{
{
pwr_tAttrRef
aref
;
sAttrRefToName
d
[]
=
{
pwr_tAName
aname
,
aname2
;
{
"RootObject-Child1.Photo"
,
cdh_mNName
,
"RootObject-Child1.Photo"
,
GDH__SUCCESS
},
{
"RootObject-Child1.Photo"
,
cdh_mName_object
,
"Child1"
,
GDH__SUCCESS
},
// Get ordinary attribute
{
"RootObject-Child1.Photo"
,
cdh_mName_attribute
,
"Photo"
,
GDH__SUCCESS
},
sprintf
(
aname
,
"RootObject-Child1.Photo"
);
{
"RootObject-Child1.Photo"
,
cdh_mName_object
|
cdh_mName_attribute
,
"Child1.Photo"
,
GDH__SUCCESS
},
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
aname
,
&
aref
);
{
"RootObject-Child1.Photo"
,
cdh_mName_volumeStrict
,
"VolPwrTest01c:RootObject-Child1.Photo"
,
GDH__SUCCESS
},
if
(
EVEN
(
m_sts
))
{
{
"RootObject-Child1.Photo"
,
cdh_mName_pathStrict
,
"RootObject-Child1.Photo"
,
GDH__SUCCESS
},
m_log
->
log
(
'E'
,
"AttrrefToName can't get aref"
,
m_sts
);
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
cdh_mNName
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
GDH__SUCCESS
},
return
;
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
cdh_mName_object
,
"P1"
,
GDH__SUCCESS
},
}
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
cdh_mName_attribute
,
"CircuitBreaker.NotTripped"
,
GDH__SUCCESS
},
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
cdh_mName_object
|
cdh_mName_attribute
,
"P1.CircuitBreaker.NotTripped"
,
GDH__SUCCESS
},
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mNName
);
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
cdh_mName_volumeStrict
,
"VolPwrTest01c:RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
GDH__SUCCESS
},
if
(
EVEN
(
m_sts
))
{
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
cdh_mName_pathStrict
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
GDH__SUCCESS
},
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped.Photo"
,
cdh_mNName
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped.Photo"
,
GDH__SUCCESS
},
return
;
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped.Photo"
,
cdh_mName_object
,
"P1"
,
GDH__SUCCESS
},
}
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped.Photo"
,
cdh_mName_attribute
,
"CircuitBreaker.NotTripped.Photo"
,
GDH__SUCCESS
},
if
(
strcmp
(
aname2
,
"RootObject-Child1.Photo"
)
!=
0
)
{
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped.Photo"
,
cdh_mName_volumeStrict
,
"VolPwrTest01c:RootObject-Child1-P1.CircuitBreaker.NotTripped.Photo"
,
GDH__SUCCESS
},
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped.Photo"
,
cdh_mName_pathStrict
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped.Photo"
,
GDH__SUCCESS
},
return
;
{
"RootObject-Child1-A1.Value"
,
cdh_mNName
,
"RootObject-Child1-A1.Value"
,
GDH__SUCCESS
},
}
{
"RootObject-Child1-A1.Value"
,
cdh_mName_object
,
"A1"
,
GDH__SUCCESS
},
{
"RootObject-Child1-A1.Value"
,
cdh_mName_attribute
,
"Value"
,
GDH__SUCCESS
},
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_object
);
{
"RootObject-Child1-A1.Value"
,
cdh_mName_volumeStrict
,
"VolPwrTest01c:RootObject-Child1-A1.Value"
,
GDH__SUCCESS
},
if
(
EVEN
(
m_sts
))
{
{
"RootObject-Child1-A1.Value"
,
cdh_mName_pathStrict
,
"RootObject-Child1-A1.Value"
,
GDH__SUCCESS
},
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
{
"RootObject-Child1-A1.Value[99]"
,
cdh_mNName
,
"RootObject-Child1-A1.Value[99]"
,
GDH__SUCCESS
},
return
;
{
"RootObject-Child1-A1.Value[99]"
,
cdh_mName_object
,
"A1"
,
GDH__SUCCESS
},
}
{
"RootObject-Child1-A1.Value[99]"
,
cdh_mName_attribute
,
"Value"
,
GDH__SUCCESS
},
if
(
strcmp
(
aname2
,
"Child1"
)
!=
0
)
{
{
"RootObject-Child1-A1.Value[99]"
,
cdh_mName_object
|
cdh_mName_attribute
|
cdh_mName_index
,
"A1.Value[99]"
,
GDH__SUCCESS
},
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
{
"RootObject-Child1-A1.Value[99]"
,
cdh_mName_volumeStrict
,
"VolPwrTest01c:RootObject-Child1-A1.Value[99]"
,
GDH__SUCCESS
},
return
;
{
"RootObject-Child1-A1.Value[99]"
,
cdh_mName_pathStrict
,
"RootObject-Child1-A1.Value[99]"
,
GDH__SUCCESS
}
}
};
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_attribute
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"Photo"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_object
|
cdh_mName_attribute
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"Child1.Photo"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_volumeStrict
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"VolPwrTest01c:RootObject-Child1.Photo"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_pathStrict
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"RootObject-Child1.Photo"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
// Get object attribute
sprintf
(
aname
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
);
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
aname
,
&
aref
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName can't get aref"
,
m_sts
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mNName
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_object
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"P1"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_attribute
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"CircuitBreaker.NotTripped"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_object
|
cdh_mName_attribute
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"P1.CircuitBreaker.NotTripped"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_volumeStrict
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"VolPwrTest01c:RootObject-Child1-P1.CircuitBreaker.NotTripped"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_pathStrict
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
// Get attrobject attribute
sprintf
(
aname
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped.Photo"
);
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
aname
,
&
aref
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName can't get aref"
,
m_sts
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mNName
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped.Photo"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_object
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"P1"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_attribute
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"CircuitBreaker.NotTripped.Photo"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_object
|
cdh_mName_attribute
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"P1.CircuitBreaker.NotTripped.Photo"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_volumeStrict
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"VolPwrTest01c:RootObject-Child1-P1.CircuitBreaker.NotTripped.Photo"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_pathStrict
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped.Photo"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
// Get array attribute
sprintf
(
aname
,
"RootObject-Child1-A1.Value"
);
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
aname
,
&
aref
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName can't get aref"
,
m_sts
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mNName
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"RootObject-Child1-A1.Value"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_object
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"A1"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_attribute
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"Value"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_object
|
cdh_mName_attribute
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"A1.Value"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_volumeStrict
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"VolPwrTest01c:RootObject-Child1-A1.Value"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_pathStrict
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"RootObject-Child1-A1.Value"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
// Get array element attribute
sprintf
(
aname
,
"RootObject-Child1-A1.Value[99]"
);
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
aname
,
&
aref
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName can't get aref"
,
m_sts
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mNName
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"RootObject-Child1-A1.Value[99]"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_object
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"A1"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_attribute
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"Value"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_attribute
|
cdh_mName_index
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"Value[99]"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_object
|
pwr_tAttrRef
aref
;
cdh_mName_attribute
|
cdh_mName_index
);
pwr_tAName
aname2
;
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname2
,
"A1.Value[99]"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_volumeStrict
);
for
(
unsigned
int
i
=
0
;
i
<
sizeof
(
d
)
/
sizeof
(
d
[
0
]);
i
++
)
{
if
(
EVEN
(
m_sts
))
{
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
d
[
i
].
aname
,
&
aref
);
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
if
(
EVEN
(
m_sts
))
{
return
;
m_log
->
log
(
'E'
,
"AttrrefToName, gdh_NameToAttrref"
,
m_sts
);
}
return
;
if
(
strcmp
(
aname2
,
"VolPwrTest01c:RootObject-Child1-A1.Value[99]"
)
!=
0
)
{
}
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
cdh_mName_pathStrict
);
m_sts
=
gdh_AttrrefToName
(
&
aref
,
aname2
,
sizeof
(
aname2
),
d
[
i
].
nametype
);
if
(
EVEN
(
m_sts
))
{
if
(
m_sts
!=
d
[
i
].
sts
)
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
m_sts
);
m_log
->
log
(
'E'
,
"AttrrefToName, wrong sts"
,
d
[
i
].
aname
,
m_sts
);
return
;
return
;
}
}
if
(
strcmp
(
aname2
,
"RootObject-Child1-A1.Value[99]"
)
!=
0
)
{
if
(
ODD
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrrefToName"
,
aname2
);
if
(
strcmp
(
aname2
,
d
[
i
].
result
)
!=
0
)
{
return
;
m_log
->
vlog
(
'E'
,
"AttrrefToName, %s != %s, idx %d"
,
aname2
,
d
[
i
].
result
,
i
);
return
;
}
}
}
}
m_log
->
log
(
'S'
,
"Attr
r
efToName"
,
GDH__SUCCESS
);
m_log
->
log
(
'S'
,
"Attr
R
efToName"
,
GDH__SUCCESS
);
}
}
void
ra_gdhtest
::
ClassAttrToAttrref
(
void
)
void
ra_gdhtest
::
ClassAttrToAttrref
(
void
)
...
@@ -1779,78 +1432,47 @@ void ra_gdhtest::ClassAttrToAttrref(void)
...
@@ -1779,78 +1432,47 @@ void ra_gdhtest::ClassAttrToAttrref(void)
m_log
->
log
(
'S'
,
"ClassAttrToAttrref"
,
GDH__SUCCESS
);
m_log
->
log
(
'S'
,
"ClassAttrToAttrref"
,
GDH__SUCCESS
);
}
}
typedef
struct
{
pwr_tOName
aname
;
pwr_tOName
oname
;
pwr_tStatus
sts
;
}
sAttrArefToObjectAref
;
void
ra_gdhtest
::
AttrArefToObjectAref
(
void
)
void
ra_gdhtest
::
AttrArefToObjectAref
(
void
)
{
{
pwr_tAttrRef
aref
,
oaref
;
sAttrArefToObjectAref
d
[]
=
{
pwr_tAName
aname
;
{
"RootObject-Child1.Photo"
,
"RootObject-Child1"
,
GDH__SUCCESS
},
{
"RootObject-Child1-A1.Value[99]"
,
"RootObject-Child1-A1"
,
GDH__SUCCESS
},
// Test ordinary attribute
{
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
"RootObject-Child1-P1.CircuitBreaker"
,
GDH__SUCCESS
}
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
"RootObject-Child1.Photo"
,
&
aref
);
};
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrArefToObjectAref"
,
"gdh_NameToAttrref"
,
m_sts
);
return
;
}
m_sts
=
gdh_AttrArefToObjectAref
(
&
aref
,
&
oaref
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrArefToObjectAref"
,
m_sts
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
oaref
,
aname
,
sizeof
(
aname
),
cdh_mName_pathStrict
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrArefToObjectAref"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname
,
"RootObject-Child1"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrArefToObjectAref wrong name"
,
aname
);
return
;
}
// Test attrobject attribute
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
"RootObject-Child1-P1.CircuitBreaker.NotTripped"
,
&
aref
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrArefToObjectAref"
,
"gdh_NameToAttrref"
,
m_sts
);
return
;
}
m_sts
=
gdh_AttrArefToObjectAref
(
&
aref
,
&
oaref
);
pwr_tAttrRef
aref
,
oaref
;
if
(
EVEN
(
m_sts
))
{
pwr_tAName
aname
;
m_log
->
log
(
'E'
,
"AttrArefToObjectAref"
,
m_sts
);
return
;
}
m_sts
=
gdh_AttrrefToName
(
&
oaref
,
aname
,
sizeof
(
aname
),
cdh_mName_pathStrict
);
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrArefToObjectAref"
,
m_sts
);
return
;
}
if
(
strcmp
(
aname
,
"RootObject-Child1-P1.CircuitBreaker"
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrArefToObjectAref wrong name"
,
aname
);
return
;
}
// Test array element
for
(
unsigned
int
i
=
0
;
i
<
sizeof
(
d
)
/
sizeof
(
d
[
0
]);
i
++
)
{
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
"RootObject-Child1-A1.Value[99]"
,
&
aref
);
m_sts
=
gdh_NameToAttrref
(
pwr_cNOid
,
d
[
i
].
aname
,
&
aref
);
if
(
EVEN
(
m_sts
))
{
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrArefToObjectAref"
,
"gdh_NameToAttrref"
,
m_sts
);
m_log
->
log
(
'E'
,
"AttrArefToObjectAref"
,
"gdh_NameToAttrref"
,
m_sts
);
return
;
return
;
}
}
m_sts
=
gdh_AttrArefToObjectAref
(
&
aref
,
&
oaref
);
m_sts
=
gdh_AttrArefToObjectAref
(
&
aref
,
&
oaref
);
if
(
EVEN
(
m_sts
))
{
if
(
m_sts
!=
d
[
i
].
sts
)
{
m_log
->
log
(
'E'
,
"AttrArefToObjectAref"
,
m_sts
);
m_log
->
log
(
'E'
,
"AttrArefToObjetAref, wrong sts"
,
d
[
i
].
aname
,
m_sts
);
return
;
return
;
}
}
if
(
ODD
(
m_sts
))
{
m_sts
=
gdh_AttrrefToName
(
&
oaref
,
aname
,
sizeof
(
aname
),
cdh_mName_pathStrict
);
m_sts
=
gdh_AttrrefToName
(
&
oaref
,
aname
,
sizeof
(
aname
),
cdh_mName_pathStrict
);
if
(
EVEN
(
m_sts
))
{
if
(
EVEN
(
m_sts
))
{
m_log
->
log
(
'E'
,
"AttrArefToObjectAref"
,
m_sts
);
m_log
->
log
(
'E'
,
"AttrArefToObjectAref"
,
m_sts
);
return
;
return
;
}
}
if
(
strcmp
(
aname
,
"RootObject-Child1-A1"
)
!=
0
)
{
if
(
strcmp
(
aname
,
d
[
i
].
oname
)
!=
0
)
{
m_log
->
log
(
'E'
,
"AttrArefToObjectAref wrong name"
,
aname
);
m_log
->
vlog
(
'E'
,
"AttrArefToObjectAref wrong name, %s != %s"
,
aname
,
d
[
i
].
oname
);
return
;
return
;
}
}
}
}
m_log
->
log
(
'S'
,
"AttrArefToObjectAref"
,
GDH__SUCCESS
);
m_log
->
log
(
'S'
,
"AttrArefToObjectAref"
,
GDH__SUCCESS
);
...
@@ -3748,7 +3370,7 @@ void ra_gdhtest::SetObjectInfoStr(void)
...
@@ -3748,7 +3370,7 @@ void ra_gdhtest::SetObjectInfoStr(void)
// Constructor
// Constructor
ra_gdhtest
::
ra_gdhtest
()
ra_gdhtest
::
ra_gdhtest
()
{
{
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Gdh"
,
"$pwrp_log/gdh.log"
);
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Gdh"
,
"$pwrp_log/gdh.
t
log"
);
if
(
EVEN
(
m_sts
))
if
(
EVEN
(
m_sts
))
printf
(
"** Unable to open log file"
);
printf
(
"** Unable to open log file"
);
}
}
...
...
project/pwrtest01/src/appl/ra_mhappltest.cpp
View file @
8a04a63c
...
@@ -621,7 +621,7 @@ ra_mhappltest::ra_mhappltest() : m_clean(0), m_checkstatus(0), m_errcnt(0)
...
@@ -621,7 +621,7 @@ ra_mhappltest::ra_mhappltest() : m_clean(0), m_checkstatus(0), m_errcnt(0)
{
{
m_mh
=
this
;
m_mh
=
this
;
m_clean
=
1
;
m_clean
=
1
;
m_log
=
new
tst_log
(
&
m_sts
,
"rt-MhAppl"
,
"$pwrp_log/mhappl.log"
);
m_log
=
new
tst_log
(
&
m_sts
,
"rt-MhAppl"
,
"$pwrp_log/mhappl.
t
log"
);
if
(
EVEN
(
m_sts
))
if
(
EVEN
(
m_sts
))
printf
(
"** Unable to open log file"
);
printf
(
"** Unable to open log file"
);
m_sts
=
gdh_Init
(
"ra_mhappltest"
);
m_sts
=
gdh_Init
(
"ra_mhappltest"
);
...
...
project/pwrtest01/src/appl/ra_mhtest.cpp
View file @
8a04a63c
...
@@ -525,7 +525,7 @@ ra_mhtest::ra_mhtest() : m_clean(0), m_checkstatus(0), m_errcnt(0)
...
@@ -525,7 +525,7 @@ ra_mhtest::ra_mhtest() : m_clean(0), m_checkstatus(0), m_errcnt(0)
{
{
m_mh
=
this
;
m_mh
=
this
;
m_clean
=
1
;
m_clean
=
1
;
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Mh"
,
"$pwrp_log/mh.log"
);
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Mh"
,
"$pwrp_log/mh.
t
log"
);
if
(
EVEN
(
m_sts
))
if
(
EVEN
(
m_sts
))
printf
(
"** Unable to open log file"
);
printf
(
"** Unable to open log file"
);
m_sts
=
gdh_Init
(
"ra_mhtest"
);
m_sts
=
gdh_Init
(
"ra_mhtest"
);
...
...
project/pwrtest01/src/appl/ra_nettimetest.cpp
View file @
8a04a63c
...
@@ -87,7 +87,7 @@ void ra_nettimetest::NetTimeToDeltaTime(void)
...
@@ -87,7 +87,7 @@ void ra_nettimetest::NetTimeToDeltaTime(void)
// Constructor
// Constructor
ra_nettimetest
::
ra_nettimetest
()
ra_nettimetest
::
ra_nettimetest
()
{
{
m_log
=
new
tst_log
(
&
m_sts
,
"rt-NetTime"
,
"$pwrp_log/nettime.log"
);
m_log
=
new
tst_log
(
&
m_sts
,
"rt-NetTime"
,
"$pwrp_log/nettime.
t
log"
);
if
(
EVEN
(
m_sts
))
if
(
EVEN
(
m_sts
))
printf
(
"** Unable to open log file"
);
printf
(
"** Unable to open log file"
);
}
}
...
...
project/pwrtest01/src/appl/ra_plctest.cpp
View file @
8a04a63c
...
@@ -115,7 +115,7 @@ int main()
...
@@ -115,7 +115,7 @@ int main()
unsigned
int
i
;
unsigned
int
i
;
pwr_tAName
aname
;
pwr_tAName
aname
;
tst_log
*
log
=
new
tst_log
(
&
sts
,
"rt-Plc"
,
"$pwrp_log/plc.log"
);
tst_log
*
log
=
new
tst_log
(
&
sts
,
"rt-Plc"
,
"$pwrp_log/plc.
t
log"
);
if
(
EVEN
(
sts
))
if
(
EVEN
(
sts
))
printf
(
"** Unable to open log file"
);
printf
(
"** Unable to open log file"
);
...
...
project/pwrtest01/src/appl/ra_pwrrttest.py
View file @
8a04a63c
...
@@ -1494,7 +1494,7 @@ class Ctx:
...
@@ -1494,7 +1494,7 @@ class Ctx:
ctx
=
Ctx
()
ctx
=
Ctx
()
ctx
.
logger
=
pwrtest
.
logger
(
'rt-pwrrt'
,
'$pwrp_log/pwrrt.log'
)
ctx
.
logger
=
pwrtest
.
logger
(
'rt-pwrrt'
,
'$pwrp_log/pwrrt.
t
log'
)
try
:
try
:
ctx
.
init
()
ctx
.
init
()
except
:
except
:
...
...
project/pwrtest01/src/appl/ra_qcomtest.cpp
View file @
8a04a63c
...
@@ -1414,7 +1414,7 @@ void ra_qcomtest::Request(void)
...
@@ -1414,7 +1414,7 @@ void ra_qcomtest::Request(void)
// Constructor
// Constructor
ra_qcomtest
::
ra_qcomtest
()
ra_qcomtest
::
ra_qcomtest
()
{
{
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Qcom"
,
"$pwrp_log/qcom.log"
);
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Qcom"
,
"$pwrp_log/qcom.
t
log"
);
if
(
EVEN
(
m_sts
))
if
(
EVEN
(
m_sts
))
printf
(
"** Unable to open log file"
);
printf
(
"** Unable to open log file"
);
}
}
...
...
project/pwrtest01/src/appl/ra_qmontest.cpp
View file @
8a04a63c
...
@@ -488,9 +488,9 @@ ra_qmontest::ra_qmontest(eProc ptype) : m_ptype(ptype), m_qquota(500), m_errcnt(
...
@@ -488,9 +488,9 @@ ra_qmontest::ra_qmontest(eProc ptype) : m_ptype(ptype), m_qquota(500), m_errcnt(
pwr_tVid
vid
;
pwr_tVid
vid
;
if
(
isServer
())
if
(
isServer
())
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Qmon"
,
"$pwrp_log/qmon.log"
);
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Qmon"
,
"$pwrp_log/qmon.
t
log"
);
else
else
m_log
=
new
tst_log
(
&
m_sts
,
"rt-QmonClient"
,
"$pwrp_log/qmonc.log"
);
m_log
=
new
tst_log
(
&
m_sts
,
"rt-QmonClient"
,
"$pwrp_log/qmonc.
t
log"
);
if
(
EVEN
(
m_sts
))
if
(
EVEN
(
m_sts
))
printf
(
"** Unable to open log file"
);
printf
(
"** Unable to open log file"
);
...
...
project/pwrtest01/src/appl/ra_status.cpp
View file @
8a04a63c
...
@@ -55,7 +55,7 @@ void ra_status::test_status()
...
@@ -55,7 +55,7 @@ void ra_status::test_status()
// Constructor
// Constructor
ra_status
::
ra_status
()
ra_status
::
ra_status
()
{
{
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Status"
,
"$pwrp_log/tst_status.log"
);
m_log
=
new
tst_log
(
&
m_sts
,
"rt-Status"
,
"$pwrp_log/tst_status.
t
log"
);
if
(
EVEN
(
m_sts
))
if
(
EVEN
(
m_sts
))
printf
(
"** Unable to open log file"
);
printf
(
"** Unable to open log file"
);
...
...
project/pwrtest01/src/appl/ra_testall_c.sh
View file @
8a04a63c
...
@@ -14,6 +14,7 @@ dexec()
...
@@ -14,6 +14,7 @@ dexec()
exec
"ra_plctest"
exec
"ra_plctest"
exec
"ra_timetest"
exec
"ra_timetest"
exec
"ra_nettimetest"
exec
"ra_cdhtest"
exec
"ra_cdhtest"
exec
"ra_gdhtest"
exec
"ra_gdhtest"
exec
"ra_errhtest"
exec
"ra_errhtest"
...
...
project/pwrtest01/src/appl/ra_timetest.cpp
View file @
8a04a63c
...
@@ -1082,7 +1082,7 @@ void ra_timetest::GetTimeMonotonic(void)
...
@@ -1082,7 +1082,7 @@ void ra_timetest::GetTimeMonotonic(void)
// Constructor
// Constructor
ra_timetest
::
ra_timetest
()
ra_timetest
::
ra_timetest
()
{
{
m_log
=
new
tst_log
(
&
m_sts
,
"co-Time"
,
"$pwrp_log/time.log"
);
m_log
=
new
tst_log
(
&
m_sts
,
"co-Time"
,
"$pwrp_log/time.
t
log"
);
if
(
EVEN
(
m_sts
))
if
(
EVEN
(
m_sts
))
printf
(
"** Unable to open log file"
);
printf
(
"** Unable to open log file"
);
}
}
...
...
project/pwrtest01/src/appl/ra_xttscripttest.rtt_com
View file @
8a04a63c
...
@@ -596,7 +596,7 @@ main()
...
@@ -596,7 +596,7 @@ main()
verify(0);
verify(0);
tzset("Europe/Stockholm");
tzset("Europe/Stockholm");
log = tstlog_open("op-XttScript", "$pwrp_log/xttscript.log");
log = tstlog_open("op-XttScript", "$pwrp_log/xttscript.
t
log");
ccm_CutObjectName(log);
ccm_CutObjectName(log);
ccm_GetAttribute(log);
ccm_GetAttribute(log);
...
...
project/pwrtest01/src/login/login.sh
View file @
8a04a63c
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
export
PWR_BUS_ID
=
999
export
PWR_BUS_ID
=
999
if
[
-e
"
/data0/pwrp/tellus
/login/sysinfo.txt"
]
;
then
if
[
-e
"
$pwrp_root
/src
/login/sysinfo.txt"
]
;
then
echo
"-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_"
echo
"-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_"
echo
"Welcome to"
echo
"Welcome to"
echo
"
`
$pwr_exe
/pwrp_env.sh show project
`
"
echo
"
`
$pwr_exe
/pwrp_env.sh show project
`
"
...
...
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