Cat
lbcat-cmake
CatCaloProto40MHz
src
Proto40MHz_v1.cpp
Go to the documentation of this file.
1
// $Id: $
2
// Include files
3
4
5
// local
6
#include "
Proto40MHz_v1.h
"
7
8
//-----------------------------------------------------------------------------
9
// Implementation file for class : Proto40MHz_v1
10
//
11
// 2006-10-23 :
12
//-----------------------------------------------------------------------------
13
14
//=============================================================================
15
// Standard constructor, initializes variables
16
//=============================================================================
17
Proto40MHz_v1::Proto40MHz_v1
( ) {
18
setName
(
"Proto40MHz_v1"
);
19
setType
(
"Proto40MHz_v1"
);
20
add
(
Attrib::ELEMENT
);
add
(
Attrib::HARDWARE
);
21
22
m_usb
=
new
UsbFTInterface
();
23
m_usbi2c
=
new
UsbI2cBus
();
24
m_phaser0
=
new
Phaser
();
25
m_phaser1
=
new
Phaser
();
26
m_phaser2
=
new
Phaser
();
27
28
m_usb
->
setName
(
"Usb"
);
29
m_usbi2c
->
setName
(
"UsbI2c"
);
30
m_phaser0
->
setName
(
"Phaser0"
);
31
m_phaser1
->
setName
(
"Phaser1"
);
32
m_phaser2
->
setName
(
"Phaser2"
);
33
34
addChild
(
m_usb
);
35
m_usb
->
addChild
(
m_usbi2c
);
36
m_usbi2c
->
addChild
(
m_phaser0
);
37
m_usbi2c
->
addChild
(
m_phaser1
);
38
m_usbi2c
->
addChild
(
m_phaser2
);
39
m_usbi2c
->
regAddress
()->
setAddress
(21);
40
m_usbi2c
->
regData
() ->
setAddress
(5);
41
42
m_phaser0
->
reg
()->
setAddress
(65);
43
m_phaser1
->
reg
()->
setAddress
(66);
44
m_phaser2
->
reg
()->
setAddress
(68);
45
46
m_usbspi
=
new
UsbSpiBus
();
47
m_usbspi
->
setName
(
"UsbSpi"
);
48
m_usb
->
addChild
(
m_usbspi
);
49
m_reg
=
new
Register
();
50
m_reg
->
io
()->
defDataU8
(4);
51
m_reg
->
setName
(
"SpiReg"
);
52
m_reg
->
setAddress
(8);
53
m_usbspi
->
addChild
(
m_reg
);
54
55
m_a3pe
=
new
A3PE
();
56
m_a3pe
->
setName
(
"A3PE"
);
57
m_usb
->
addChild
(
m_a3pe
);
58
}
59
//=============================================================================
60
// Destructor
61
//=============================================================================
62
Proto40MHz_v1::~Proto40MHz_v1
() {
63
64
}
65
66
//=============================================================================
UsbI2cBus::regAddress
Register * regAddress()
Definition:
UsbI2cBus.h:54
Phaser
Definition:
Phaser.h:19
Proto40MHz_v1::m_phaser0
Phaser * m_phaser0
Definition:
Proto40MHz_v1.h:84
Proto40MHz_v1.h
Attrib::add
void add(int attribut)
Definition:
Attrib.h:67
Object::setName
void setName(std::string name)
Definition:
Object.h:51
UsbI2cBus::regData
Register * regData()
Definition:
UsbI2cBus.h:58
Proto40MHz_v1::m_reg
Register * m_reg
Definition:
Proto40MHz_v1.h:87
Phaser::reg
Register * reg()
Definition:
Phaser.h:101
UsbFTInterface
Definition:
UsbFTInterface.h:40
A3PE
Definition:
A3PE.h:20
Proto40MHz_v1::m_phaser2
Phaser * m_phaser2
Definition:
Proto40MHz_v1.h:86
Object::setType
void setType(std::string type)
Definition:
Object.h:52
UsbI2cBus
Definition:
UsbI2cBus.h:16
Attrib::ELEMENT
Definition:
Attrib.h:36
Proto40MHz_v1::m_usb
UsbFTInterface * m_usb
Definition:
Proto40MHz_v1.h:81
IOobject::setAddress
void setAddress(U32 address)
Definition:
IOobject.h:84
UsbSpiBus
Definition:
UsbSpiBus.h:17
Attrib::HARDWARE
Definition:
Attrib.h:37
Register
Definition:
Register.h:16
Proto40MHz_v1::m_a3pe
A3PE * m_a3pe
Definition:
Proto40MHz_v1.h:88
Proto40MHz_v1::~Proto40MHz_v1
virtual ~Proto40MHz_v1()
Destructor.
Definition:
Proto40MHz_v1.cpp:62
Hierarchy::addChild
virtual void addChild(Hierarchy *element)
Definition:
Hierarchy.cpp:83
Proto40MHz_v1::m_usbi2c
UsbI2cBus * m_usbi2c
Definition:
Proto40MHz_v1.h:82
Proto40MHz_v1::m_usbspi
UsbSpiBus * m_usbspi
Definition:
Proto40MHz_v1.h:83
Proto40MHz_v1::Proto40MHz_v1
Proto40MHz_v1()
Standard constructor.
Definition:
Proto40MHz_v1.cpp:17
Proto40MHz_v1::m_phaser1
Phaser * m_phaser1
Definition:
Proto40MHz_v1.h:85
IOdata::defDataU8
void defDataU8(unsigned long size)
Definition:
IOdata.h:179
IOobject::io
IOdata * io()
Definition:
IOobject.h:66
Generated by
1.8.13