Speeduino is now on Github Sponsors (Rather than Patreon): https://github.com/sponsors/noisymime
Anything not specifically related to the Speeduino hardware. Eg sensors, bluetooth, displays etc
User avatar
By JanKovalski
#48779
I'm building a custom board for my project. I specifically chose the Mega 2560 Pro because of its small footprint.
Mega2560_mini_pro_robotdyn.jpg
Mega2560_mini_pro_robotdyn.jpg (57.45 KiB) Viewed 4899 times
I need this to be able to fit my board inside the stock ECU's enclosure. And it works, the car starts and runs. But the problems starts when I try to hook up a bluetooth module. I have a XM-15B SPP. What I've tried so far:

- Use two different Mega 2560 Pro boards
- Use two different XM-15B SPP modules
- Use a logic level converter, both ways
- Use a USB-UART module to test if pins 0 and 1 of my board are okay - and they are - I'm able to connect with TS this way

But the bluetooth module won't connect. In the end I was able to figure out that it's about the supply voltage to the Arduino itself. My power supply is based on a LM2940-5 and it outputs exactly 4.95V. When I power the Arduino via a diode or a 10 ohm resistor, so the power supply to the board drops to about 4.3V, the bluetooth suddenly connects and works. But if I power the Arduino with 4.95V and lower the voltage only on the bluetooth module supply to 4.3V it won't work.

The issue does not appear on a full-sized version of Mega 2560 (which is also just a clone). I can connect via that same bluetooth module whether I supply the Arduino with 4.3V or 5.2V.

Any ideas? I understand that I can't just solve this issue by supplying my Arduino with 4.3V because it's rated 4.5-5.5V and I believe it would mess up analog calculations too.
By fram
#48783
Hi

Arduino 2560 pro include a 5V LDO regulator and a 3.3V LDO regulator.
If you feed your board with Vin = 5V, because of the 5V LDO dropout voltage, output for this regulator will go down to 4.2/4.3V.

So, because of this dropout voltage of the +5V LDO regulator, you need to feed your board with a PSU of 6V mini for Vin (6.3v to 6.5V is fine).

You should double check the Mega 2560 pro schematic to clearly understand the power suppplies part.
Probably a good starting point to have stable PSU for your system.

;)
User avatar
By DeeEmm
#49064
I've had a similar issues with the pro boards.

Some of the HC-05 / 06 modules work fine and others don't. I've never been able to figure out why. Even with the same brand & type of HC module, one batch works okay, the next don't. Last lot of HC-05's I bought from Lonely Binary were fine, this lot none of them work. Go figure.

They all work fine on a loopback test, but not in circuit. My guess was always a voltage issue, but not been able to pin it down.

I've not measured a drop in the regulated 5v from the board, it's pretty stable at 4.97, even after the BT has connected.

In the past I've used them connected direct without a voltage divider as they appear to be pretty 5v tolerant despite actually being a 3.3v device, but even connected with a voltage divider I'm not having any luck with this batch.

Adding a voltage divider might be worth a try if you haven't already.

I'm interested to find out what causes this problem and what the fix might be as I have a pile of HC modules that I could potentially use.
Attachments
HC-05-Basic-set-up.jpg
HC-05-Basic-set-up.jpg (113.55 KiB) Viewed 4631 times
User avatar
By DeeEmm
#49065
@JanKovalski I just tried lowering the supply to 4.3v on the board I have here and it does not connect.

I suspect your issue may be that the RX line is too high and lowering the voltage brings it down within the 3.3.v logic range. Try using the voltage divider and see if it fixes your issue.
User avatar
By PSIG
#49174
The XM-15 is an HC "compatible" device, with many settings. It also has circuits to avoid needing any resistor dividers, etc, as stated in the datasheets I could find. You may want to issue a reset command to defaults, then check and set the basic stuff, like master/slave, baud, parity, stop bits, etc.

I have not used that unit, and it may work well, but most HC-compatible BT modules have issues or weaknesses of one kind or another that I have encountered. Unless doing something specific or special, I generally suggest (such as in the Wiki) using a real (BlueCore chip) HC-06 (slave-only) on the standard 4-pin backboard, with only one setting required for 115200 baud - as a starting point for most new users.

If using only the HC-06 module without backboard adapter, I suggest the connections shown below, or other proven circuit. The backboard has the circuits already.

The original HC-06s have been ultra-reliable across hundreds of Speeduinos for basic uses. Other devices are unknown, and may be great, but up to you to sort-out. Good luck!
HC-06 TxRx V-shift.png
HC-06 TxRx V-shift.png (36.3 KiB) Viewed 4510 times
#49202
Thing is, that same particular module connected to the regular mega works and with the pro it doesn't. I ordered the XM-15 because I read it's 5V tolerant so I thought it would be easier. I think I won't dig too much into it and just order the HC-06. Thank you.
By NickZ
#49393
you will also find the HC-05's are not all the same, ive had them work perfect on one design then the next lot of HC-05 didn't. I ended up using a blocking diode on both the CH340 and bluetooth lines and used a pull up resistor on the Mega2560 TX pin. this solved most of my problems.
PCB for BMW m52 engine

Hey guys, I have built a Rev2.2 version of this E[…]

… Here is my question: can I use speeduino[…]

Thanks everyone, I think 12 is probably going to b[…]

for a single cylinder engine, channel 1 is the p[…]

Still can't find what you're looking for?