fix compiler warnings: braces around bit-arithmetics & wrong argument type

This commit is contained in:
marschap
2008-10-08 20:20:46 +00:00
parent 6b7db138d6
commit e07f90a6bf
+3 -3
View File
@@ -190,11 +190,11 @@ ftdi_HD44780_senddata(PrivateData *p, unsigned char displayID, unsigned char fla
portControl = p->ftdi_line_RS;
}
buf[0] = (ch>>4) & 0x0F | portControl | p->ftdi_line_EN;
buf[1] = (ch>>4) & 0x0F | portControl;
buf[0] = ((ch>>4) & 0x0F) | portControl | p->ftdi_line_EN;
buf[1] = ((ch>>4) & 0x0F) | portControl;
buf[2] = (ch & 0x0F) | portControl | p->ftdi_line_EN;
buf[3] = (ch & 0x0F) | portControl;
int f = ftdi_write_data(&p->ftdic, &buf, 4);
int f = ftdi_write_data(&p->ftdic, buf, 4);
if (f < 0) {
p->hd44780_functions->drv_report(RPT_ERR, "failed to write: %d (%s). Exiting",