DAVEga: Battery monitor, odometer, speedometer

@bigben Please PM me your address and how many would you like.

The same goes for anyone else who would like PCBs only.

I expect it won’t be before 2-3 weeks before I can ship full kits.

Just a reminder: The kits will come without the display. If you haven’t ordered one yet, it maybe be a good time to do it since it will take a while until it arrives to you. This is the cheapest source I have found, but I don’t have any experience with them, so I can’t give any recommendations.

3 Likes

still not a satisfying answer, but it’s ok.

PM’d

1 Like

Pmd back. If you need an enclosure for your board let me know and I’ll send one out to you. Think of it as a small thank you for what you’re doing for the community.

5 Likes

I had idea to put also programmable RGB strip controller port but after running simple examples it used over 80% of memory on ATmega32u4 so I don’t think it would fit together with main software. I will try to look either separate solution or into bigger flash mcu :stuck_out_tongue:

Because those strips looks sick :stuck_out_tongue:

3 Likes

@Kug3lis That looks cool. Is the speed / battery status somehow reflected in that?

1 Like

Here’s some info about the kit assembly, currently mainly for those who asked for the PCBs only.

This is the PCB layout:

50

Required components:

  • ILI9225 2.0" TFT LCD Display
  • ATMEGA328P-PU
  • 16 MHz crystal
  • 2x 20pF capacitor
  • 100nF capacitor
  • 1N4148 diode
  • 10k resistor
  • 3x button (only BTN1 currently used)
  • 8 pin JST PH female connector (for the VESC)
  • 5 or 6 pin right angle female pin header (for programming)
  • USB-UART adapter (for programming)

Recommended:

  • 8 pin JST PH male connector, 1 and 4 pin dupont female connectors
    • to make an 8 pin JST -> 5 pin dupont adapter for programming
    • update: maybe this is a better solution

Assembled PCB: 38

The VESC and DEBUG pads are for 4 pin JST PH connectors, but these are not needed. Better to solder on wires directly. VESC cable wires can be soldered either to the VESC pads plus the DTR (if you want to use the cable for programming as well) or to the 5 USB-UART pads.

In the local stores, I wasn’t able to find small enough 20pF capacitors. The ones I found are taller than the chip (second tallest) and that increases the thickness of the whole thing.

IMG_1467

Therefore I used SMD caps instead. If you need to do the same, I recommend the 0805 ones. Though smaller, they are easier to solder on than the 1206 since they fit in better.

Alternatively, it’s possible to use the DIP caps and carefully bend them.

IMG_1468

Be sure to burn a bootloader before soldering on the chip.

Here’s how to install the firmware.

Good luck!

9 Likes

Gerber files can be downloaded from https://easyeda.com/honza.pomikalek/VESC-Gauge.

  • scroll down to “PCB v0.2” and click on “Open in Editor”
  • select “Generate Fabrication File” from the menu: 31

@thisguyhere

3 Likes

Hey, does it matter what tolerance they are? I have some silver and gold ones in my parts kit from school and I was just gonna use those

It’s just a pull up resistor. You can use pretty much any value close to 10k.

1 Like

What if you made this available to put to a custom remote instead? If that is possible

TAKE MY MONEY!

1 Like

I’m definitely interested. Count me in.

evaD

I’m afraid the display is a bit too big for that. Remotes with smaller displays already exist. The Firefly has a small 128x32 display. A version with a bigger display is being worked on.

At any rate, if anyone wants to make an Arduino based remote with the 2.0" LCD, I’m happy to help with adjusting the VeGa FW for it.

1 Like

If u find an Display who ll fit in… 2 inch Huge for a remote. Any suggestions?

The 0.96 inch display is more than enough. I mean… bigger screen is cool :). But also took a lot of power by rendering ect. U need all recourses u have for cycle time and calculating. My small 0.96.inch display needs around 45-50ms to refresh in the fastest possible mode. Double size screen could take a bit longer. We have to test it…

Will these also be available like plug and play? I wouldn’t trust myself to assemble such a kit…

IMO, what you have is just about the right display size for the remote and I like your GUI. Adding speed would be a nice feature. Maybe you could get rid of the “POWER” label and move the wifi and headlight indicators to that area. You could get rid of the small battery indicator, which is redundant. Then you have the right side of the display free for more info.

Note that you don’t need to redraw the full display. You can only update what changed (e.g. speed). That way you can do much faster refresh rate. That’s what I do on VeGa. Redrawing everything each time wouldn’t be feasible.

Yes, I can assemble a few. It doesn’t take much time and I kinda enjoy doing it. Note that you’ll still need to do the wiring to the VESC so some soldering to the PCB is probably inevitable.

At any rate, as I said before, the first batch is meant for those who don’t mind to be beta testers. There will likely be problems that will require some tweaking. If you want a plug-and-play version, it’s best if you wait a little bit.

3 Likes

I have a button and u can switch through 4 different views with dirfferent informations. The section “Power” is the most important one for me at the moment because of my battery issues. There is also a long bar above the trigger jndicator I can’t see at the moment, because there is nothing connected.

Thanks for the tip with updating just sections who changed. I already into this… I expect them around -10ms. But 60ms total is allready perfect. At the beginning I was at around 130ms.

But I am still seachring for a better display… maybe colored or with much more brightness liebe a Sharp reflective display from Adafruit. Any suggestions there?

There’s a smaller version of what I use for VeGa, but it’s probably still too big.

Some thoughts about wiring things up. Ideally, we would have a single cable going out of DaVeGa that we can connect either to VESC or to the USB-UART adapter for programming.

There are 5 pins on VeGa:

  • 5V
  • GND
  • TX
  • RX
  • DRT

The VESC connects to the first 4. The USB connects to all.

Here’s the pinout of the devices to be wired up (for the VESC, this is how my ESCapes look like; I think that other VESC derivatives have a different pin order, but that doesn’t really matter):

32

Now, one option is to simply split 4 wires and add two connectors. That’s what I have done here. But, it’s pretty annoying having to split 4 wires and you end up with the dupont connector dangling around all the time when it’s only used rarely.

07

An alternative would be to make an adapter. It’s natural to go from more wires to fewer wires, i.e. from USB to VESC. But, that wouldn’t be very reliable since the dupont connectors tend to slide off. Plus, the device that’s plugged-in most of the time (the VESC) would go in via an adapter. Not ideal.

53

We can go the other way around, but that means the DTR wire would need to be separate. It’s not a problem to connect the 6 pin USB-UART to two (1+5 pin) dupont connectors. This would work just fine. We would end up with only a 1 pin dangling connector. No Y-splits needed.

34

An even better option would be to connect all 5 VeGa pins to the VESC and then make a simple adapter to the 6 pin dupont without the stand-alone wire for DTR. I think that it should be OK to connect the DTR to one of the VESC’s ADC pins. DTR is high (5V) in a normal state, but I believe the ADC pins are not used for anything by default. The only problem would be if the ADC is pulled low since that would reset the VeGa, but that shouldn’t happen. Could someone with a better knowledge of the VESC HW please confirm this? @Kug3lis maybe? Thanks! I know this is a hackish solution, but it seems the simplest and most elegant.

51

Last but not least, it’s not necessary to connect the DTR at all. Then we would need an extra button for resetting VeGa manually. It’s not hard to reset manually at the right moment when updating the FW. Still, it’s an extra button.

1 Like

After more thinking, we could just do this:

… but use JST XH instead of the dupont. The JST won’t slide off and 2.54mm spaced pins of the USB-UART can be plugged into a female JST XH directly. It would still mean the VESC goes in via an adapter, but I guess that’s fine.

2 Likes