Build Log: Waterproof longboard 10s LiFe with Vesc

Very good point, my batteries are actually ~33 volts so thatā€™s about 16.5 amps if water bridges the terminals. Those terminals are connected the the BMS which I know has some kind of over current protection. But that still would be bad. I wouldnā€™t want my BMS to keep shutting them off and back on. Sooooo thatā€™s what the Corrosion X is for :grinning:

Also Iā€™m sure the resistivity of water changes based on distance and the ā€œthicknessā€ of the water bridging the terminals. I wonder exactly how many ohms it will be in this situation.

Iā€™m going to do a little experiment on this Iā€™ll post it here when Iā€™m done.

2 Likes

Alright i just did the experiment. Hereā€™s what I did:

I took some spare lipos I had (22.2 volts total) and hooked them up to my multimeter in amp mode and a female xt60 connector. I then dipped the connector into tap water from my sink and checked the amperage. I sprayed Corrosion X on the female xt60 connector and I dipped it again.

results: without corrosion x: 0.015 amps with corrosion x: 0.003 amps

This is how many amps the water allows with the connector fully submerged, so I think it will be pretty safe on the bottom of my board with water just spraying on it. :grinning:

Amps will be a little higher on my 33 volt batteries but should be pretty close.

3 Likes

Thats interesting. That would mean the water has resistivity of around 1500Ohms. Anyway, good to hear it works fine to you.

The second enclosure is done! This one was actually a lot harder to form because the kydex had to stretch and compress more because if the smaller size. But it still turned out pretty good.

Got all the electronics in it and sealed all the holes with loctite marine epoxy. I also used a yoga mat again between the board and the deck.

And hereā€™s the (mostly) completed board!

20 Likes

That looks sick with the LED light

1 Like

My board is officially complete! :grinning: Here are some pictures of it:

Here are the measured specs: top speed: 20 mph range: 11 miles (farther than I expected) charge time: about an hour (charging at 1C) weight: only 15 pounds

I meet all the goals I set for this build. Itā€™s (most likely) completely waterproof. Iā€™ve only rid it through puddles so far but itā€™s been doing fine. Itā€™s easy to charge with the BMS. The batteries are a safe chemistry (LiFe) so they shouldnā€™t ever catch on fire. The ground clearance is great, and the winning remote is working pretty well for me (Iā€™ve only had a few drop outs when Iā€™m pulling lots of amps. I am gonna try more loops around the ferrite ring).

Also I havenā€™t posted anything about my Arduino battery meter here yet. I wanted an easy way to see how much battery life I had left so I made this:

This circuitboard has @JdogAwesomeā€™s mosfet switch and an arduino that Iā€™ve programmed to read the battery voltage and display it on 5 LEDs on the outside of the board.

Iā€™ve found that just reading voltage isnā€™t the best way to monitor LiFe batteries because their voltage goes up and down a lot depending on load but it works good enough. :grinning:

Iā€™d like to thank all these people for making this board possible: :slight_smile: @JdogAwesome for the mosfet switch @torqueboards for the wheel pulley kit @chaka for the vesc and motor Benjamin Vedder for designing the vesc @stealth71 for the kydex enclosure idea @onloop for making this forum possible and everyone else here for posting their builds and ideas.

Some things I still want to add in the future: a headlight for seeing the road better at night a handle change from 9mm to a wider belt a gps tracker (any ideas for this?)

8 Likes

Board looks really clean man, love it!

1 Like

Wow this board is beautiful! Im happy you liked the design of my switch and I hope it fits your needs!

1 Like

Nice :slight_smile: We have 12mm Kegels now btw. They are a much nicer/durable fit than the previous versions.

1 Like

Iā€™ve had a few people ask me how I did the Arduino battery meter so hereā€™s how I did it: :grinning: Iā€™m writing this assuming basic arduino programming knowledge and goodish math knowledge.

This is how the Arduino reads the battery voltage:

The Arduino analog pins can read anything from 0 to 5 volts so I just used resistors to drop the main voltage down before connecting to an analog pin. The voltage will still be proportional to the main voltage.

So now that the arduino can read the battery voltage it just needs to know what voltage correlates to what capacity. Since my LiFe batteries donā€™t discharge linearly I had to find an equation for the discharge curve. To do this I charged my battery fully then rode my board until it died, checking the battery voltage with a multimeter every mile and writing it down (I used the app Strava to know how many miles I had gone).

