Hi All,

I moght well be that I am on the wrong list, but I think I hav ethe best 
chance to start here.

I manged to get a two .c file project compiling ang linked, upon reading 
the bin/release .lst file I see this
000002   2803     goto    0x3                     goto    
__sdcc_gsinit_startup
I clipped some lines
                                           _main    ;Function start
                                            ; 2 exit points
                                            ;    .line    13; 
"SDCC_PIC_Using.c"    LCD_SetUp();
0000d8   118a     bcf    0xa, 0x3                 PAGESEL    _LCD_SetUp
0000d9   20d3     call    0xd3                    CALL    _LCD_SetUp
0000da   118a     bcf    0xa, 0x3                 PAGESEL    $
0000db   0008     return                       RETURN
                                            ; exit point of _main
I clipped some more lines
                                           ;entry:  _LCD_SetUp    
;Function start
                                            ; 2 exit points
                                            ;has an exit
                                            ;; Starting pCode block
                                            _LCD_SetUp    ;Function start
                                            ; 2 exit points
                                            ;    .line    7; 
"LCD_Driver2.c"    PORTD = PORTA;
0000d3   1283     bcf    0x3, 0x5                 BANKSEL    _PORTA
0000d4   1303     bcf    0x3, 0x6
0000d5   0805     movf    0x5, w                  MOVF    _PORTA,W
0000d6   0088     movwf    0x8                    MOVWF    _PORTD
0000d7   0008     return                       RETURN
                                            ; exit point of _LCD_SetUp

but no routine with the name. __sdcc_gsinit_startup


I have set several settings in Code::Blocks, all from internet postings, 
for the compiler and linker to find things, do I have to give them too?

I must have forgotten something, to include, set or.....but can't figure 
out what..


Here are my working conditions.

SDCC version 2.9 ubder Code::Blocks version 8.02 on Windows XP
SDCC is set up for pic16F874

Here is my code:

First .c file:

#include <PIC/PIC16F874.H>

#include "LCD_Driver2.h"


// CONFIG
     static typedef unsigned int config;
     config at 0x2007 __CONFIG = _PWRTE_OFF & _BODEN_OFF & _WDT_OFF & 
_LVP_ON & _CPD_OFF & _DEBUG_OFF & _HS_OSC & _CP_OFF;

// main body
void main(){
     LCD_SetUp();
     }


second .c file


#include <PIC/PIC16F874.H>


void LCD_SetUp(void)
{
     PORTD = PORTA;
}

the LCD_Driver2.h

void LCD_SetUp(void);


Who can help me through this?


Thanks.


Frans.

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Sdcc-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sdcc-user

Reply via email to