Help with RS485

Hi. I'm no expert in electronics but I build many PCB as a hobby. The problem is driving me crazy is to run a RS485 on a PCB. In the breadboard works perfect! No errors in transmission/reception are produced using terminators or without them (the cable is very short).
But when I take my PCB (it's the second plate I build) only transmit trash. No matter whether if I use terminators or not. I've checked several times the connections on the PCB and they are fine. To avoid interferences in this second attempt I've only used the ATMGEGA, the RS485, the ICSP (for power) and I used the terminator pins to connect the data line A and B of RS485.
The result is the same. I do not understand that if I take the same components to the breadboard works perfectly.
The code is not the problem, I'm sure. It is a simple code that returns an echo and as I say in the breadboard works well.
I include pictures of circuit. If anyone can provide me any idea I would be very grateful.
Thank you.

PCB.png

You have no supply decoupling in that circuit apart from the regulator. You need 0.1uF caps on each supply pin and on the Vref. You should also put one on the 485 driver as well.

At this stage you are best soldering surface mount capacitors directly on the pins on the back of the PCB.

Why did it work on bread board? Well it could be that the stray capacitance between the tracks was enough to stabilise the circuit, but probbly only just.

Grumpy_Mike:
You have no supply decoupling in that circuit apart from the regulator. You need 0.1uF caps on each supply pin and on the Vref. You should also put one on the 485 driver as well.

At this stage you are best soldering surface mount capacitors directly on the pins on the back of the PCB.

Why did it work on bread board? Well it could be that the stray capacitance between the tracks was enough to stabilise the circuit, but probbly only just.

Thank you very much . I'll try it in a while .

I've tried adding three 0.1uF (104) ceramic capacitors to ATMEGA8 VCC and AVCC, also to RS485 VCC (I uploaded a picture with these changes), but no luck, still the same.

I do not understand why it works on the breadboard with the same components and connections.

I appreciate your help.

20150424_180620.jpg

You should be routing the A and B RS485 signals as a balanced pair, not splitting them apart
around other bits of circuit.

Are you using the board to TX, RX or both? If RXing you did jumper in the terminating
resistor? The terminating resistor should be non-inductive.

You cable is twisted pair for AB isn't it? That's essential.

MarkT:
You should be routing the A and B RS485 signals as a balanced pair, not splitting them apart
around other bits of circuit.

Are you using the board to TX, RX or both? If RXing you did jumper in the terminating
resistor? The terminating resistor should be non-inductive.

You cable is twisted pair for AB isn't it? That's essential.

Yes, I use twisted pair although I think the cable is not the problem because I use the same cable on the breadboard and it works well.

I have also tried to use a 120omh terminator, but does not work. I even used biasing resistors with same result.

The last thing I have tried has been soldered terminals A and B directly to the socket pins of RS485. There has been no luck.

I have no idea what happens. Although the circuit design is simple, must have an error which I can not see.

Check all the ground and supply pins are getting the right voltage with a
multimeter, hunt with a lens for poor solder joints...

Have you tried swapping the pair over?
There is not a lot else you can do without looking at the signals on a scope.

I'll try to get an oscilloscope.
Thank you very much for your help.