Документ взят из кэша поисковой машины. Адрес оригинального документа : http://www.spm.genebee.msu.ru/manual/en/node139.html
Дата изменения: Fri Feb 4 20:39:00 2005
Дата индексирования: Mon Oct 1 22:08:27 2012
Кодировка:
COM-port initialization file format next up previous contents index Russian
Next: Parameters of 3D Images Up: Scanning Probe Microscopy Image Previous: Temperature calibration file format   Contents   Index

COM-port initialization file format

This file is written in text format and consists from several sections. The order of this sections doesn't important. Every section starts with header like this --

[<section_name>]
and lasts until next section starts or until the end of file. Every section content several records. The record has this format --
<record_name>=<value>;

These sections should be described in the file: init, sample, var, var.scale (not nessesarly) , var.display (not nessesarly).

Variables are described in var section. Variable names can de substituted in the record values with $ sign. In the case when section var.scale is exist, in this section scale coefficients for conversion of variables values to numbers can be set. Then values, multiplied to these scale coefficients, will appear in a Parametres window of the client's software.

If the var.display section is exist, the alternate, more convenient variables names, can be set in the section. The section init have to contain following records:

Section sample should contain following records:

Communication with a port goes according to following scenario:

An example of initialization file listed below.


[init]
RdInterval=500;
RdTotConst=500;
RdTotMult=500;
Speed=1.0/(2.0e-6*$CCPR2*$TMRQuanta);
WrTotConst=0;
WrTotMult=0;
init=SETRTS,!100,CLRRTS,!100,0x74,$Uhv,0xf4,0x74,$Ud,0xfc;
init_read=6;

[sample]
hibyte=0xa6;
hibyte_offset=0;
hibyte_read=1;
init=0x30,$C_DvdReg,0x1c,$CCPR2High,0x1b,$CCPR2Low,0x29,$TMRQuanta,0xf2;
init_read=9;
lobyte=0x81;
lobyte_offset=0;
lobyte_read=1;

[var]
CCPR2(Cntr),int,0,0xffff=256;
CCPR2High,int,0,255,,#CCPR2 >> 8=#CCPR2 >> 8;
CCPR2Low,int,0,255,,#CCPR2 & 0xff=#CCPR2 & 0xff;
C_DvdReg(Div),int,0,255=0;
TMRQuanta(Cntr T, ms),int,0,255,0.05*##=40;
Ud(Ud, V),int,0,255=20;
Uhv(Uhv, V),int,0,255=200;
sample_freq,double,,,,,1.0/(2.0e-6*#CCPR2*#TMRQuanta)=1;


next up previous contents index Russian
Next: Parameters of 3D Images Up: Scanning Probe Microscopy Image Previous: Temperature calibration file format   Contents   Index
Filonov 2005-02-04