Hi,
I have a program, which I converted to Java from C++. At least most of it. However I am getting error for 2 statements. Any help would be appreciated;
This is the error I am getting:
Code:
$ javac FirmwareTest.java
FirmwareTest.java:56: operator ! cannot be applied to int
if ((len != 270) || (s0.charAt(0) != 0x83) || (!(b1 & 0x80) ) ) {
^
FirmwareTest.java:80: cannot resolve symbol
symbol : method subString (int)
location: class java.lang.String
String strRev1 = pHead.subString(3);
^
2 errors
How to re-write this expression in Java?
Code:
(!(b1 & 0x80) )
b1 is int datatype.
variable "pHead" is "final String pHead;"
Thanks
S