microEngineering Labs, Inc.
    719-520-5323
 
Home:
  Developer Resources:

Programming Clues
    Sample Programs
   
    PICBASIC PRO™
Compiler Manual
    PICBASIC™ Compiler
Manual
    Serin2/Serout2 Modes
    ASCII Character Set
    Number Conversion
    Floating Point
Routines
    PBP Debug Monitor
    Articles and Tutorials

Hardware Clues
    Parts / Vendor List
    PICPROTO™ Boards
    LAB-X1 Docs
    LAB-X2 Docs
    LAB-X20 Docs
    LAB-X3 Docs
    LAB-X4 Docs
    LAB-XUSB Docs
    LAB-XT Docs
     
 

PBP examples written for the PIC16F887 and LAB-X1 Experimenter Board

The 16F887 replaced the older 16F877A. The 887 is less expensive and has an internal oscillator.

adcin10x.pbpPICBASIC PRO program to display result of 10-bit A/D conversion on LCD Connect analog input to channel-0 (RA0)
adcin3x.pbpPICBASIC PRO program to display result of 8-bit A/D conversion on LCD Connect analog inputs to channels 0, 1, 3 (RA0, 1, 3)
adcin8x.pbpPICBASIC PRO program to display result of 8-bit A/D conversion on LCD Connect analog input to channel-0 (RA0)
adcx.pbpPICBASIC PRO program to read pots on 16F887 ADC
blink8x.pbpPICBASIC PRO program to blink all the LEDs connected to PORTD
blinkx.pbpPICBASIC PRO program to blink an LED connected to PORTD.0 about once a second
bpx.pbpPICBASIC PRO program to simulate an LCD Serial Backpack. Serial data received is displayed on the LAB-X1 LCD.
butx.pbpPICBASIC PRO program to show button presses on 4 LEDs with the LAB-X1.
clockx.pbpPICBASIC PRO program for an LCD clock using On Interrupt. Uses TMR0 and prescaler. Watchdog Timer should be set to off at program time and Nap and Sleep should not be used. Buttons may be used to set hours and minutes.
eepagex.pbpPICBASIC PRO to demonstrate the page-write capability of the 24LC256 serial memory. This program will transfer 64 bytes of data to the memory before a pause is needed to complete the write.
hserx.pbpPICBASIC PRO to send and receive from the hardware serial port.
i2cWordx.pbpPICBASIC PRO program to read and write to I2C SEEPROMs that require a word-sized address. Writes to the first 16 locations of an external serial EEPROM. Reads first 16 locations back and send to LCD repeatedly.
i2cwx.pbpPICBASIC PRO program to read and write to I2C SEEPROMs that require a word-sized address. Writes to the first 16 locations of an external serial EEPROM. Reads first 16 locations back and send to LCD repeatedly.
i2cx.pbpPICBASIC PRO program to read and write to I2C SEEPROMs that require a byte-sized address. Writes to the first 16 locations of an external serial EEPROM. Reads first 16 locations back and send to LCD repeatedly.
jrcx.pbpPICBASIC PRO program for an LCD clock using the JRC6355 RTC.
keyx.pbpPICBASIC PRO program to display key numbers on LAB-X1 LCD.
lcdinx.pbpPICBASIC PRO program to display 'hello world' on LCD, then use LCDIN to read the first letter of each line and change it to upper case.
lcdx.pbpPICBASIC PRO program to display 'Hello World' on LAB-X1 LCD.
lcd_bit_bang.pbpPICBASIC PRO program to manually operate (without LCDOUT) an LCD in 4-bit mode with the PIC16F887 and LAB-X1.
ltcx.pbpPICBASIC PRO program to read LTC1298 ADC.
mwx.pbpPICBASIC PRO program to read and write to Microwire SEEPROM 93LC56A. Writes to the first 16 locations of an external serial EEPROM. Reads first 16 locations back and send to LCD repeatedly. Note: for SEEPROMs with byte-sized address.
progee8x.pbpPICBASIC PRO program to receive a HEX file from PC and write data to I2C memory. Writes data in page mode, 8 bytes at one time. Memory device must be addressed with 8 bits and capable of receiving 8 bytes at once.
progeex.pbpPICBASIC PRO program to receive a HEX file from PC and write data to I2C memory. Writes data in page mode, 16 bytes at one time. Memory device must be addressed with 8 bits and capable of receiving 16 bytes at once.
rtcx.pbpPICBASIC PRO program for LCD clock using the Dallas 1202/1302 RTC ICs.
rwcodex.pbpPICBASIC PRO program to read and write to code space Flash Program Write must be enabled on your programmer. Writes to 8 locations of code space beginning at $1800. Reads 8 locations back and sends to LCD repeatedly.
serbufAx.pbpPICBASIC PRO program to demonstrate an interrupt-driven input buffer for hardware USART receive using Assembly language interrupt. Pin definitions compatible with LAB-X1 and PIC16F887
serbufx.pbpPICBASIC PRO program to demonstrate an interrupt-driven input buffer for Hserin using On Interrupt. Pin definitions compatible with LAB-X1 and PIC16F887.
servosx.pbpPICBASIC PRO program for servo control using On Interrupt. Uses TMR0 and prescaler. Watchdog Timer should be set to off at program time and Nap and Sleep should not be used. Buttons on LAB-X1 keypad are used to move servos.
servox.pbpPICBASIC PRO program to move RC servo 1 using keypad buttons. Button 1 moves servo left, 2 centers servo, 3 moves servo right.
spix.pbpPICBASIC PRO program to read and write to SPI SEEPROMs Writes to the first 16 locations of an external serial EEPROM. Then reads first 16 locations back and send to LCD repeatedly Note: for SEEPROMs with word-sized address.
strtblx.pbpPICBASIC PRO program to demonstrate a method of storing text strings in a table. The strings can be called by storing the location of the first character in a variable and calling the strout subroutine. The string will be sent to both LCD and Serial pin and the main program will resume when the null terminating character is encountered in the table.
temp3x.pbpPICBASIC PRO program to read the DS1620 3-wire temperature sensor and display temperature on LCD.
tempx.pbpPICBASIC PRO program to read DS1820 1-wire temperature sensor and display temperature on LCD.
temp_DS1822.pbpPICBASIC PRO program to read DS1822 or DS18B20 1-wire temperature sensor using OWIN and OWOUT commands and display temperature on LCD.
tmr1clkx.pbpPICBASIC PRO program that demonstrates the use of Timer1 interrupt for a real-time clock. Written for the LAB-X1 experimenter board with a 16F887.
tonex.pbpPICBASIC PRO program to create telephone pad tone. Note: LAB-X1 Oscillator must be set to 20MHz
vbarx.pbpPICBASIC PRO program to measure voltage (0-5VDC) and display on LCD with 2 decimal places. A 60 segment bargraph is also displayed using custom LCD characters. This program uses the */ operator to scale the ADC result from 0-1023 to 0-500. The */ performs a divide by 256 automatically, allowing math which would normally exceed the limit of a word variable.
vmeterx.pbpPICBASIC PRO program to measure voltage (0-5VDC) and display on LCD with 2 decimal places. This program uses the */ operator to scale the ADC result from 0-1023 to 0-500. The */ performs a divide by 256 automatically, allowing math which would normally exceed the limit of a word variable.