Hi Dietmar,
> static void display_data(unsigned char c)
> {
> //PORTA = 0xaa;
> if(cmd_or_data)
> {
> PORTA |= 2;
> }
> else
> {
> PORTA &= ~2;
> }
> PORTB = c; PENABLE;
> c <<= 4;
> PORTB = c; PENABLE;
> cmd_or_data = DATA;
> }
What's PENABLE? How is cmd_or_data defined? And how is DATA?
Assuming
#define PENABLE TRISB=0x00
enum { CMD=0, DATA };
unsigned char cmd_or_data;
and using SDCC 2.6.4, r4616, the resulting code looks beautiful.
However, this might be due to
(1) the improved PIC code generator in the newer SDCC, or
(2) the assumptions above `spoiling' your bug, or
(3) the #include files not shown in your snippet.
I suggest you first upgrade your SDCC installation (ideally via svn, a
more recent nightly build (probably 31-12-2006) from
http://sdcc.sf.net/snap.php will do), try again and report your bug
again with complete, compiling source code so that I can reproduce the
error.
--
Regards,
Raphael Neider
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Sdcc-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sdcc-user