How do lights talk to the controller?

Kagehik

New member
Local time
3:18 AM
Joined
Apr 13, 2023
Messages
13
Location
Lake Havasu City, AZ USA
Kind of had this question before but about specific parts. I am looking at a more general things. Near as I can tell a display for an ebike has more "symbols" and things on it that every motor controller knows about, can turn on/off, etc. Heck, my current controller will read the long press on the "mode up", button, then tell the display, "Ah.. turn on the light symbol!", despite the fact that the bloody thing doesn't turn the power on/off for either the display, or the wires they supply to run the lights off of. In any case I am curious if anyone out there has tested this, or knows how it works, and can confirm the theory of mine.

See, I figure that since there is a display symbol for, "You have applied the brakes", then light sets that have this feature, instead of watching to see if the power running through the brakes themselves, could "listen in" on the serial communications going on between the controller and the display, and if it sees, "Ah, the brake symbol was turned on!", and activate the brake light. The brake controls are basically interrupt switches, when you don't have them on the power passes through, but when engaged it cuts the power running through those pins. I tested the switch in a set to confirm this.

Now, I could be totally wrong, but I just asked the befang people directly how this works, and they gave a whole spiel about how I should just use the lights made by the same company as my ebike motor - except, they don't freaking make them with the whole set of features.

In any case, trying to figure this out, because either I will keep the current bike, or upgrade to a better one, but either way I want to bloody add full lights, including brakes and turn signal, and it would be kind of nice to know how "existing" sets actually detect things like brakes being applied, if they read the serial communications, or just watch to see if the power running through the brake wires it cut, etc. Do they turn on by having the controller power them, in which case I can't even install them on the current bike, since its controller won't do this, or, again, is it watching the communications and going, "Ah, someone turned the lights on!"

I mean, to me, it makes far more sense to watch the serial communications, and thus produce a "universal" light set, not try messing with wires that carry power, or other nonsense, which literally won't work if you have the wrong wiring/controller/motor, etc.

Anyone have any idea? Because, ironically, the company whose lights I was looking at either have no clue about their own design, or don't bother to know, since its made by some other company, or refuse to say. This is, needless to say, annoying.
 
On my bike, it is a mechanical button which sends a signal to the controller, which enables/disables power to the headlamp. There is no fancy high-speed serial bus involved in this feature. All the secondary headlamp button does is dim the display when engaged and has it at full brightness when not engaged.
 
Hmm. Yeah, wouldn't want any sort of fancy standardization, that actually listens to the controller... lol What frustrates me the most is that when I asked this question to both the maker of the lights I liked, and the people that make the parts I currently have on the bike, the responses I got where, in the same order, "We are not going to tell you. But buy the lights from the people you got the parts from.", and, "We have no idea of anyone else's lights are compatible with out parts". Needless to say, its damn stupid, if there is already a way for the display to be updated, based on what is going on with the lights, and brakes, for every manufacturer to have their own absurd solution, some of which don't even work right.

Case in point, my commentary on how the current parts correctly detect the same "if you hold this button it turns on the lights" signal, and even shows it going active on the display, but doesn't provide a way to run said lights using that feature. Just.. why? Why even have the controller implement the signal, and the display change, at all, if it doesn't DO anything? It also is likely the reason why using the wiring from the old controller failed with a communication error #10 - they kept the function, but rewired the controller so it expected the display backlight to always be on, effectively a) disabling the light switch function, and b) creating a condition where, if there is a split in the wiring, for lights, it malfunctions.

Why the F do this? I would think that having an upgrade/replacement kit that doesn't work right with everyone else's stuff would really annoy a lot of customers, especially if said customer found that half the stuff currently on their bike won't work any more, and they just "downgraded" by buying the replacement.

I mean, I suppose they maybe only intend them to be kits for upgrading non-ebikes to ebikes, but even then.. why would someone looking to upgrade to a better setup later buy their crap, if its missing features, or doesn't follow any sort of standards?

