Skip to content
Snippets Groups Projects
Commit 8693ab75 authored by Giacomo Strangolino's avatar Giacomo Strangolino
Browse files

initial commit

parents
No related branches found
No related tags found
No related merge requests found
release_01: first release of the project "acdc-delay".
README 0 → 100644
This is acdc-delay README file.
DEPENDENCIES:
Qt version >= 4.8
Qwt version 6
QTango version 6
SPECIAL REQUIREMENTS:
none
Tango devices used
------------------
TANGO HOST:
export TANGO_HOST=srv-tango-srf:20000
DEVICES:
Building
--------
qmake
make
Main customer
-------------
Errors & Troubleshooting
------------------------
If you experience problems, please contact:
Giacomo <giacomo.strangolino@elettra.eu>
Thank you.
Sincrotrone Trieste s.c.p.a - ELETTRA Laboratory - Controls Group
isEmpty(CUMBIA_ROOT) {
CUMBIA_ROOT=/usr/local/cumbia-libs
}
include($${CUMBIA_ROOT}/include/quapps/quapps.pri)
# CONFIG += debug | release
DEFINES += QT_NO_DEBUG_OUTPUT
# RESOURCES +=
SOURCES += src/main.cpp \
src/acdc-delay.cpp
HEADERS += src/acdc-delay.h
# cuuimake runs uic
# FORMS = src/acdc-delay.ui
# but we need to include ui_xxxx.h file amongst the headers
# in order to be recompiled when it changes
#
HEADERS += \
ui/ui_acdc-delay.h
# - ui: where to find cuuimake ui_*.h files
# since FORMS is not used
# - src: where to find headers included by
# ui_*.h (e.g. for custom widget promoted
# from the Qt designer)
#
INCLUDEPATH += ui src
TARGET = acdc-delay
!wasm-emscripten {
TARGET = bin/$${TARGET}
} else {
TARGET = wasm/$${TARGET}
}
#
# make install works if INSTALL_DIR is given to qmake
#
!isEmpty(INSTALL_DIR) {
wasm-emscripten {
inst.files = wasm/*
} else {
inst.files = $${TARGET}
}
inst.path = $${INSTALL_DIR}
INSTALLS += inst
message("-")
message("INSTALLATION")
message(" execute `make install` to install 'acdc-delay' under $${INSTALL_DIR} ")
message("-")
} else {
message("-")
message("INSTALLATION")
message(" call qmake INSTALL_DIR=/usr/local/bin to install acdc-delay later with `make install` ")
message("-")
}
# unix:LIBS += -L. -lmylib
# unix:INCLUDEPATH += . ../../src
message("-")
message("NOTE")
message("You need to run cuuimake in order to build the project")
message("-")
message(" cuuimake --show-config to see cuuimake configuration options")
message(" cuuimake --configure to configure cuuimake")
message(" cuuimake -jN to execute cuuimake and then make -jN")
message(" cuuimake --make to run cuuimake and then make")
message("-")
#include "acdc-delay.h"
#include "ui_acdc-delay.h"
// cumbia
#include <cumbiapool.h>
#include <cuserviceprovider.h>
#include <cumacros.h>
#include <quapps.h>
// cumbia
Acdcdelay::Acdcdelay(CumbiaPool *cumbia_pool, QWidget *parent) :
QWidget(parent)
{
// cumbia
CuModuleLoader mloader(cumbia_pool, &m_ctrl_factory_pool, &m_log_impl);
cu_pool = cumbia_pool;
ui = new Ui::Acdcdelay;
ui->setupUi(this, cu_pool, m_ctrl_factory_pool);
// mloader.modules() to get the list of loaded modules
// cumbia
}
Acdcdelay::~Acdcdelay()
{
delete ui;
}
#ifndef Acdcdelay_H
#define Acdcdelay_H
#include <QWidget>
// cumbia
#include <qulogimpl.h>
#include <cucontrolsfactorypool.h>
class CumbiaPool;
// cumbia
namespace Ui {
class Acdcdelay;
}
class Acdcdelay : public QWidget
{
Q_OBJECT
public:
explicit Acdcdelay(CumbiaPool *cu_p, QWidget *parent = 0);
~Acdcdelay();
private:
Ui::Acdcdelay *ui;
// cumbia
CumbiaPool *cu_pool;
QuLogImpl m_log_impl;
CuControlsFactoryPool m_ctrl_factory_pool;
// cumbia
};
#endif // Acdcdelay_H
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>Acdcdelay</class>
<widget class="QWidget" name="Acdcdelay">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>303</width>
<height>182</height>
</rect>
</property>
<property name="windowTitle">
<string>Acdcdelay</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="QTabWidget" name="tabWidget">
<property name="currentIndex">
<number>0</number>
</property>
<widget class="QWidget" name="tab">
<attribute name="title">
<string>Operations</string>
</attribute>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Delay</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QuInputOutput" name="quInputOutput">
<property name="source">
<string>$1/Delay</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_2">
<property name="text">
<string>M6</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QuLabel" name="quLabel">
<property name="source">
<string>$1/M6</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>M7</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QuLabel" name="quLabel_2">
<property name="source">
<string>$1/M7</string>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_2">
<attribute name="title">
<string>Expert</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Zero Delay Position [M6]</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QuLabel" name="quLabel_3">
<property name="source">
<string>$1/ZeroDelayPosition</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Zero Delay Position [M7]</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QuLabel" name="quLabel_4">
<property name="source">
<string>$1/ZeroDelayPosition</string>
</property>
</widget>
</item>
<item row="2" column="1">
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>56</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</widget>
</item>
</layout>
</widget>
<layoutdefault spacing="6" margin="11"/>
<customwidgets>
<customwidget>
<class>QuLabel</class>
<extends>QLabel</extends>
<header>qulabel.h</header>
</customwidget>
<customwidget>
<class>QuInputOutput</class>
<extends>QFrame</extends>
<header>quinputoutput.h</header>
</customwidget>
</customwidgets>
<resources/>
<connections/>
</ui>
#include <quapplication.h>
#include "acdc-delay.h"
// cumbia
#include <cumbiapool.h>
#include <cuthreadfactoryimpl.h>
#include <qthreadseventbridgefactory.h>
// cumbia
#define VERSION "1.0"
int main(int argc, char *argv[])
{
QuApplication qu_app( argc, argv );
qu_app.setOrganizationName("Elettra");
qu_app.setApplicationName("Acdcdelay");
QString version(VERSION);
qu_app.setApplicationVersion(version);
qu_app.setProperty("author", "Giacomo");
qu_app.setProperty("mail", "giacomo.strangolino@elettra.eu");
qu_app.setProperty("phone", "375 8073");
qu_app.setProperty("office", "T2PT025");
qu_app.setProperty("hwReferent", "$HW_REFERENT$"); /* name of the referent that provides the device server */
CumbiaPool *cu_p = new CumbiaPool();
Acdcdelay *w = new Acdcdelay(cu_p, NULL);
w->show();
// exec application loop
int ret = qu_app.exec();
// delete resources and return
delete w;
for(std::string n : cu_p->names())
if(cu_p->get(n))
delete cu_p->get(n);
return ret;
}
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment