SDCC version: 3.0.4 #6622
Command line: sdcc -c -mpic16 -p18f2685 --denable-peeps test.c
source:
{
__code const unsigned char * hexfa;
hexfa=(__code unsigned char *)0x12000L;
}
will result in:
CLRF r0x01
MOVLW 0x20
MOVWF r0x02
CLRF r0x03
wehre the upper byte is lost!
NO error Message is generated!!!
Does SDCC support pointers larger than 16 bits for PIC16? I doubt it.
Shure, The PIC16 is able to adress 20Bit of code.
The hole handling of code pointers in the SDCC is designed for 20Bits!
After loading a long ponter it works well.
The only problem is the initaialisation from an constant