In any case, its looking more and more like, "If you want a full set of lights, which do everything, either buy a new motor, controller, etc. from the same company that makes the lights, or wire some up yourself." The later is.. complicated, because then you are worrying about how to power it - from the existing lights wiring, you have to worry about if the wiring can carry the amp load (I suspect no), while if you do it off a splitter at the battery you are suddenly dealing with 36v, 48v, or 56v wiring, a mess of step downs, to get the right power for the electronics, and a whole host of other madness.

This is just absurd when someone could just, in principle, build something that is universal and only limited by, "Make sure your controller supports these things. You can test this by looking for X and Y to show up on the display when you engage brakes, or turn on/off the existing lights on the bike." The current system of, "We have no idea if any of this stuff works with our stuff, or even possibly how any of it works at all, someone just shipped us a box with wires coming out, which they promised does what you told them we wanted.", is utter madness. imho
 
Kagehik,
This is why my taillight, turn signals, brake light, and alarm are a separate (all in one) isolated system as an add-on for my bike.
It came with a removable controller which gets mounted to the handlebars.
Sure, it is just one more thing to put on the handlebars, but it gets several tasks handled without cutting into wiring harnesses.

Sometimes I am willing to forgo integration for the sake of ease of install. There are several great headlamps with a built-in lithium battery to power them. Whether your headlamp is integrated, or separate, you still got to push a button to turn it on.
This means the human part (press a button to turn on the light) remains the same.

eBike design is evolving too fast for standard interfaces to take hold quite yet. Everyone is trying to one-up their competitor.
As a point of reference, fuel injectors for a Ford, don't work on a Chevy either. Neither does the Brain (ECU). Gasoline cars have been
main stream much longer than lithium powered eBikes.
 
On my bike, it is a mechanical button which sends a signal to the controller, which enables/disables power to the headlamp. There is no fancy high-speed serial bus involved in this feature. All the secondary headlamp button does is dim the display when engaged and has it at full brightness when not engaged.
Similar here. Thinking of my Juiced bike, there's a switch in the brake lever assemblies whose state is read by the controller. The controller then sends a signal for the brake lights to go brighter. (there's a microcontroller in the control module that reads the states of several inputs and changes certain outputs based on those inputs)

For the headlight, when I flip the switch on the switch cluster from low to high, the controller sees the change of state and energizes the high beam output and also the high beam symbol on the display.

It's just inputs and outputs and having each output rated properly. For example, I know the horn output on my bike is full battery voltage. I'm not sure if the switch handles the large current or if a MOSFET or relay handles it.

While it's nice to have turn signals, (so we can use our hands for braking instead of signaling as we approach a turn) I don't think I'd want to re-design the control system on my bike just to have it. It feels like one of those jobs where you'd run into one roadblock after another.

On this bike, some things are done with those simple switches. On others, it uses a GUI with three buttons on the display unit.

On my Aventon and Lectric, it's all GUI, except for the brake switches and torque and cadence sensors. (since it has no horn and the headlight function is done through the GUI.

The Electra has no built-in lighting and only a very simple GUI. (several LEDs and three buttons: power, PAS + and PAS -)
 
If I understand the Direction of the OP - summarize as "I want to be able to choose to prgram on/off every feature that my Controller has available in tandem that can be Switched on/off on my Display

Starting Off - please undertstand just because a additional feature might shown(Hidden) in-the-Display does not mean that is a real feature selectable in the Controller.

So far - what I see being "asked for" are "features" that are 12V power lead's - ex:headlight - where 12V is provided - contant on when bike is on - and that 12V drop is externally switched.
 
Hunted around a bit more, with different search terms and.. seems that controllers and their paired displays use one of three different communication protocols. Now, as to fabbrisd's comment on "requested features". Technically many of them do supply "some" of these.

