EnOcean Link
1.14.0.0
Middleware to Connect EnOcean easily to other Projects
|
This Step by Step Guide will help you to get your first project to compile with your favourite IDE. The shown example use Visual Studio.
If you want to know more about CMAKE and the Usage please refer to https://cmake.org/. General usage of the cmake tools can be read here https://cmake.org/runningcmake/
Download the latest cmake release from https://cmake.org/download/ or install it using package manager tools. For example
This will download&install cmake, gcc and g++ for compiling eolink on a linux system.
Execute the cmake gui and select as path where the SourceCode is, the folder containing the EoLink SourceCode and the CMakeLists.txt
Use configure to select the generator you want to use (in our examples Visual Studio 2017)
After configuring you can generate the solution file (build files) for EoLink based on your generator.
Afterwards open the solution file and open the HelloWorld example.
Now you can open the HelloWorld.cpp, which implements a eoLink Receiver using the USB300, or you can test the application by pressing the run button(green arrow).
The first few lines set the serial Port to the rigth device.
The eoLink Header is included from the EOLink project, which contains the SourceCode of eoLink.
In the main function we first define an eoGateway and try to open a connection to our device
Now we can use an eoCommonCommand command to read the version and the application of the connected enoceanGateway Device
We use a variable recv to parse the RECEIVE_FLAGS from eoGateway::Receive(). We put the receive functionallity in an endless loop and if we've received a telegram, we print it out.
Pressing the green arrow you can run the Target.
Now you can continue with the Tutorials or you can read up about eoGateway and how to use it.