Dim d7 blue light and jtag config help for recovery

Don’t know what jtag is, but with this code snippet you can control the Photon RGB LED - I´m on the right way (I know this differs to D7)?

void setup:
RGB.control(true);

void loop:
RGB.color(255, 0 ,0);
delay(2000);
RGB.color(0, 255, 0);
delay(2000);
RGB.color(0, 0, 255);
delay(2000);