blob: 7bfcd99d6084ce2909571b6632457e8a51519566 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
/*
* CanAnalyzer.cpp
*
* Created on: 18.01.2011
* Author: istsveise
*/
#include "CanAnalyzer.h"
#include <math.h>
CanAnalyzer::CanAnalyzer() {
// TODO Auto-generated constructor stub
}
CanAnalyzer::~CanAnalyzer() {
// TODO Auto-generated destructor stub
}
int CanAnalyzer::getMaxTransmissionTimeUsec(CanMessage& m)
{
int tau = 1; // 1 mircosecond bit time
int transTimeUsec = (floor((34+8*m.byteCount)/5)+47+8*m.byteCount)*tau;
return transTimeUsec;
}
|