Suzuki SV650 Riders Forum banner
41 - 60 of 92 Posts
...With 12V I am able to get a steady current (1) when I connect input12 to one of the three solder spots of the barrel jack connector. When touching the solder spot two and three of the barrel jack connector I get a steady ground (0). When not touching any solder spots I get noise, switching between 0 and 1 constantly over and over.

Is this what is expected?
Yes that is expected. 12v through resistor will register HIGH, 0v through resistor will register LOW, open circuit will pickup whatever noise happens to be floating around.


...Will I be getting noise when applying this to my bike later?
It depends on the turn signals. If the elements are incandescent bulbs, then the filaments will provide a strong path to ground and keep the input low even if the flasher is inactive. No noise from a floating input in that case. However, you will still have EMI noise from the ignition system. 0.1uF capacitor to ground will reduce that to acceptable level.

If the flasher elements are LEDs, you will need to add pull-down resistors, say, 10k ohms to keep the chip inputs low when the flashers are off.

It is clumsy to describe in words so this schematic may help. The part shown is not your exact chip or I/O, just illustrates the concept. hth.
Image
 
Discussion starter · #42 ·
Wow. Thanks a lot.

I worked from your sketch and added the nRF24L01+ and the power source. Am I right to add the 6V voltage regulator after the power source? I figured I could use it to take the stress of the Arduino's regulator. Or is this the same as with the flashers, just a simple resistor? I am unsure when I need to use an voltage regulator and when just to use a resistor.

Also, do I just connect GND to the minus pole of the battery? I only need to tap into the flashers positive wire for probing right? Is there anything missing on my sketch?

Thanks!

Image
 
Discussion starter · #43 ·
Well, great success!
I did some initial testing with the bike today, brought my laptop and powered the Arduino through the USB of the computer, hooked it up to the bike. Initially I couldn't get it right, think I was probing the wrong wire of the two leading to the light. Then when I switched and probed from the other wire it worked like a charm.

Here's a crummy video showing the results.

Next is actually powering the Arduino from the bike's power and see if everything still works. I usually take one step at at time. Shouldn't be any biggie I suppose. Should I use a voltage regulator between the bike and the Arduino as in my sketch above?

Now I have to go help a friend of mine with TurboCAD, a program I've never used T_T. I'll keep you guys posted.
 
Looking good kodde!


Am I right to add the 6V voltage regulator after the power source?
The 7806 regulator is not necessary; the Uno's built in regulator is sufficient. You may want to add an in-line inductor between bike power and Arduino power to knock down ignition noise but probably not necessary for your application. Edit: where does the nRF24L01+ get power from?


...I am unsure when I need to use an voltage regulator and when just to use a resistor.
A voltage regulator provides a fixed voltage independent of load (current).

A resistor is not a regulator, it only drops voltage when current passes through it. The reason the resistor works for you flasher input is because the internal clamping diode is referenced to the chip 3.3v making it act like a zener diode. That probably sounds like gobbledygook but if you look up 'Zener Diode' you'll see a simple (two components) circuit that can be quickly built on your protoboard; playing around with that circuit might be fun and help clarify. If interested, checkout 'Voltage Divider' too.


...Also, do I just connect GND to the minus pole of the battery?
Yes, or tap into Black/White anywhere on the bike.


Is there anything missing on my sketch?
An inline fuse is advisable. Also, be sure to tap power from a switched source so the unit doesn't kill the battery. A copy of the Gladius schematic would be a big help. I don't have one and if you locate a copy please send one to me!
 
Discussion starter · #46 ·
This is why I love SVR. Somebody's always doing something cool like this. Well done!
Thanks :)

Looking good kodde!
Thanks!

The 7806 regulator is not necessary; the Uno's built in regulator is sufficient. You may want to add an in-line inductor between bike power and Arduino power to knock down ignition noise but probably not necessary for your application. Edit: where does the nRF24L01+ get power from?
Are you sure? The Arduino Mini Pro 3.3V is rated for a maximum of 12V input, doesn't the battery at times have a higher voltage than 12V?
Hardware reference on the Arduino Mini Pro 3.3V