Once I had a table of data (distance traveled and voltage) I put the data in my calculator and used the calculators built in quartic regression to find an equation for the curve:

I put 5 LEDs on my board so I decided my battery meter would have 6 states: (1 means LED on and 0 means LED off)

Then I just had to use the equation to find out what the battery voltage would be at every increment.

The arduino analogRead() function doesnā€™t directly read the voltage. It only reads a fraction of the voltage determined by the resistors used in the first picture. It also doesnā€™t return the value of the voltage, it returns a number 0 through 1023 (0 being 0 volts and 1023 being the reference voltage(the reference voltage is really close to 5 volts)).

So now I had to find an equation that relates the battery voltage to the number the arduino analogRead() function returns. This is way easier than the last equation because it will be a linear one. I just needed two data points:

first data point: battery voltage: 0 analogRead(): 0

second data point: battery voltage: 33.6 analogRead(): 748

To find the second data point I just measured the battery with a multimeter and used the arduino serial monitor to display the results of analogRead().

Then I plugged these into my calculator and used linear regression to find an equation. I used that equation to translate all the battery voltage increments into what analogRead will say at those voltages:

So now I know what increments to change the LEDs at, time to program the ardiuno! The ardiuno code is really simple, here it is:

//longboard battery meter code //Nick Wallick 10/20/16

int delayTime = 100; int battery; int flashingTimer = 0;

void setup() { // put your setup code here, to run once: pinMode(A7, INPUT); pinMode(8, OUTPUT); pinMode(9, OUTPUT); pinMode(10, OUTPUT); pinMode(11, OUTPUT); pinMode(12, OUTPUT);

startupAnimation(); startupAnimation(); }

