# NikonD3Client Console Application

## Introduction

The `nikonD3Client` is win32 console application which runs a very simple tcp client and a set of textual commands to interact with the `nikonD3Server` program. This program is intended to be an example for someone writing a more autonomous driver to interact with the `nikonD3Server`. A

## Program Usage

Typical usage of the program is as follows:

	nikonD3Client.exe <server ip> <server port>

Where `<server ip>` is an IPv4 address or dynamic name that can be resolved. The `<server port>` is an integer representing the tcp listening socket on the server side. 

### Runtime Commands

There are only 7 commands currently implemented, and are outlined in the code block below:

    -----------------------------------------------
    n      - Send NONE message to test communiation
    c[0,1] - Tell System to Connect
    a[0,1] - start acquisition 
    i[X]   - set interval to X milliseconds
    tc     - retrieve trigger count
    fc     - retrieve frame count
	x      - Exit program
	-----------------------------------------------

In the case there is a `[0,1]` annotation, 1 activates the property and 0 disables it. An `[X]` requires that the command be directly followed by an integer.

## Other Notes

As this is a sample program, the tcp client aspects of it are coded in a rather rudimentary way. If the server fails to respond to any command, the program will hang and you will have to escape out of it and reconnect. 

## Requirements

Compiling this program requires the use of Microsoft Visual Studio. Initial development was done under *MSVS 2012 for Desktop*. 

Runtime requirements for the executable are Windows 7 or newer.