If I should add an in-line inductor, what kind? what rate? Any of these?

The nRF24L01+ draws power on pin2 and ground is pin1.
Reference on the nRF24L01+ in conjunction with Arduino.
...and another useful link on the subject.


A voltage regulator provides a fixed voltage independent of load (current).

A resistor is not a regulator, it only drops voltage when current passes through it. The reason the resistor works for you flasher input is because the internal clamping diode is referenced to the chip 3.3v making it act like a zener diode. That probably sounds like gobbledygook but if you look up 'Zener Diode' you'll see a simple (two components) circuit that can be quickly built on your protoboard; playing around with that circuit might be fun and help clarify. If interested, checkout 'Voltage Divider' too.
Oh I see. I'll read up on the difference. Thanks.


Yes, or tap into Black/White anywhere on the bike.
Thanks.


An inline fuse is advisable. Also, be sure to tap power from a switched source so the unit doesn't kill the battery. A copy of the Gladius schematic would be a big help. I don't have one and if you locate a copy please send one to me!
I actually already have a distribution block hooked up, relay + fuse. So that should cover both the fuse part and the switch right? The relay taps in on the license plate light.
The distribution block guide I followed
The Gladius service manual in PDF format. - Alternative link
 
Discussion starter · #47 ·
Regarding the input Voltage,

In the Hardware section for the Arduinos when looking at the Uno board it lists both a recommended input voltage and the limits for input voltage. Apparently recommended range is 7-12V and limits are 6-20V. Could this be similar with the Mini board, but they didn't list it in a similar fashion?
Reference on the Uno

Either way I have both a 6V and a 8V voltage regulator lying around, I could use the 8V. That way I would stay within the recommended range for the Uno. If the Mini is similar to the Uno when it comes to input Voltage that would put me within the recommended range right?
 
Regarding the input Voltage,

In the Hardware section for the Arduinos when looking at the Uno board it lists both a recommended input voltage and the limits for input voltage. Apparently recommended range is 7-12V and limits are 6-20V. Could this be similar with the Mini board, but they didn't list it in a similar fashion?
Reference on the Uno
The 12v max spec on the Mini-Pro Summary page is generic, not necessarily what your board can handle. Here is the reference schematic from the same page:
Image


Note the exact part number for the 78xx (U2) is not called out, nor is the max voltage for the input filter capacitor C19 (more likely the limiting factor).

Can you read the part number of the regulator on your board? That will tell the true limit for that part (probably 35vdc). The max voltage for the input filter cap C19 will not be marked on the part. To be sure, it would need to be replaced with a known 50v (or more) cap, or add the regulator up front as you plan.

If you do add the regulator, be sure the filter cap is rated 50v or more. The bike voltage is only 14.5v max, but there are narrow voltage spikes (up to 20v) due to ignition noise coupling. The cap should be rated 2x that (at least), 50v is a common cap value.

kodde, for being new to this you are quite thorough and pick things up fast. Excellent work!
 
Discussion starter · #50 ·
The 12v max spec on the Mini-Pro Summary page is generic, not necessarily what your board can handle. Here is the reference schematic from the same page:
Image


Note the exact part number for the 78xx (U2) is not called out, nor is the max voltage for the input filter capacitor C19 (more likely the limiting factor).

Can you read the part number of the regulator on your board? That will tell the true limit for that part (probably 35vdc). The max voltage for the input filter cap C19 will not be marked on the part. To be sure, it would need to be replaced with a known 50v (or more) cap, or add the regulator up front as you plan.

If you do add the regulator, be sure the filter cap is rated 50v or more. The bike voltage is only 14.5v max, but there are narrow voltage spikes (up to 20v) due to ignition noise coupling. The cap should be rated 2x that (at least), 50v is a common cap value.

