Here's an example of how you can implement a multi-process plugin system for Linux on Golang
- core_module.go - Core module of plugin system.
- process_plugin.go - Plugin module.
- watchdog.go - Watchdog module.
| #include "Control_ST_L6258.h" | |
| /****************************************************************************** | |
| * @file Control_ST_L625.c | |
| * @author Molotaliev A.O([email protected]) | |
| * @version V 0.5.1 | |
| * @date 10-May-2016 | |
| * @brief This Driver for H-Bridge ST L6258(LGPL) | |
| * | |
| * | |
| ****************************************************************************/ |
| /* | |
| * GpioControler.cpp | |
| * | |
| * Created on: Sep 30, 2019 | |
| * Author: M0nteCarl0 | |
| */ | |
| #include "GpioControler.h" | |
| GpioControler::GpioControler():MaxCountBank(0),MaxCountLinesPerBank(0),Iter(nullptr),Chip(nullptr){ |
| #include "FM25.h" | |
| /****************************************************************************** | |
| * @file FM25.c | |
| * @author Molotaliev A.O([email protected]) | |
| * @version V 0.0.1 | |
| * @date 1-october-2016 | |
| * @brief This Driver for RAMTRON FM2504 F-RAM Memory | |
| * | |
| * | |
| ****************************************************************************/ |
| include "DAC.h" | |
| /******************************************************************************/ | |
| void InitDAC(void) | |
| { | |
| RCC_APB1PeriphClockCmd(RCC_APB1Periph_SPI2,ENABLE); | |
| RCC_AHB1PeriphClockCmd(RCC_AHB1Periph_GPIOB,ENABLE); | |
| RCC_AHB1PeriphClockCmd(CS_RCC,ENABLE); | |
| GPIO_PinAFConfig(GPIOB, GPIO_PinSource15, GPIO_AF_SPI2); |
| #include "CriticalSection.h" | |
| CriticalSection::CriticalSection() { | |
| Init(); | |
| } | |
| CriticalSection::CriticalSection(const char * Decription) { | |
| Init(); | |
| _Description = Decription; | |
| } |
| import sys | |
| import time | |
| import numpy as np | |
| from matplotlib.backends.qt_compat import QtWidgets | |
| from matplotlib.backends.backend_qtagg import ( | |
| FigureCanvas, NavigationToolbar2QT as NavigationToolbar) | |
| from matplotlib.figure import Figure | |
| import trsfile as trs | |
| from trsfile import trs_open, Trace, SampleCoding, TracePadding, Header |
Here's an example of how you can implement a multi-process plugin system for Linux on Golang
| #include <iostream> | |
| #include <boost/asio.hpp> | |
| #include <boost/beast.hpp> | |
| namespace asio = boost::asio; | |
| namespace beast = boost::beast; | |
| using tcp = asio::ip::tcp; | |
| int main() | |
| { |
| #include <iostream> | |
| #include <cpprest/http_client.h> | |
| #include <cpprest/json.h> | |
| using namespace web; | |
| using namespace web::http; | |
| using namespace web::http::client; | |
| int main() | |
| { |
| #include <iostream> | |
| #include <boost/asio.hpp> | |
| #include <boost/thread.hpp> | |
| using boost::asio::ip::tcp; | |
| void session(tcp::socket socket) | |
| { | |
| try | |
| { |