Materials Required
Putting the required script on the Arduino
Download and install the Arduino IDE from https://www.arduino.cc/en/software
Connect the arduino using the USB cable to the computer
Open the IDE and make sure your device is connected. Your board should appear near the red line
Locate the Arduino liquid crystal ino File from the support folder ArduinoLiquidCrystal\TCPReadWriteAllPinOutput_NoDigiRead_FastPWM.ino
Copy the file to your local drive as you want to make edits
Open the file in the IDE and edit the following -
You can find the MAC address on the arduino itself. It would be on a label
For the IP Address
Make sure that the Arduino is connected to your PC using an Ethernet Cable
Navigate to Control Panel > Network and Internet > Network and Sharing Center
Click on the ethernet connection of your Arduino device
Got to properties
Select Internet protocol Version 4 (TCP/IP) and click properties or double click and change the settings to a an ip address that you can use (Similar to setting up a GigE camera, you may refer to the drop net schedule as well for allowable IP Addresses). Click okay
In the script, go to the IP Address section and input the IP Address you can assign to the device. (For example the last digit in the IP address maybe be one more than the Ethernet Port address/Gateway Address)
Now Press Verify and Upload buttons on the IDE to put the script in the memory of the arduino device
The serial monitor should read
You can now disconnect the USB Cable from the arduino and the computer.
The default calibration file is for device - LCC1622
You can get the curve/data from the manufacturers website. It then needs to be formatted into the following way as a csv file, with voltage values on the left and transmission% values on the right.
You can then put the file in the active directory
Setup a new device in the DB Manager by Navigating to Device Ops > Device > Device(Add)
Select the DeviceType as ArduinoLiquidCrystal and fill out the rest of the details
Navigate to Device Ops > Device variable Ops > Device Variables (Add/Edit/Delete)
Navigate to the correct Devicetype and Device
Set the following variable
ResourceName - Set as the IP Address of the arduino
TransmissionValueTablePath - Path to the Calibration csv you had created. Leave it as is if using LCC1622.
Make sure local port is set as 8888