kodde, for being new to this you are quite thorough and pick things up fast. Excellent work!
Thanks mate. I'm just thorough and planning by nature I guess. Usually pays off in my experience. Anyway, the voltage regulator on the board is marked "KB33". When googling it I found this thread claiming that it's a Micrel 5205 MIC5205. Absolute voltage range is -20V to +20V from what I can tell. Best I use the external voltage regulator right?

The 10uF cap is rated 63V and the 0.1uF cap is rated 50V, so it should be good.

And thanks for the link to the Gladius Service Manual. :D
You are welcome. It's a sticky in the Gladius sub forum here on SVR.
 
... the voltage regulator on the board is marked "KB33". When googling it I found this thread claiming that it's a Micrel 5205 MIC5205. Absolute voltage range is -20V to +20V from what I can tell. Best I use the external voltage regulator right?
It's a bit kludgy to have two regulators back to back; +20v for the KB33 is sufficient, but without knowing the max voltage for C19, then adding the external regulator is an easy option. Replacing C19 with a known 50v part would work too.

For the inductor, 100uH is sufficient. To size the current, measure what the Mini-Pro draws then double that. If the mini draws 100mA or less, this inductor would work well.

btw, the dark sunglasses on your avatar are to hide the bloodshot eyes, no? Seems you are up all hours of the day and night! ;D 8)
 
Discussion starter · #52 ·
Alright. I'll go with the external regulator. No way am I going to re solder some part on the arduino Mini... I have one of them low price fairly big tip solder irons.

Regarding the inductor, I measure between the Raw-input-pin of the Arduino and the power source to see what current it draws right?

My avatar is Walter White from Breaking Bad, one of my all time favorite shows and a cool guy to look up to ^^
You are right though. I've never in my life slept this little during Christmas holidays, all thanks to this project. I'm loving it though, totally worth it.
 
Discussion starter · #53 ·
On second thought. The inductor would be between the bike's battery and the voltage regulator? Or between the regulator and the Raw-pin on the Arduino? This is the same place I measure at?
 
...The inductor would be between the bike's battery and the voltage regulator? Or between the regulator and the Raw-pin on the Arduino? This is the same place I measure at?
Measure between bike voltage and your add-on regulator. Install the inductor at the same place, directly at the front end.

Honestly, adding the regulator and inductor is conservative design considering this is a hobby project.

You could test the system without either and if it functions without glitch, it will likely work for a long time. Worst case, C19 would fail after a time, but could be replaced. It's not bad though to play it safe. Most important is you're having fun! :)
 
Discussion starter · #55 ·
Alright, will do.

To me, predicting possible errors down the line is part of the challenge. Since I already own the regulator and the inductor costs next to nothing, I find it more satisfying to implement this safety measure.

I've been tinkering and welding for a couple of hours now and I have the finished installment minus the regulator and inductor. I've tested the functionality here at home so far and it works as it should, both the RF unit and the current sensing on two different pins (left/right flasher). I'm quite happy that I managed to get it down to around 50x50x25 millimeters, including some margin for drilling installment holes.

It's late here in Sweden and I have to catch some shut eye. Tomorrow I will get the last parts and a nice plastic housing to hold the unit and test it on the bike. If that turns out well the only step left is to write the final code that will run on the sender(bike) and the code for the receiver(backpack).

Goodnight and thanks a bunch for the help.
 
Discussion starter · #58 ·
Thanks guys.

I'm heading out to get the extra few parts(inductor and plastic housing) soon. I'll keep you posted during the day. I'll get you some pics or videos of the installation of the motorcycle part as it should be finished later today.
 
Here's a quick update. The casing is 60x65x25mm. Just need to a drill a hole for the wires now. Then I'll head off to the garage to do some more testing.

Image
That is beautiful kodde!

A couple quick observations:
- Where are the 0.1uF noise caps for the flasher inputs, behind the edge connectors?

- Vibration is a big factor for motorcycle mounted electronics. The regulator, wireless card, even the interconnect wires may break if not securely mounted. Tightly mounted to the board helps with a dab of epoxy on big components if there is any possibility of movement. The wireless card will probably need a support.

Overall, great concept, design, layout, package! :rock:
 
41 - 60 of 92 Posts