Pulling my hair out with Bluetooth and ATmega328p

I may have bitten off more than I can chew with trying to learn about microprocessors and wireless technologies. I've been trying to design an LED sign that can receive message via bluetooth and display them on an LED matrix display from Sure Electronics (32x16). I am currently on my 3rd prototype board (after having minor layout design issues with the first two), and cannot get my design to function 100%. Before I consider just cutting my losses and not spending anymore time on this project, I'd like to see if anyone might be able to tell me what my problem is. In the interest of helping you help me, I'll post everything I've got here.

I know my core circuit works, as when I load my program with a "Hello World" message onto the mega328p, it scrolls continuously across the screen.

I know the bluetooth module works, because I can pair with it, and even open a putty session (although can't seem to send anything to it).

I know the android App that I wrote for it works because I can install the app on my phone and my tablet and send data back and forth, as well as send data from my phone to my pc (putty) and back.

What isn't working though, is the sending data across bluetooth (either from my laptop or from an android remote for it I wrote).

Here is the board from eagle:

I've circled 2 areas I had to jumper to get the bluetooth to successfully pair...I'm not entirely sure why yet, but it pairs and connects now with that jumped.
My Eagle files (BRD and SCH): 3216 - 3mm BT USB

My Arduino code:Displaycode

The bluetooth modules I'm using:http://www.dealextreme.com/p/wireless-bluetooth-rs232-ttl-transceiver-module-80711

The Resistor divider in the top left is to step down the 5v signal to 3v3 for the bluetooth module, since it runs at 3v3 but my logic runs at 5v.

I've tried all sorts of tests, including setting my 328p to just send "test" to the serial port using serial.write, and other things, I can't seem to get the bluetooth to work with the micro, and it's starting to piss me off because it's probably something simple. I may do one more board run, making the entire circuit run at 3v3 instead of 5 (and dropping the logic down to 16mhz instead of 20) but I'd like to figure out why it isn't working, as this is my 3rd run, and I've already invested nearly 200$ in boards and parts building prototypes.

Would appreciate any help anyone might have.

bump.. anyone have any idea why this isn't working right? if the schematic/circuit/board is correct, then at least i can go back and check my code.



Nice little project you got going.

I cant see any faults with your eagle…

I have done some projects with bluetooth. I also started off buying the cheap bluetooth modules from dealextreme(I brought two of them). Everything i did seemed to be right, but i couldn’t get the module to receive anything! The pairing was no problem at all, and i knew the code was right. After LOTS of hours with no results i decided to but this module:

I plugged it in, same code, same android phone and same phone app, and WOLLA. Everything worked like a charm. I still dont know why they wont work.

I am not saying that this is your problem, but it could be worth a try…

The modules are not pin-compatible, but this could overcome with some wires as a start-off.

are you sure your voltage divider scheme its correct ? take a look at this http://www.sparkfun.com/tutorials/65

going with a 3.3v probably will solve some of your problems but a problem may appear while you interface your board with the display

..at which baudrate you run that BT uart module??? Those BT modules are transparent UARTS, but you have to set the specific baudrate you want to operate it at. Those BT modules are not "any" baudrate cables.
There is a procedure where you have to set it into "AT" configuration mode (not the transparent UART), set parameters (ie baudrate, password, name, etc) and then to switch back to the transparent uart mode. You have to connect a pin of the BT module to a specific log level and make reset in order to enter into that AT mode. See the datasheet. So - atmega, BT, and PC must be set to the same baudrate. P.