First of all, make sure the Web Server in AbelCam is configured, running and accessible. Refer to the AbelCam documentation if you are not sure how to do this. To confirm that the Web Server is set up right, point your browser at hostname:port/index.html (where hostname is your machine's network name and port is the Server Port you set in AbelCam). If the Web Server is working you will see an AbelCam page.
If you plan to start out by using the included sample web pages to test (recommended) you should set your card's jumpers to Address 0 (SK-5 and SK-6 both jumpered). Plug the card into a USB port and make sure it is recognized by Windows. The Out 8 LED will flash a few times and then go off if Windows recognized the card properly. Then start the plugin by clicking Activate on the AbelCam plugins dialog. Next, click Configure and then check the Enable Card box in the configuration dialog.
To control and monitor your K8055 card using the included sample web page, simply point your web browser at: hostname:port/K8055/K8055_sample.html Or, if you use the webcam pages that come with AbelCam you can just open your webcam home page and click the Plugins button at the top.
Some knowledge of HTML is required. Use the included sample pages K8055_sample.html and status_sample.html as a starting point, and take a minute to read the extensive comments contained in each of those files.
In order to be served properly, you custom pages must be located in the same directory as the sample pages. This directory (normally C:\Program Files\AbelCam\Plugin\Web\K8055Plugin) functions as the "web root" for this plugin. The URL for a custom page named "mypage.html" will be server:port/K8055/mypage.html
Displaying Card Data On A Web Page: K8055 data is placed in a page by using special HTML "Include tags". Include tags look a bit like Comment tags, but they contain information that specifies the K8055 data item you want to display. When the page is served, the plugin replaces the Include tags with the actual live data items they specify.
Include tags look like this: <!--#XYYZ --> where X specifies the K8055 card address, YY specifies the type of data, and Z specifies which data item you want. Note the space directly after Z - it is required, not optional. Valid value range for card address X is 0 - 3. Valid values for data type Y are: DI (digital input), AI (analog input), CT (counter), DO (digital output) and AO (analog output). Valid values for data item Z are 0 - 5 (for digital inputs), 0 - 8 (for digital outputs) and 0 - 2 (for analog inputs & outputs, and counters).
For example: <!--#0DI4 --> will display the value of Digital Input 4 on Card 0. A complete list of all supported Include tags can be downloaded HERE.
Controlling Cards From A Web Page: Cards are controlled by passing arguments in a URL, much like calling a CGI script. There are two basic methods of doing this:
Method 1: hostname:port/K8055/mypage.html?CARD=0&DO=3&VAL=1 will turn on Digital Output 3 on Card 0 and then return a page named "mypage.html".
Method 2: hostname:port/K8055/?CARD=0&DO=3&VAL=1 will turn on Digital Output 3 on Card 0 and then return a tiny internal HTML page that simply says "Success" or "Error".
The general format for passing arguments is always: ?CARD=X&YY=Z&VAL=V where X specifies the K8055 card address and YY specifies the type of output to operate on (DO for digital output, AO for analog output, CR to reset a counter). Z specifies which output to operate on (0 - 8 for digital outputs, 0 - 2 for analog outputs and counters). V is the value to set the output to. Valid V values are 0 & 1 for digital outputs and 0 - 255 for analog outputs. V is not required for couter reset since counters can only reset to zero.
For example: ?CARD=0&DO=8&VAL=1 turns on Digital Output 8 on Card 0, and ?CARD=0&DO=8&VAL=0 turns it off. ?CARD=1&AO=1&VAL=127 sets analog output 1 on Card 1 to 127 (2.5 volts). ?CARD=0&CR=2 resets Counter 2 on Card 0. Refer to the comments and code in K8055_sample.html for more examples.