|
DAQFactory |
Top Previous |
|
DAQFactory is a data acquisition application that can connect to a wide variety of hardware devices, including PLCs and RTUs, collect the data and send it to DAQConnect. DAQFactory Express is available for free from www.azeotech.com. Simply download the DAQFactory trial and when the trial expires, it will revert to a free version that you can continue to use. The full paid versions of DAQFactory offer many more features such as automated control, advanced screens, alarming, and much more. DAQFactory release 5.80 and newer supports direct, easy connectivity to the DAQConnect service to allow you to view your data live from a web browser without having to worry about your firewall or router settings, static IPs or any thing else related to IT really. You don't need an external website either, as would be required using FTP. In 5.86 the connection method between DAQFactory and DAQConnect changed to make things easier. Older documents will still work, however, the user interface has changed. This documentation applies to the new user interface: Sending data to DAQConnect: You can easily start connecting to DAQConnect by going to Real-time Web -> Connect... in the DAQFactory main menu. The first time you do this in a session, you will be prompted to login or create an account. If you've already created a DAQConnect account, click login, otherwise, you can create a free DAQConnect account right from this window. If you haven't created any data sources yet, after logging in or creating an account you will go directly to the page for creating new data sources. A data source is a group of channels within DAQConnect. Typically you'll create a data source for each location sending data to DAQConnect, but you could also use separate data sources for separate applications running on a single computer. Give your data source a name, which like all DAQFactory names must start with a letter and contain only letters, numbers or the underscore. Once the data source is created, your DAQFactory document will be linked to it. Note: if you are using a proxy to get to the Internet or a dedicated instance of DAQConnect (i.e. you access DAQConnect through a URL other than www.daqconnect.com, please see the Settings section below before you you do Connect... To then send data to DAQConnect, you simply mark the desired channels for sending: 1) Go to the channel table by clicking CHANNELS in the workspace. Towards the right of the table you'll see three columns related to DAQConnect: DAQConn?, determines if the channel data is being sent to DAQConnect. Check this box to mark the channel. DC Hst:, determines how many data points are kept on the DAQConnect server for historical viewing. This number is limited by the plan you select. You can enter -1 to have DAQConnect automatically apply an even amount to all of your tags based on your plan, or you can specify exact amounts for each channel allowing you to have more data retained for certain channels. DC Intvl: determines how often the channel data is sent up to DAQConnect. This is in data points. So, if you are taking data once a second and you put a value of 10 in this column, every 10th data point is sent. This is to allow you to take data at a faster rate than it is sent to DAQConnect. Please note that DAQConnect may limit the spacing of data points being sent to it. If you need to send high speed data such as streamed data, you should contact DAQConnect to arrange for a special plan. Once you click Apply in the channel table, DAQFactory will start sending the data to DAQConnect. You can go to DAQConnect, and in the Basics menu see your tags appear. You can then start creating your screens within DAQConnect to view your data from any browser. To change the data source you are sending data to, you can once again go to Real-time Web -> Connect.... You will be taken to a screen listing all your data sources on your account, highlighting the one you are currently connected to. You can then select a different data source. Settings: From Real-time Web -> Settings... you can adjust a couple settings for your DAQConnect connection: Display Detailed Status: checking this box will display detailed status information about your DAQConnect connection in the Command / Alert window. This is quite useful when you are first establishing a connection. This setting is not saved with the document as its designed primarily for debugging. Host: this setting should only be changed from www.daqconnect.com if you are using a proxy server or a dedicated DAQConnect instance. If using a proxy, set this value to the IP of the proxy. If using a dedicated instance (and no proxy), set this to the URL of your dedicated instance. Host Name: this setting should only be changed from www.daqconnect.com if you are using a dedicated DAQConnect instance. If so, you should set this to the URL of the dedicated instance. Control from DAQConnect: DAQConnect can also send commands back to your DAQFactory application. To ensure that the commands are processed the way YOU want them to be, there is no automatic command processing. Instead, when a command comes in from DAQConnect, the system event "OnDCSet" is triggered, passing in the two values from DAQConnect: the key and the value. To allow a remote user of DAQConnect to change values in your DAQFactory installation: 1) in DAQConnect, you will use the system.sendCommand() function (or other possible output functions) in an Click or other event. These functions will take a key and a value. The key is a string and often contains the name of the connector with a dot after it, such as "MyConnector.MyKey". The value can either be a string or number, and may be part of the function. Please review the DAQConnect help for more information. 2) in DAQFactory, create a Sequence called "OnDCSet". This sequence will be run whenever a new command comes in from DAQConnect. Commands from DAQConnect only come in when DAQFactory sends data to DAQConnect. So, if your channels are updating every 60 seconds, you can only possibly get commands from DAQConnect every 60 seconds. In these situations, you might consider using a Test channel or similar to ping the server more rapidly. 3) When the sequence is called, two local variables are created: "key" and "val". What these mean is largely up to your design. If, for example, you were directly controlling a digital output, "key" might be the name of a channel, and val either 0 or 1. In this case, you might use this script: if (key == "mydigout") mydigout = val endif If you wanted to do more channels, you'd just repeat, or use a switch/case instead. Now some important details:
private nVal = strtodouble(val) // convert to a number if (key == "myout") if ((nVal > 20) && (nVal < 40)) myout = nVal endif endif
Note that we converted the string "val" to a numeric "nVal" before doing comparisons. > and < and other operators will work on strings, but work in a different way ("2" is actually > "10" for example, even though 2 < 10)
NOTE: if you lose your Internet connection or otherwise have troubles sending data to DAQConnect, the data will queue up until a connection can be reestablished. There is a hard limit of 1,000 data points per packet across all tags to ensure you don't run out of RAM. If more than 1,000 data points queue up while waiting for a connection, the oldest data is lost.
|