Skip to content
Snippets Groups Projects
Commit 970f4dd8 authored by Your Name's avatar Your Name
Browse files

still trouble in moernising

parent 76d50b4d
No related tags found
No related merge requests found
# Set the minimum version of cmake required to build this project
cmake_minimum_required(VERSION 2.6)
cmake_minimum_required(VERSION 3.13)
project(gnuplot)
subdirs(o_gnuplot)
subdirs(o_gnuplot_poi)
#subdirs(o_gnuplot_poi) // Need to be checked and documented
......@@ -3,11 +3,9 @@ cmake_minimum_required(VERSION 2.6)
project(o_gnuplot)
find_package(blc_channel REQUIRED)
find_package(blc_program REQUIRED)
find_package(blc REQUIRED)
add_definitions(${BL_DEFINITIONS} -std=c++14)
include_directories(${BL_INCLUDE_DIRS})
add_executable(o_gnuplot src/o_gnuplot.cpp src/history_graph.cpp src/graph.cpp )
target_link_libraries(o_gnuplot ${BL_LIBRARIES})
target_compile_features(o_gnuplot PRIVATE cxx_std_14)
target_link_libraries(o_gnuplot PRIVATE blc rt})
#include "blc_program.h"
#include "blc_text.h"
#include "graph.h"
#include <pthread.h>
#include <sys/time.h>
#include <unistd.h>
#include <string>
#include <unique>
using namespace std;
......@@ -20,7 +22,7 @@ typedef struct history:blc_array{
unsigned long initial_us;
}type_history;
type_history history;
unique_ptr<type_history> history;
pthread_mutex_t mutex=PTHREAD_MUTEX_INITIALIZER;
int k;
......@@ -197,7 +199,7 @@ void create_history_graph(deque <blc_channel> &inputs, char const *title, int hi
command.append(buffer);
}
history.init(input->type, input->format, 2, columns_nb, history_length);
history(input->type, input->format, {columns_nb, history_length});
history.sampling_period=sampling_period;
history.input=input;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment