beautypg.com

Red Lion GEMINI 33 User Manual

Page 22

background image

SENDING COMMANDS & DATA TO THE GEMINI 3300 (Cont’d)

VALUE

IDENTIFIER

DESCRIPTION

MNEMONIC

A (41H)

Preset 1

(PS1)

B (42H)

Preset 2

(PS2)

C (43H)

Batch Preset

(PSB)

D (44H)

Scale Factor

(SCF)

E (45H)

Process Count

(PRC)

F (46H)

Batch Count

(BAT)

G (47H)

Total Count

(TOT)

M (4DH)

Counter (s) selected in Code 61

N/A

The command string is constructed by using the above commands and value

identifiers, along with the data values that are required. Data values may or may

not contain the decimal point if a decimal point is programmed into the Gemini

3300. The Gemini 3300 will accept the decimal points, however, it does not

interpret them in any way. Leading zeros can be eliminated, however, all

trailing zeros must be present. For example, if a Scale Factor of 1.0000 is to be

sent, the data value can be transmitted as 1.0000 or 10000. If a “1” is

transmitted, the Scale Factor will be changed to 0.0001.

The Address command is used to allow a command to be directed to a

specific unit in the Serial Communications Loop. Whenever the unit address

is zero, transmission of the Address command is not required. This is done for

applications which do not require more than one Gemini. For applications

that require several units, it is recommended that each unit in the loop be

given a separate address. If they are given the same address, a command such

as the Transmit Value Command, will cause all the units to respond at the

same time, resulting in erroneous data.

The command string is constructed in a specific logical sequence. The

Gemini 3300 will not accept command strings that do not follow this

sequence. Only one operation can be performed per command string. Below

is the procedure to be used when constructing a command string.

1. If the Gemini 3300, to which the command is to be sent, is assigned an

address other than zero, the first two or three characters of the command

string must consist of the Address Command (N) and the address number of

the unit (1-15).

2. The next character(s) in the command string is the actual command that the

Gemini 3300 is to perform and the value identifier if it pertains to the

command. (A command such as the Transmit per Print Options, “P”,

command does not require a Value Identifier.)

3. If the change command is being used, the next characters in the command

string is the numerical data value.

4. The last character in the command string is the command terminator (*).

This character must be sent in order to tell the Geminis that the command

string is complete, so that they can begin processing the command.

Below are some typical examples of properly constructed command strings.

(EX. 1) Change Preset 1 on the Gemini 3300 with an address of 2 to 00123.4.

COMMAND STRING: N2VA1234*

(EX. 2) Have the Gemini 3300, with an address of 13, transmit the Batch

Count Value.

COMMAND STRING: N13TF*

As shown, all commands must be terminated with a “Command

Terminator” (* or 2AH). The Gemini 3300 will not process the command

until the terminator is sent. If illegal commands or characters are sent to the

Gemini 3300, they still would need to be terminated by an (*). If they are not

terminated, the next command will not be accepted.

When writing application programs in Basic, the transmission of spaces or

carriage return and line feed should be inhibited by using the semicolon

delimiter with the Print statement. The Gemini 3300 will not accept a carriage

return or line feed as valid characters.

When a “Change Value” command is sent to the Gemini 3300, a short

amount of time is required for the unit to process the data. This time increases

with the count rate. During this time, only one additional command may be sent

to the Gemini 3300. This may be done 80 msec after the transmission of the

“Change Value” command. After the second command has been transmitted,

the unit will ignore any further commands until 10 msec after both the “Change

Value” and second command have been processed. It is recommended that a

“Transmit Value” command follow a “Change Value” Command. If this is

done, the reception of the data can provide a timing reference for sending

another command and will insure that the change has occurred.

-20-