|
Veethree D7 SDK
|
This application will demonstrate integrating the D7 SDK in a QML project that will run both on the host and the target device. It displays resistance readings from the built-in analog sensors. Each sensor is set up as a 1-wire resistance sensor.
For more information about all the available hardware interfaces and their configurations, please refer to the Hardware interfaces page.
For this example, you will need to have the Qt libraries installed separately from the D7 SDK. Please refer to the guide for installing Qt.
While running on the host, the sensor readings are mocked, since there are no sensors that can be used there. They will all read 249 Ohms.
On the target device however, you can connect resistances between AGND (pin 4, 23-way AMPSEAL connector) and each one of pins 4, 5, 6, 15, 16, 17 in the AMPSEAL 35-way connector so that you can see the the device's resistance sensors in action.
Similar to the previous example, you will need to open a new terminal, navigate to the D7 SDK installation directory and activate the development environment.
On Windows, open a new CMD window, navigate to the D7 SDK installation directory and run:
Assuming the D7 is connected to the network via ethernet and its IP address is known (see Connecting via SSH), run the following command to transfer the executable:
Once the transfer is complete, ssh into the device.
If the application was built on Windows, you will also need to mark the application as executable:
You should now be able to run the application and, if you have connected any resistances as described in the test harness section, their values should be displayed on screen now.
As before, if you are on Linux, in a new terminal you will need to source the environment script with this command:
Then navigate to the source directory and create the build directory:
You will then need to configure and compile the project.
On Windows, open a new CMD window, navigate to the D7 SDK installation directory and run:
The previous commands should run without any errors and produce output similar to the following.
You should now be able to run qml-analog-app from the build directory and it should look like this:
In this page we have described configuring, building and running a QML application for both the host and the target device, as well as attaching resistances to the sensor pins in the AMPSEAL 35-way connector.
There are other example applications that explore other hardware interfaces, such as the 4-20mA interface or the Digital In/Out interface.
Installing Qt libraries and Qt Creator
If you plan to use Qt Creator for development, the next step is setting up Qt Creator.
Otherwise, you can skip to the Software Updates section of this guide.