2 bluetooth shield having hard time to connect (red light)

scenario:
i have transmitter side (1arduino with 1 bluetooth shield) and receiver side (1arduino with 1 bluetooth shield) they connect fast (green becomes red in both bluetooth) when the program installed in the arduino were simple, but if i installed many lines of codes it had a hard time or not connecting (just green light blinking fast and not turning into red)

i thought the bluetooth was just dependent on its configuration, but it seems not (dependent also in the code installed in the arduino?), the codes inside the microcontroller also affects its time of connectivity?

how can i connect this the 2 devices. thanks

herminz:
i thought the bluetooth was just dependent on its configuration, but it seems not (dependent also in the code installed in the arduino?), the codes inside the microcontroller also affects its time of connectivity?

In normal use, bluetooth is just another serial device and runs as configured. I think it might be possible to have the code affect the connectivity if the bluetooth is in AT mode.

You might find some help here