FACT++
1.0
Main Page
Related Pages
Namespaces
Classes
Files
Examples
void ConnectionDrive::HandlePdo1
(
const uint8_t &
node
,
const uint8_t *
data
,
const
Time
&
tv
)
inline
private
Definition at line
748
of file
drivectrl.cc
.
References
Time::GetAsStr()
.
749
{
750
const
uint32_t pos1 = (
data
[3]<<24) | (
data
[2]<<16) | (
data
[1]<<8) |
data
[0];
751
const
uint32_t pos2 = (
data
[7]<<24) | (
data
[6]<<16) | (
data
[5]<<8) |
data
[4];
752
753
if
(
fVerbosity
>2)
754
Out
() <<
Time
().
GetAsStr
(
"%M:%S.%f"
) <<
" PDO1["
<< (int)
node
<<
"] "
<< 360.*int32_t(pos1)/
fPosRes
[
node
/2] <<
" "
<< 360.*int32_t(pos2)/
fPosRes
[
node
/2] << endl;
755
756
// Once every few milliseconds!
757
758
fPdoPos1
[
node
/2] = pos1;
759
fPdoTime1
[
node
/2] = tv;
760
fHasChangedPos1
[
node
/2] =
true
;
761
762
fPdoPos2
[
node
/2] = pos2;
763
fPdoTime2
[
node
/2] = tv;
764
fHasChangedPos2
[
node
/2] =
true
;
765
}
ConnectionDrive::fPdoTime1
Time fPdoTime1[2]
Definition:
drivectrl.cc:741
node
Definition:
dns.c:26
ConnectionDrive::fHasChangedPos2
bool fHasChangedPos2[2]
Definition:
drivectrl.cc:746
Time
Adds some functionality to boost::posix_time::ptime for our needs.
Definition:
Time.h:30
ConnectionDrive::fPosRes
uint32_t fPosRes[2]
Definition:
drivectrl.cc:583
ConnectionDrive::fPdoTime2
Time fPdoTime2[2]
Definition:
drivectrl.cc:743
Connection::Out
std::ostream & Out()
Definition:
Connection.h:51
ConnectionDrive::fPdoPos2
int32_t fPdoPos2[2]
Definition:
drivectrl.cc:739
ConnectionDrive::fHasChangedPos1
bool fHasChangedPos1[2]
Definition:
drivectrl.cc:745
ConnectionDrive::fPdoPos1
int32_t fPdoPos1[2]
Definition:
drivectrl.cc:738
ConnectionDrive::fVerbosity
uint16_t fVerbosity
Definition:
drivectrl.cc:484
data
float data[4 *1440]
Definition:
EventBuilderWrapper.h:95
Time::GetAsStr
std::string GetAsStr(const char *fmt="%Y-%m-%d %H:%M:%S") const
Definition:
Time.cc:240
Here is the call graph for this function:
ConnectionDrive
Generated on Sun Sep 18 2016 20:50:44 for FACT++ by
1.8.11