From: Diego H. <die...@di...> - 2012-10-09 13:07:34
|
Hi! In sdcc/trunk/sdcc/device/include/pic16/usart.h<http://sdcc.svn.sourceforge.net/viewvc/sdcc/trunk/sdcc/device/include/pic16/usart.h> we can find: #if (__SDCC_PIC16_FAMILY == 1822200) \ || (__SDCC_PIC16_FAMILY == 1802420) \ || (__SDCC_PIC16_FAMILY == 1802480) \ || (__SDCC_PIC16_FAMILY == 1865200) \ || (__SDCC_PIC16_FAMILY == 1865850) #define __SDCC_NO_SPBRGH 1 #endif /* device lacks SPBRGH */ Shouldn't we use __SDCC_USART_STYLE instead of __SDCC_PIC16_FAMILY? Something like this: #if (__SDCC_USART_STYLE == 1822200) \ || (__SDCC_USART_STYLE == 1865200) #define __SDCC_NO_SPBRGH 1 #endif /* device lacks SPBRGH */ N.B: 1822200, 1802420, 1802480 and 1865850 belong to __SDCC_USART_STYLE 1822200 and 1865200 belongs to __SDCC_USART_STYLE 1865200. If I am right, I can provide a patch. Thanks! Regards, Diego Herranz |