C300 Transmission protocol for C300 firmware 5.x.x
C300B transmission protocol 2017-06-12.doc
9/22
4. Setting commands for calibrator's functions
4.1. Setting harmonics
Function
Prepare calibrator to receive block of data
Command
BD_<VAL_INT>[CR][LF]
Description
Prepare calibrator to receive <VAL_INT> bytes of data.
Command is used to transmit data (table) of harmonic shape (4096 samples) to a calibrator.
Parameter(s)
<VAL_INT> = 16384
Prepare calibrator to receive harmonic table
Example(s)
BD_16384[CR][LF]
Example answer
OK[CR][LF]
Function
Write data to calibrator
Command
WR_<DATA><CRC>[CR][LF]
Description
Write data (table of samples) of harmonic shape to the calibrator. The table of shape consists
of 4096 samples (one period).
Each sample of shape is coded as a 4 ASCII chars (hexadecimal value of Sample).
Sample = ShapeSample • 4095 + 4096; where:
Sample
calculated sample in range from 1…4096…8191 (natural number)
ShapeSample
sample of a shape (shape normalized to
1 values)
ShapeSample = 0
1000 hex value (4096)
ShapeSample = -1
0001 hex value (1)
ShapeSample = +1
1FFF hex value (8191)
Parameter(s)
<DATA>
binary data coded as an ASCII chars. Max. size of <DATA> is 114 chars (29
samples)
<CRC>
4 bytes of CRC checksum
Example(s)
WR_10000FFA0FF40FEE0FE70FE10FDB0FD50FCE0FC80FC20FBB0FB50FAF0FA90FA
20F9C0F960F8F0F890F830F7D0F760F700F6A0F630F5D0F570F51F387[CR][LF]
(116 bytes of first 29 samples of sine-
shape, last 4 bytes are CRC “F387” counted from
<DATA>)
Example answer
OK[CR][LF]
Function
Harmonics
– uploading to channels
Command
H2CH_<CHANNEL>[CR][LF]
Description
Rewrite shape wi
th harmonics from the C300’s receiving buffer to the memory.
Parameter(s)
<CHANNEL> = 0
change default SIN shape to the new one
<CHANNEL> = 1
set harmonics shape to the U1
<CHANNEL> = 2
set harmonics shape to the U2
<CHANNEL> = 3
set harmonics shape to the U3
<CHANNEL> = 4
set harmonics shape to the I1
<CHANNEL> = 5
set harmonics shape to the I2
<CHANNEL> = 6
set harmonics shape to the I3
Example(s)
H2CH_1[CR][LF]
(set harmonics shape to the U1 channel)
Example answer
OK[CR][LF]
START
Prepare calibrator
to data transfer
BD_16384
Send data to
calibrator
WR_
Upload buffer to
channel memory
H2CH_
Send
FREQDIV_1
Switch harmonic ON in uploaded
channel
HR
NO
YES
Send data
to next
channel?