Steering diodes, the problem with the code

Hello, I need something like this ... Using Arduino and bluetooth wants to light up the LEDs 7 pcs and dim and brighten another 5 pieces I need the code to program the Arduino (I do not have, so the version of any - buy what you will need) and I want to light up / dim the LEDs using a program written in C + + (after editing of course) If anyone is able to help me I would appreciate and please contact us.

So you have a bluetooth module, 12 LEDs, 12 current limit resistors.
You want to receive a message that is 2 bytes long via the serial port connected to the D0/D1 lines and make pins D3-4-5-6-7 and D8-9-10-11-12-13 turn on off accordingly?

Simple code might be this using direct port manipulation:

byte x;
byte dPortdata;
byte bPortdata;

void setup(){
(for x=2; x<14; x=x+1){
pinMode(x, OUTPUT);
Serial.begin(9600);
} // end setup

void loop(){
if (Serial.available()>1){ 2 bytes received
dPortdata = Serial.read(); // read the bytes
bPortdata = Serial.read();
PORTD = PORTD & 0b00000011; // clear bits 2-3-4-5-6-7, leave 0-1 alone
PORTD = PORTD | (dPortdata & 0b11111100);  // OR in the 6 new bits
PORTB = PORTB & 0b11000000; // clear bits 8-9-10-11-12-13
PORTB = PORTB | (bPortdata & 0b00111111); // OR in the 6 new bits
} // end serial data check
} // end loop

If the bluetooth needs some specific stuff set up to tell it pair with another device, or to set the data rate, whatever, we'll need to know more to develop that part. For now, try the above with the serial monitor. LED cathodes connect to Gnd, anodes go to a series resistor and then to 2-3-4-5-6-7-8-9-10-11-12-13.

wants to have 7 LED that can disable or enable and 5 LEDs which can operate linearly brighter darker I want to control the LED using a laptop with bluetooth. On the laptop will be a program written in C + + control. I need a code to Adruino that it realized. I need a program code that works with C + +. Because at the moment I have a situation with the program on a laptop at his window, light bulbs, and using potentiometers can be dimmed, I want to do the same thing except that in real terms for LED

I've given an example. Expand from there. Send more bytes, with 1 byte per PWM level for the dimming LEDs, arrange the pins differently so the data goes to the correct IO pin, etc.