Roomba App  1.0
MainWindow Class Reference

The MainWindow class. More...

#include <mainwindow.hh>

Inheritance diagram for MainWindow:
Collaboration diagram for MainWindow:

Public Member Functions

 MainWindow (QWidget *parent=nullptr)
 Constrict a new MainWindow object. More...
 
 ~MainWindow ()
 Delete MainWindow object. More...
 

Protected Member Functions

void closeEvent (QCloseEvent *event) override
 Reimplemented to savely close reading thread. More...
 

Private Slots

void on_actionClose_triggered ()
 Close application. More...
 
void on_actionDisconnect_triggered ()
 Disconnect from serial device. More...
 
void on_actionSearch_triggered ()
 Search serial devices. More...
 
void connectSerialDevice (const QString &actionName)
 Connect to serial device. More...
 
void serialTimeout ()
 Slot to handle serial timeout which signals to update data from serial. More...
 
void showErrorMessage (const QString &message)
 Show error message as status bar message. More...
 
void addMessageToLogs (const QString &message)
 Add message to log widget. More...
 
void addValueSpeedL (const QString &message)
 addValueVelocityL More...
 
void addValueSpeedR (const QString &message)
 addValueVelocityR More...
 
void addValueGSpeedL (const QString &message)
 addValueSetSpeedL More...
 
void addValueGSpeedR (const QString &message)
 addValueSetSpeedR More...
 
void addValueAccelerationL (const QString &message)
 addValueAccelL More...
 
void addValueAccelerationR (const QString &message)
 addValueAccelR More...
 
void addValueBaterry (const int message)
 addValueBaterry More...
 

Private Member Functions

void addDropShadow (QGroupBox *group, int xOffset, int yOffset, int radius)
 addDropShadow More...
 

Private Attributes

Ui::MainWindow * ui
 Pointer to all ui widgets. More...
 
Communication_communication
 Communication handle. More...
 
QTimer _serialTimer
 Serial communication timer to get new frames. More...
 
FrameThread_frameThread
 Serial communication thread handle. More...
 
Parser_parser
 _parser More...
 

Detailed Description

Definition at line 38 of file mainwindow.hh.

Constructor & Destructor Documentation

◆ MainWindow()

MainWindow::MainWindow ( QWidget *  parent = nullptr)
Parameters
[in]parentPointer to parent QWidget object

Definition at line 27 of file mainwindow.cpp.

Here is the call graph for this function:

◆ ~MainWindow()

MainWindow::~MainWindow ( )

Dealocate memory from ui pointer

Definition at line 67 of file mainwindow.cpp.

Member Function Documentation

◆ addDropShadow()

void MainWindow::addDropShadow ( QGroupBox *  group,
int  xOffset,
int  yOffset,
int  radius 
)
private
Parameters
[in]groupGroup Box handle to which drop shaddow add
[in]xOffsetShadow offset on x axis
[in]yOffsetShadow offset on y axis
[in]radiusShadow radius

Definition at line 172 of file mainwindow.cpp.

Here is the caller graph for this function:

◆ addMessageToLogs

void MainWindow::addMessageToLogs ( const QString &  message)
privateslot
Parameters
[in]messageInfo message string

Definition at line 165 of file mainwindow.cpp.

Here is the caller graph for this function:

◆ addValueAccelerationL

void MainWindow::addValueAccelerationL ( const QString &  message)
privateslot
Parameters
message

Definition at line 190 of file mainwindow.cpp.

Here is the caller graph for this function:

◆ addValueAccelerationR

void MainWindow::addValueAccelerationR ( const QString &  message)
privateslot
Parameters
message

Definition at line 205 of file mainwindow.cpp.

Here is the caller graph for this function:

◆ addValueBaterry

void MainWindow::addValueBaterry ( const int  message)
privateslot
Parameters
message

Definition at line 210 of file mainwindow.cpp.

Here is the caller graph for this function:

◆ addValueGSpeedL

void MainWindow::addValueGSpeedL ( const QString &  message)
privateslot
Parameters
message

Definition at line 185 of file mainwindow.cpp.

Here is the caller graph for this function:

◆ addValueGSpeedR

void MainWindow::addValueGSpeedR ( const QString &  message)
privateslot
Parameters
message

Definition at line 200 of file mainwindow.cpp.

Here is the caller graph for this function:

◆ addValueSpeedL

void MainWindow::addValueSpeedL ( const QString &  message)
privateslot
Parameters
message

Definition at line 180 of file mainwindow.cpp.

Here is the caller graph for this function:

◆ addValueSpeedR

void MainWindow::addValueSpeedR ( const QString &  message)
privateslot
Parameters
message

Definition at line 195 of file mainwindow.cpp.

Here is the caller graph for this function:

◆ closeEvent()

void MainWindow::closeEvent ( QCloseEvent *  event)
overrideprotected
Parameters
event

Definition at line 72 of file mainwindow.cpp.

Here is the call graph for this function:

◆ connectSerialDevice

void MainWindow::connectSerialDevice ( const QString &  actionName)
privateslot
Parameters
[in]actionNameName of the action that have been clicked [Action name represents device name]

Definition at line 123 of file mainwindow.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ on_actionClose_triggered

void MainWindow::on_actionClose_triggered ( )
privateslot

Slot connected to actionClose which triger closing application

Definition at line 79 of file mainwindow.cpp.

Here is the call graph for this function:

◆ on_actionDisconnect_triggered

void MainWindow::on_actionDisconnect_triggered ( )
privateslot

Slot connected to actionDesconnect which triger disconnection from serial device

Definition at line 86 of file mainwindow.cpp.

Here is the call graph for this function:

◆ on_actionSearch_triggered

void MainWindow::on_actionSearch_triggered ( )
privateslot

Slot connected to actionSearch which trigger search of serial devices

Definition at line 101 of file mainwindow.cpp.

Here is the call graph for this function:

◆ serialTimeout

void MainWindow::serialTimeout ( )
privateslot

Definition at line 142 of file mainwindow.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ showErrorMessage

void MainWindow::showErrorMessage ( const QString &  message)
privateslot
Parameters
[in]messageError message string

Definition at line 160 of file mainwindow.cpp.

Here is the caller graph for this function:

Member Data Documentation

◆ _communication

Communication* MainWindow::_communication
private

Definition at line 164 of file mainwindow.hh.

◆ _frameThread

FrameThread* MainWindow::_frameThread
private

Definition at line 174 of file mainwindow.hh.

◆ _parser

Parser* MainWindow::_parser
private

Definition at line 179 of file mainwindow.hh.

◆ _serialTimer

QTimer MainWindow::_serialTimer
private

Definition at line 169 of file mainwindow.hh.

◆ ui

Ui::MainWindow* MainWindow::ui
private

Definition at line 150 of file mainwindow.hh.


The documentation for this class was generated from the following files: