Last change
on this file since 337 was 324, checked in by Sanahuja Guillaume, 5 years ago |
removing opencv dependency
|
File size:
1.1 KB
|
Line | |
---|
1 | // %flair:license{
|
---|
2 | // This file is part of the Flair framework distributed under the
|
---|
3 | // CECILL-C License, Version 1.0.
|
---|
4 | // %flair:license}
|
---|
5 | // created: 2014/02/07
|
---|
6 | // filename: SimuUs.cpp
|
---|
7 | //
|
---|
8 | // author: Guillaume Sanahuja
|
---|
9 | // Copyright Heudiasyc UMR UTC/CNRS 7253
|
---|
10 | //
|
---|
11 | // version: $Id: $
|
---|
12 | //
|
---|
13 | // purpose: Class for a simulation us
|
---|
14 | //
|
---|
15 | //
|
---|
16 | /*********************************************************************/
|
---|
17 | #include "SimuUs.h"
|
---|
18 | #include <SharedMem.h>
|
---|
19 | #include <sstream>
|
---|
20 |
|
---|
21 | using std::string;
|
---|
22 | using std::ostringstream;
|
---|
23 | using namespace flair::core;
|
---|
24 |
|
---|
25 | namespace flair {
|
---|
26 | namespace sensor {
|
---|
27 |
|
---|
28 | SimuUs::SimuUs(const IODevice *parent, string name,uint32_t modelId,uint32_t deviceId)
|
---|
29 | : IODevice(parent,name) {
|
---|
30 |
|
---|
31 | shmem = new SharedMem(this, ShMemName(modelId, deviceId), sizeof(float));
|
---|
32 |
|
---|
33 | SetIsReady(true);
|
---|
34 | }
|
---|
35 |
|
---|
36 | SimuUs::~SimuUs() {
|
---|
37 | }
|
---|
38 |
|
---|
39 | string SimuUs::ShMemName(uint32_t modelId,uint32_t deviceId) {
|
---|
40 | ostringstream dev_name;
|
---|
41 | dev_name << "simu" << modelId << "_us_" << deviceId;
|
---|
42 | return dev_name.str().c_str();
|
---|
43 | }
|
---|
44 |
|
---|
45 |
|
---|
46 | } // end namespace sensor
|
---|
47 | } // end namespace flair
|
---|
Note:
See
TracBrowser
for help on using the repository browser.