[ mnn @ 14.02.2015. 20:55 ] @
Šta ovde nije dobro ili ja ne vidim ? U pitanju je Pic18f orginal include fajlovi .Umesto da mi displej piše po portu D on mi piše po portu B
Code:

/* PIC18 XLCD peripheral routines.
 *
 *   Notes:
 *      - These libraries routines are written to support the
 *        Hitachi HD44780 LCD controller.
 *      - The user must define the following items:
 *          - The LCD interface type (4- or 8-bits)
 *          - If 4-bit mode
 *              - whether using the upper or lower nibble
 *          - The data port
 *              - The tris register for data port
 *              - The control signal ports and pins
 *              - The control signal port tris and pins
 *          - The user must provide three delay routines:
 *              - DelayFor18TCY() provides a 18 Tcy delay
 *              - DelayPORXLCD() provides at least 15ms delay
 *              - DelayXLCD() provides at least 5ms delay
 */

/* Interface type 8-bit or 4-bit
 * For 8-bit operation uncomment the #define BIT8
 */
/* #define BIT8 */

/* When in 4-bit interface define if the data is in the upper
 * or lower nibble.  For lower nibble, comment the #define UPPER
 */
 #define UPPER 

/* DATA_PORT defines the port to which the LCD data lines are connected */
 #define DATA_PORT              PORTD
 #define TRIS_DATA_PORT         TRISD

/* CTRL_PORT defines the port where the control lines are connected.
 * These are just samples, change to match your application.
 */
 #define RW_PIN   LATDbits.LATD2         /* PORT for RW */
 #define TRIS_RW  TRISDbits.TRISD2        /* TRIS for RW */

 #define RS_PIN   LATDbits.LATD1          /* PORT for RS */
 #define TRIS_RS  TRISDbits.TRISD1        /* TRIS for RS */

 #define E_PIN    LATDbits.LATD3          /* PORT for D  */
 #define TRIS_E   TRISDbits.TRISD3       /* TRIS for E  */


[ goran_68 @ 14.02.2015. 21:07 ] @
Najverovatnije nisi uvukao ovaj fajl vec neki drugi. U ovom je na prvi pogled sve dobro.
[ bogdan.kecman @ 14.02.2015. 23:10 ] @
iskopiraj taj fajl kod sebe u dir i nemoj da ga zoves xlcd.h nego mu daj svoje ime ... XC8 je velika budzevina (i C18 je bio) tako da sto rece kolega cesto uvuce default fajl umesto taj tvoj, posebno ako si ostavio default setovanje onda mu je njegov include svakako pre tvog
[ zoran968 @ 15.02.2015. 10:40 ] @
Jeste, ovo je stari problem jos iz C18. Koliko neprospavanih noci, jer sam bio ubedjen da je dokumentacija ok i da je greska u meni. Dok nisam shvatio problem bio sam siguran da sam glup i da ja to ne mogu. Mogu samo da zamislim koliko je ljudi, pogotovo pocetnika, odustalo od mikrokontrolera zbog slicnih situacija, koje mogu da obeshrabre.
[ mnn @ 15.02.2015. 14:22 ] @
Valjda je bilo do mene.Povlačio je svoj include.Proradio je .Hvala na sugestijama.