The controller I have now have an entirely separate connector, and wire pair, that specifically was assigned as output for running lights on the bike - ironically, while the controller "responds to" the same "if you hold the up button it will turn on/off the lights", feature that many bikes use, and it shows an icon on the display, it doesn't *actually* turn on/off the power to this connection when you do so. So.. guessing they just used what ever firmware that was standard for the communication protocol they chose, but utterly ignored its features? Makes no sense to me.

In any case, looks like its still complicated to do this right (or even close to right), and I would need to work out which protocol is being used to get the brake light to work. Yeah, its possible to just watch for the voltage drop on the pin for the brake controls, but I have no idea what voltage is run through this connection, so it seems to me to be a higher risk to "detect" the brakes this way, compared to reading the serial communications. Have it short and maybe you lose the brakes, since it looks like its always powered, or your motor dies, because the connection is "always drawn to ground" - i.e., it thinks the brakes are always engaged. If you have something go wrong with a serial intercept, by comparison, you either get a) no working lights, but the bike should still work, or b) a communication error message, telling you something is wrong with the wiring. This seems "far" more sensible to me.

Hopefully at some people ebike developers come up with something better in the future, and more standardized (heck, even a simple set of dip switches that let you "select" which protocol your bike is using, like the old days of electronics.

There are signs that some states in the US might, and are already discussing, of ebikes are "motor vehicles", and thus would require a license. Seems to me that its not a massive stretch for either existing laws regarding such vehicles, or additional laws being passed, mandating that, in effect, "Since its kind of like a motorcycle, and a motocycle has to have brake lights, turn signals, and the rest, it should be a requirement for ebikes as well." As things stand, this is going to leave every manufacturer of them, who want to sell in the US, scrambling to fix something they should have thought of in the first place.

For myself, I just consider it a safety issue for my own bike - I ride to work in the mornings, to get there are before 6am, and there is less than one week out of the entire year in which this isn't in the bloody dark. Combine that with having been cut off at least 4 times by idiots that can't comprehend that, yeah, no matter how late you are getting some place, you still need to wait for someone in a left turn lane to actually stop at a stop sign, and make their own turn, before taking the same turn (or in one case just moving into oncoming traffic to not make the same left turn, but the flipping PASS me on the left, because I was "in the way"). This is, mind you, with some cheap, not terribly great, not imho wide enough to be clearly visible, "remote control" turn signals, which I have had on several occasions literally turn off on me, because I didn't charge the battery soon enough.

This is hardly "reliable" as signals go, and doesn't include a brake signal.
 
Hunted around a bit more, with different search terms and.. seems that controllers and their paired displays use one of three different communication protocols. Now, as to fabbrisd's comment on "requested features". Technically many of them do supply "some" of these.

The controller I have now have an entirely separate connector, and wire pair, that specifically was assigned as output for running lights on the bike - ironically, while the controller "responds to" the same "if you hold the up button it will turn on/off the lights", feature that many bikes use, and it shows an icon on the display, it doesn't *actually* turn on/off the power to this connection when you do so. So.. guessing they just used what ever firmware that was standard for the communication protocol they chose, but utterly ignored its features? Makes no sense to me.

In any case, looks like its still complicated to do this right (or even close to right), and I would need to work out which protocol is being used to get the brake light to work. Yeah, its possible to just watch for the voltage drop on the pin for the brake controls, but I have no idea what voltage is run through this connection, so it seems to me to be a higher risk to "detect" the brakes this way, compared to reading the serial communications. Have it short and maybe you lose the brakes, since it looks like its always powered, or your motor dies, because the connection is "always drawn to ground" - i.e., it thinks the brakes are always engaged. If you have something go wrong with a serial intercept, by comparison, you either get a) no working lights, but the bike should still work, or b) a communication error message, telling you something is wrong with the wiring. This seems "far" more sensible to me.

