
Page : 19
Power up
Start
addressing
Start
message
Instrument
address
Polarity
Overload
Character to
be placed on
digit MSB
Character to
be placed on
digit LSB
Strobe
character
0D hex or 13 d
End of
message
XOFF
XON
Address
Polarity
6th digit
5th digit
4th digit
3rd digit
2nd digit
1st digit
STROBE
XOFF
ESC : Resets display to its power-on condition. Has priority
over any other character.
Address : Configured on the switch selector S4 (+30 hex).
All the units with the address, "0" (ASCII 30 hex),
will display all data, including the address code
sent, and this address will cause any unit to
receive data.
Polarity : The middle bar is light-up.
Overload : Led located over the polarity bar is light-up.
10.3.- STROBE OPERATING MODE USING XON/XOFF, PROGRAMME EXAMPLE
Next message
/* =============OMEGA Engineering Inc.==============
/* Demo programm for series LDP-XX-S connected to a PC */
/* Comunication from an IBM compatible computer in Shift
operating mode using XON-STROBE-XOFF */
/* In Turbo "C++", Borland Version 1.01 */
/* Fema Version 01, realized on Dec 1th of 1997 */
/* mode strobe*/
#include<bios.h> /*
#include<conio.h>
#include<stdio.h>
#define COM1 0 /*
#define COM2 1 /*
#define TRUE 1
#define FALSE 0
#define EVEN 0x18
#define ODD 0x10
#define NONE 0x0
#define BIT7 0x2
#define BIT8 0x3
#define STOP1 0x0
#define STOP2 0x4
#define BAUD300 0x40
#define BAUD600 0x60
#define BAUD1200 0x80
#define BAUD2400 0xA0
#define BAUD4800 0xC0
#define BAUD9600 0xE0
int main(void)
{
int count,DONE=FALSE; /*counter & end loop condition
char dat1,men1[25]; /*temporary data and string*/
ciscr(); /*Clear Screen*/
/*__________Initializing Host port________________*/
bioscomp(0,(BAUD9600 | BIT8 | NONE | STOP1),COM2); /*open COM2 port*/
/*__________Initializing instrument_______________*/
bioscom(1,'\x19', COM1); /*Start addressing (XOFF)*/
*/__________Main loop of the programm_______________*/
while(!DONE){ /*start transmmision loop*/
/*__________Read message introduced using the keyboard________________*/
count=0 /*reading the string introduced using the keyboard*/
gotoxy(10,3);
printf("enter the mesage (0-7 characters)"); /*Until press Enter key*/
do{
dat1=getche();
Men1[count]=dat1;
count++;
}while (dat1!='\x0d);
men1[count]='\r';
/*_________Send the message and present it on the screen_____________*/
cirscr();
{
bioscom(1,'\x11',COM2); /*Send XON*/
gotoxy(12.10);
printf("XON");
bioscom(1,'0' , COM2); /* Send address*/
printf("0");
count=0
/*_______Message Loop Transmmision_________*/
while (men1[count]!='\r'){
/*Covert to capital letters to see the small letters*/
if (men1[count]<123 & men1[count]>96) men1[count]=men1[count]-32;
*/Print on the screen and send every message character to the port until carriage return*/
printf("%c", men1[count]);
bioscom(1,men1[count],COM2);
count++;
}
bioscom(1,'\x0D',COM2); /*Send 0D hex STROBE*/
printf("STROBE");
bioscom(1,'\x13',COM2); /*Send XON, end of message*/
printf(XOFF);
}
}
return 0;
}
' =============OMEGA Engineering Inc.==============
' Demo programm for series LDP-XX-S connected to a PC
' Example of comunication in Strobe operating mode using XON-STROBE-XOFF
' Realizer for Microsoft Qbasic, VERSION 1.1
' Fema Version 01, realized on Dec 1th of 1997
OPEN "COM2:9600,N,8,1,CD0,CS0,DS0,OP0,RS,TB20,RB20" FOR RANDOM AS #1
'Open port 2 without protocols, 9600, 8, none, buffers for 20 characters'
CLS
PRINT#1,CHR$(19)
DO
LOCATE 10,5
INPUT "Enter message";A$
A$ = UCASE$(A$)
'Conversion to capital letters'
CLS
LOCATE 12,5
PRINT "XON 0" + A$ + " (STROBE) XOFF"
'Print string on screen'
PRINT #1, CHR$(17) + "0" +A$ + CHR$(13) + CHR$(19); 'Send string to the port'
LOOP WHILE NOT (A$="")
'Until empty string is entered'