Niko
B2 I was referring to bluetooth
So from what I understand, you are continuously sending the string where it updates each section of your screen. For instance, Checking XF sets the image on region 1030,665:
String btnXForward = json.getString("XF");
...
if ((btnXForward.equals("1")) == true || (btnXDownward.equals("1"))== true) {
image(imgGreen, 1030, 665);
} else {
image(imgRed, 1030, 665);
}
First question: Are you holding XF in “1” state during a long period?
Notice you are using btnXForward.equals("1"). I suggest that when you extract the value in the parsing process, you also add the trim() function to remove space characters. Not sure if it solves this problem but worth to try. For debugging, instead of printing outside the if statement, place your printing clause inside. It will look messier but you will be able to evaluate the functionality of that statement directly.