Simple high/low signal from VESC to operate a solid state relay

Support for creating custom user applications on the VESC.
fpage
Posts: 3
Joined: 25 Jun 2018, 04:09

Simple high/low signal from VESC to operate a solid state relay

Postby fpage » 25 Jun 2018, 04:44

I have a hardware version 4.12 VESC set up to be operated from my phone, and I would like to add the ability to turn my longboard's headlights off and on through this interface. I was hoping to be able to do this by sending a simple high/low signal from one of the vesc pins to a solid state relay, but am unsure as to whether any of the pins are suitable for this purpose. I believe that it would need to be able to alternate between ~0V and ~5V,<50 mA. Does anyone have any advice?

rew
Posts: 943
Joined: 25 Mar 2016, 12:29
Location: Delft, Netherlands.

Re: Simple high/low signal from VESC to operate a solid state relay

Postby rew » 25 Jun 2018, 08:30

The VESC doesn't have any negative supplies, so any voltages below zero are out of the question.

The specs you list may be from a TRIAC like device. Those are used inside solid state relays, but are for AC only.

You would want to use something like a mosfet for DC. Now signals from the VESc are going to be 0V ("low") or 3.3V ("high"). For many high-power mosfets that's too little to turn on properly, but if the application does not require high power, maybe we can find something.

Do you have 12V? What are you going to run the headlights off? What voltage needs to be switched to turn the headlights on?

fpage
Posts: 3
Joined: 25 Jun 2018, 04:09

Re: Simple high/low signal from VESC to operate a solid state relay

Postby fpage » 25 Jun 2018, 14:54

My plan was to run the headlights off of the board's 8s battery. All of the lights are ~4 V, 1 W, and there will be four of them in parallel on the same supply line. From searches on Mouser and DigiKey, it seems like it's possible to convert the 25.6-33.6 V from the battery to the 4 V required for the lights, but perhaps this is not the case. Optimally, the path of the circuit will be
(battery-->solid state relay-->voltage regulator-->headlights-->battery), although the positions of the solid state relay and voltage regulator can be swapped if that would be a better setup.

TilmanBaumann
Posts: 15
Joined: 15 Feb 2018, 16:50
Location: Germany

Re: Simple high/low signal from VESC to operate a solid state relay

Postby TilmanBaumann » 26 Jun 2018, 07:33

On a side note, I would eat my hat if that wasn't a LED headlight. It might be designed to run on a constant voltage (with a protection resistor) but it's also quite likely that is expecting a constant current. (I'm assuming this because of the very odd voltage of 4V)

Consider using a constant current source rather than a voltage regulator. A lot of LED drivers have enable pins as well that would allow you to toggle the light, cutting down on parts. (You probably still need a 5V source)
Just some random thoughts.

The real issue remains, how would you drive the IO pin with logic level. Once you got that, flashing a LED is the least of your problems.

fpage
Posts: 3
Joined: 25 Jun 2018, 04:09

Re: Simple high/low signal from VESC to operate a solid state relay

Postby fpage » 26 Jun 2018, 23:34

Yeah to be more specific, I was planning on wiring up this bike light
https://www.trekbikes.com/us/en_US/equi ... t/p/12535/
that usually takes 3 1.5 V AAA batteries to power a 1 W LED.

TilmanBaumann
Posts: 15
Joined: 15 Feb 2018, 16:50
Location: Germany

Re: Simple high/low signal from VESC to operate a solid state relay

Postby TilmanBaumann » 28 Jun 2018, 13:13

Those LED take 5V 1A if you want to rewire them.


Return to “Custom Applications”

Who is online

Users browsing this forum: No registered users and 0 guests