This will handle both ints, bytes and chars transparently.
(int what)
| 241 | * This will handle both ints, bytes and chars transparently. |
| 242 | */ |
| 243 | public void write(int what) { // will also cover char |
| 244 | try { |
| 245 | port.writeInt(what & 0xff); |
| 246 | } catch (SerialPortException e) { |
| 247 | errorMessage("write", e); |
| 248 | } |
| 249 | } |
| 250 | |
| 251 | |
| 252 | public void write(byte bytes[]) { |