Hopefully at some people ebike developers come up with something better in the future, and more standardized (heck, even a simple set of dip switches that let you "select" which protocol your bike is using, like the old days of electronics.
They are not going to develop controllers specifically so some ultra-finnicky customer can tinker with it. They don't WANT us tinkering; it opens them up to potential liability. Features they feel it's OK for us to control, they program this into user interface and provide instructions on how to make the changes. The rest of the time, it's like your case: you bought a bike without the features you want and now you are banging your head against the wall trying to add them.


There are signs that some states in the US might, and are already discussing, of ebikes are "motor vehicles", and thus would require a license. Seems to me that its not a massive stretch for either existing laws regarding such vehicles, or additional laws being passed, mandating that, in effect, "Since its kind of like a motorcycle, and a motocycle has to have brake lights, turn signals, and the rest, it should be a requirement for ebikes as well." As things stand, this is going to leave every manufacturer of them, who want to sell in the US, scrambling to fix something they should have thought of in the first place.
The US government defines the three eBike classes and then leaves discretion up to the states, but does draw lines as to what the states can forbid.

What your saying would be counter to the US directions on the matter: (bolded parts were my emphasis)
Final Rule

As explained above, Secretary's Order 3376 directs the NPS to revise 36 CFR 1.4 and any associated regulations to be consistent with the Order. The Bureau of Land Management (BLM), U.S. Fish and Wildlife Service (FWS), and Bureau of Reclamation (Reclamation) are also revising their regulations for consistency with S.O. 3376. Specifically, the Order directs the NPS, BLM, FWS, and Reclamation to add a definition for e-bikes consistent with 15 U.S.C. 2085, and expressly exempt all e-bikes as defined in the Order from the definition of motor vehicles.
Look at this part: it specifically forbids these branches of government from considering eBikes as motor vehicles. Remember though that if one's "eBike" doesn't meet their definition, it is not considered an eBike and may be considered a motor vehicle. It's fair. For example, if I get pinched for riding my 1,000 W rated eBike around town, they have a legitimate cause to nick me. It's rated more than 750 W. I have no legal cause to complain. (the loophole is that there's nothing to prevent manufacturers from dual-rating their bikes; ex. "750 W sustained, 2 kW peak" and then in reality providing a motor and controller that will allow 2 kW sustained. Speed and weight limits are the way to go, not power. (just like engine displacement was a stupid way to go for mopeds, as engines got more and more powerful over time)

Source: https://www.federalregister.gov/documents/2020/11/02/2020-22129/general-provisions-electric-bicycles

For myself, I just consider it a safety issue for my own bike - I ride to work in the mornings, to get there are before 6am, and there is less than one week out of the entire year in which this isn't in the bloody dark. Combine that with having been cut off at least 4 times by idiots that can't comprehend that, yeah, no matter how late you are getting some place, you still need to wait for someone in a left turn lane to actually stop at a stop sign, and make their own turn, before taking the same turn (or in one case just moving into oncoming traffic to not make the same left turn, but the flipping PASS me on the left, because I was "in the way"). This is, mind you, with some cheap, not terribly great, not imho wide enough to be clearly visible, "remote control" turn signals, which I have had on several occasions literally turn off on me, because I didn't charge the battery soon enough.

This is hardly "reliable" as signals go, and doesn't include a brake signal.
Hmm. It seems like you're upset because some bad drivers. As a former motorcyclist, I can tell you that those people are going to be dangerous no matter HOW many lights are on your bike. I'd recommend asking the police to enforce those laws in those areas for awhile.
 
Ok. First.. Was not aware that there was a federal thing on the subject. Nice to know that the states, if/when they decide to do the increasingly common practice of thumbing their nose at the fed, and doing something anyway, said federal government might eventually do something about it.

That said, sure, I would like at least the illusion of added safety. This doesn't undermine my point. There is no reason "not" to do this, and while the decision to use multiple methods to having controllers talk to display makes it more complicated, its not an insolvable problem - as shown by the fact that at least one companies "does" provide something that works this way. I had hoped that someone here might have had an idea how it worked, and thus presented me with a way forward. They didn't. So, what we have is something like the silly mess between all electric car manufacturers, and their crap inability to fast charge well, if at all, and Tesla, who, crazy as they are (and not in the same sense as their chump CEO), actually thought it was a good idea to support such a feature from the start.

I hope that, as time passes, other manufacturers decide its a useful feature. I may be an utter fool in hoping this.

So what? This doesn't make me ultra-finnicky as you suggest. If the solution existed, but I insisted the lights where not big enough, they where the wrong color, I wanted more of them than available, and a whole f-ing list of other things, then it would be "finnicky", nah, outright ultra even. But, merely wanting a solution that doesn't require that I have to buy every part on the bike from the one and only company that makes one? That is just, "It would be nice, and here is why I think so." What is wrong with that exactly?
 
There are signs that some states in the US might, and are already discussing, of ebikes are "motor vehicles", and thus would require a license.
I don't see that anywhere. The impetus is to adopt 3-class legislation state by state. Last I heard we were up to something like 40 states, and the progression has been steady since California introduced the first 'model' version several years ago. Only Alaska regulates ebikes as motor vehicles at the state level (which translates to regulating rider behavior, which is not done at the federal level).

@Smaug noted some federal regs on the matter, but those are in fact late to the game. The laws on the books, first federal and then state by state came as follows... and note particularly below that what people call the federal 'laws' are not in fact laws at all. That first round is a regulation that manufacturers are subject to.

This is a really good quick synopsis of what 'regulation' actually means at the federal and state level (and in this case since this is an Ohio county web site they only talk about Ohio law):


The discussion of the Federal level is short at two small paragraphs, but I want to call out the line on jurisdiction:
Federal law regulates the manufacturing and first sale of an e-bike, but the rest is up to the state to regulate.
So the CPSC regulations, which state an ebike is a bicycle, are there to tell the manufacturer they need not comply with motor vehicle equipment regulations such as DOT-approved lighting and brakes, for example. Instead they need to comply with bicycle equipment regulations when they manufacture their product. Note also federal jurisdiction does not include personally-DIY'd bikes which, since they are manufactured privately and not subject to a first-sale, are outside of CPSC regulation and jurisdiction.

Below is the actual text of the CPSC regulation (not law). Note this regulation also dates back to 2002. Thus, THIS is the originating ebike definition/regulation in the USA.


So after the feds created the definition above, what is left is significant: How does the ebike fit into the vehicle code, which is a state-level thing. Also how should people behave while riding an ebike, and where can they ride one (for example Class 3 is excluded from shared-use paths)? Also regulated at the state and in some cases the municipal level. The next series of laws that came about to address ebikes was the 3-classes legislation that first came out in California, and has been adopted with few material changes in many states. Just how many depends on how old your source is. In January of 2023, it was 36 states and as of now it is either 38 or 40, depending on which source you quote. If you count the population of the adopting states... its pretty much everyone.

So where do the regs @Smaug was talking about fit in? A couple of years ago, the US Dept of Agriculture, who manages a lot of federally-owned land, issued proposed land use regulations that would allow ebikes onto said federal land. These proposed regs did not use the CPSC federal ebike definition, but instead used the 3-class, state-level definitions. Then they also classified ebikes as motor vehicles, but thats got nothing to do with fears of licensing and equipment regulation. That has everything to do with what kind of trail an ebike is to be allowed on. Federal land has trails where motorized vehicles are allowed, and trails where they are prohibited. Ebikes are not going to be allowed on trails designated purely for hiking and horseback for instance.

Once the Dept of Agriculture did their thing, a second round of agencies issued their proposed (and later adopted) regs which covers places like national parks.

This article covers that phase of the regulation process pretty well:

 
Back
Top