void loop() { //reads pin attached to resistors and battery battery = analogRead(A7);

//BATTERY AT 5 BARS/////////////////////////////// if (battery >= 750){ digitalWrite(8, HIGH); digitalWrite(9, HIGH); digitalWrite(10, HIGH); digitalWrite(11, HIGH); digitalWrite(12, HIGH); } //BATTERY AT 4 BARS/////////////////////////////// if (battery < 750){ if (battery >= 741){ digitalWrite(8, LOW); digitalWrite(9, HIGH); digitalWrite(10, HIGH); digitalWrite(11, HIGH); digitalWrite(12, HIGH); } } //BATTERY AT 3 BARS///////////////////////////////// if (battery < 741){ if (battery >= 737){ digitalWrite(8, LOW); digitalWrite(9, LOW); digitalWrite(10, HIGH); digitalWrite(11, HIGH); digitalWrite(12, HIGH); } } //BATTERY AT 2 BARS/////////////////////////////// if (battery < 737){ if (battery >= 734){ digitalWrite(8, LOW); digitalWrite(9, LOW); digitalWrite(10, LOW); digitalWrite(11, HIGH); digitalWrite(12, HIGH); } } //BATTERY AT 1 BAR/////////////////////////////// if (battery < 734){ if (battery >= 724){ digitalWrite(8, LOW); digitalWrite(9, LOW); digitalWrite(10, LOW); digitalWrite(11, LOW); digitalWrite(12, HIGH); } } //BATTERY AT FLASHING/////////////////////////////// if (battery < 724){ if (battery >= 683){ if (flashingTimer > 2000){ digitalWrite(8, LOW); digitalWrite(9, LOW); digitalWrite(10, LOW); digitalWrite(11, LOW); digitalWrite(12, LOW); }else{ digitalWrite(8, HIGH); digitalWrite(9, HIGH); digitalWrite(10, HIGH); digitalWrite(11, HIGH); digitalWrite(12, HIGH); } flashingTimer = flashingTimer + 1; if (flashingTimer > 8000){ flashingTimer = 0; } } } //BATTERY AT FAST FLASHING/////////////////////////////// if (battery < 683){ if (flashingTimer > 500){ digitalWrite(8, LOW); digitalWrite(9, LOW); digitalWrite(10, LOW); digitalWrite(11, LOW); digitalWrite(12, LOW); }else{ digitalWrite(8, HIGH); digitalWrite(9, HIGH); digitalWrite(10, HIGH); digitalWrite(11, HIGH); digitalWrite(12, HIGH); } flashingTimer = flashingTimer + 1; if (flashingTimer > 1000){ flashingTimer = 0; } } }

void startupAnimation() { digitalWrite(8, HIGH); delay(delayTime); digitalWrite(8, LOW); digitalWrite(9, HIGH); delay(delayTime); digitalWrite(9, LOW); digitalWrite(10, HIGH); delay(delayTime); digitalWrite(10, LOW); digitalWrite(11, HIGH); delay(delayTime); digitalWrite(11, LOW); digitalWrite(12, HIGH); delay(delayTime); digitalWrite(12, LOW); digitalWrite(11, HIGH); delay(delayTime); digitalWrite(11, LOW); digitalWrite(10, HIGH); delay(delayTime); digitalWrite(10, LOW); digitalWrite(9, HIGH); delay(delayTime); digitalWrite(9, LOW);
}

The code just reads the A7 pin and turns the right number of LEDs on depending on what A7 returns.

When writing the code I decided to add fast flashing, in addition to normal flashing, if the battery gets way too low so I know to turn it off. I also added a startup animation just cause it looks cool :slight_smile: .

Hopefully this helps some people figure out how to make a battery meter!

Also hereā€™s my full electrical drawing of the circuitboard I soldered the arduino to. The wires going up on the right go to the LEDs. This circuit board also has this mosfet switch.

10 Likes

This is one of the most beautiful builds Iā€™ve seen with external enclosures.Your enclosures along with buttons and leds just look professional. The builds I love the most are the stealth builds with a hollow wooden deck, but you have the added advantage of leaving some flex in the board for comfort!

The only thing I think you should do make it actually waterproof is getting rid of the connector between the enclosure, and making an enclosure/spray-shield for your motor so water doesnā€™t spray in to it. Iā€™m also going to do a waterproof build so yours will definitely serve as inspiration!

1 Like

Thanks so much! It would look better without the connector between the enclosures but I kinda need it for ease of maintanence. It should be fine getting wet though.

A splash guard for the motor would be good to protect the motor bearings from water. Or I can change the motor bearings with ceramic ones.

Do you have a complete list of all the parts you used?

Hey @ndwallick I love the schematic for the board and how you implemented everything, only thing I would suggest is using a small buck converter instead of the Linear one because they are 100x more efficient. Also I purchased these for headlights and they seem pretty bright, though I havenā€™t tested them on my board in real conditions yet. And for the GPS thing, Iā€™ve had an idea in dev for a little while now which would have a GPS module as well as UART communication with the VESC and connect via BT to your phone to get accurate info on your VESC as well as GPS based info, but donā€™t expect anything any time soon lol.

EDIT: you may also want to slightly bump your positive side MOSFET gate driver voltage divider resistor a little, like 12K ohms because ATM gate is being given 17V which is a little closer to the max of 20V for the 3034. You should be fine at 17V but if you wanna make sure Iā€™d go with 12K resistor. And if you really want to perfect it you could use a 12V Zener instead to give it a constant 12V.

Here you go @LivingLongboard I meant to post this earlier. All the parts I bought and their prices: https ://docs.google.com/spreadsheets/d/1z52R29VjZmLlpdBmYNeP7w5TYLwirt2lKW2v7VQmexs/edit?usp=sharing

Edit: just remove the space after https. The link was causing problems

@JdogAwesome I do plan on switching to a buck converter. At first I thought a linear voltage regulator would be fine cause it is only powering an arduino but it does get pretty warm. Il also switch to the newer higher voltage mosfets that you suggested in your post and Iā€™ll change out the resistors according to whatever those mosfets need.

Iā€™ll probably just make a whole new circuitboard with all the changes and add whatever circuitry for headlights I may need. Il definitely check out those headlights theyā€™re super cheap.

Also looking forward to your GPS module!

Fantastic build, @ndwallick!

Iā€™m looking at getting the same deck and 5065-200kv motor. Have you found the flex of the deck to be a problem? Also, how hot does the motor get during a riding session?

In hindsight is there anything you wouldā€™ve done differently with this build?

Thanks

Thanks! The deck has a medium flexiness to it. When I attached the kydex it definitely got stiffer but the flex didnā€™t cause any problems.

The motor gets pretty warm but never too hot to touch.

The main thing I changed since I finished the board is upgrading to this 12mm pulley kit because I already had a 9mm belt break.

Good luck with your build

Great, thanks for the info. What range are you getting with your 10S2P LiFe pack?

Right when I finished the build I did a range test and got 11 miles, but I was likely not pushing it very hard since I was still getting used to it. I also live in an area with no hills. So Iā€™d guess a little less than that. The board only weighs 15 pounds so thereā€™s definitely room for more battery.

1 Like

Hi! what type of mounting hardware you are using? Can you share the site, where you bought it?