—Demonstrates the use of Timer B to generate a PWM signal on digital output
•
PWM.C
OUT8. The program generates a 42 Hz PWM signal with the duty cycle adjustable
from 1 to 99%.
—Demonstrates how to control the relay on the BL2000.
•
RELAY.C
4.2.3 Serial Communication
The following sample programs are found in the
—Transmits and then receives an ASCII string on Serial Ports B and C. It also
•
PUTS.C
displays the serial data received from both ports in the
—This program echoes characters over Serial Port B to Serial Port C. It
•
RELAYCHR.C
must be run with a serial utility such as Hyperterminal.
The following sample programs are found in the
—This program demonstrates a simple RS-485 transmission of lower case
•
MASTER.C
letters to a slave BL2000. The slave will send back converted upper case letters back to
the master BL2000 and display them in the
the slave BL2000.
—This program demonstrates a simple RS-485 transmission of lower case
•
SLAVE.C
letters to a slave BL2000. The slave will send back converted upper case letters back to
the master BL2000 and display them in the
the master BL2000.
4.2.4 A/D Converter Inputs
The following sample programs are found in the
—Demonstrates how to recalibrate an A/D converter channel using two
•
AD_CALIB.C
known voltages to generate two coefficients, gain and offset, which are rewritten into
the user block data area. The voltage that is being monitored is displayed continuously.
Note that this sample program will overwrite the calibration constants set at the factory.
—Demonstrates how to access the A/D internal test voltages in both the
•
AD1.C
TLC2543 and TLC1543 A/D converter chips. The program reads the A/D internal volt-
ages and then uses the
—Demonstrates how to access the A/D channels using the
•
AD2.C
The program uses the
—Demonstrates how to access the A/D converter channels with the low-level
•
AD3.C
A/D driver. The program uses the
monitored on all the A/D channels using the low-level A/D driver.
—Demonstrates how to use the A/D converter channels with the low-level A/D
•
AD4.C
driver. The program uses the
ples) that is being monitored on all the A/D converter channels using the low-level A/D
driver.
36
window to display the RAW data.
STDIO
window to display the voltage that is being monitored.
STDIO
STDIO
window to display the voltage that is being
window to display the voltage (average of 10 sam-
STDIO
subdirectory in
RS232
window.
STDIO
subdirectory in
RS485
window. Use
STDIO
window. Use
STDIO
subdirectory in
ADC
SAMPLES/BL2000
SAMPLES/BL2000
to program
SLAVE.C
to program
MASTER.C
.
SAMPLES/BL2000
function.
anaInVolt
Wildcat (BL2000)
.
.