Zombiverter Din_Brake will it trigger BrakeLight D_out

Post Reply
alucas
Posts: 32
Joined: Tue Jan 21, 2025 3:37 am
Has thanked: 4 times
Been thanked: 2 times

Zombiverter Din_Brake will it trigger BrakeLight D_out

Post by alucas »

I have my brake sensor wired to Din_Brake and my brake lights are on a relay run by the BrakeLight output using SL2Func. When I press the brakes I don't get brake lights.
I think that the BrakeLight is only triggered via regen braking and that is why I don't get bake lights when the car is sitting not in run mode and not regen braking. I just wanted to check that is the case before I go do some funny wiring. I like the relay as it is a combo fuse-relay setup, and my rewiring to have both regen baking and the old braking would bypass the fuse and use the old cars system which has 3 fuses for the whole cars electrical system. :)

Is my assumption about BrakeLight correct?
User avatar
manny
Posts: 195
Joined: Sun Jan 23, 2022 4:15 pm
Location: Netherlands
Has thanked: 58 times
Been thanked: 159 times

Re: Zombiverter Din_Brake will it trigger BrakeLight D_out

Post by manny »

Yes regen only

Code: Select all

if (Param::GetInt(Param::potnom) < Param::GetInt(Param::RegenBrakeLight)) {
    // enable Brake Light Ouput
    IOMatrix::GetPin(IOMatrix::BRAKELIGHT)->Set();
  } else {
    IOMatrix::GetPin(IOMatrix::BRAKELIGHT)->Clear();
  }
[DRIVING] Citroen Saxo electrique
  • Volvo ERAD motor, XC90 inverter/DCDC (custom OI board)
  • PSA battery (50kWh)
  • Foccci and MG ZS charger 6.6kW
  • Zombie VCU
alucas
Posts: 32
Joined: Tue Jan 21, 2025 3:37 am
Has thanked: 4 times
Been thanked: 2 times

Re: Zombiverter Din_Brake will it trigger BrakeLight D_out

Post by alucas »

I ended up modifying the code so that when the bake is pressed the BRAKELIGHT goes on.
User avatar
tom91
Posts: 2962
Joined: Fri Mar 01, 2019 9:15 pm
Location: Bicester, Oxfordshire
Has thanked: 328 times
Been thanked: 847 times

Re: Zombiverter Din_Brake will it trigger BrakeLight D_out

Post by tom91 »

alucas wrote: Tue Apr 07, 2026 4:49 pm I ended up modifying the code so that when the bake is pressed the BRAKELIGHT goes on.
I would strongly suggest you do not rely purely on the zombie to turn your brake lights on and always retain the "OEM" method and parallel the zombie one. If the zombie fails for whatever reason you still have the 12V wiring/relays to fall back on.
Creator of SimpBMS
Founder Volt Influx https://www.voltinflux.com/
Webstore: https://citini.com/
modellfan
Posts: 177
Joined: Tue Jul 12, 2022 11:20 am
Has thanked: 20 times
Been thanked: 61 times

Re: Zombiverter Din_Brake will it trigger BrakeLight D_out

Post by modellfan »

Is there any reason , why this regen brake light is not implemented for sdu ?
User avatar
tom91
Posts: 2962
Joined: Fri Mar 01, 2019 9:15 pm
Location: Bicester, Oxfordshire
Has thanked: 328 times
Been thanked: 847 times

Re: Zombiverter Din_Brake will it trigger BrakeLight D_out

Post by tom91 »

Who knows, its a completely different code base. also I believe the tesla boards were running low on IO pins so some functions were not included.
Creator of SimpBMS
Founder Volt Influx https://www.voltinflux.com/
Webstore: https://citini.com/
User avatar
allard
Posts: 8
Joined: Mon Jan 08, 2024 1:39 pm
Location: Amsterdan NL
Has thanked: 3 times

Re: Zombiverter Din_Brake will it trigger BrakeLight D_out

Post by allard »

tom91 wrote: Tue Apr 07, 2026 5:12 pm I would strongly suggest you do not rely purely on the zombie to turn your brake lights on and always retain the "OEM" method and parallel the zombie one. If the zombie fails for whatever reason you still have the 12V wiring/relays to fall back on.
I think Tom is right; from a security perspective it is better to leave the OEM wiring. However if you, like me, don't have the wire anymore and it is hard to rewire because it is in an unreachable place, you can consider using this code:

Code: Select all

selectedInverter->SetTorque(torquePercent);


  // START Brake light control - activate on regen OR physical brake press
  bool brakeLightOn = false;

  if(Param::GetInt(Param::potnom) < Param::GetInt(Param::RegenBrakeLight))
  // Check for regen braking
  if(torquePercent < Param::GetFloat(Param::RegenBrakeLight))
  {
      brakeLightOn = true;
  }

  // Check for physical brake press using parameter
  if(Param::GetBool(Param::din_brake))
  {
      brakeLightOn = true;
  }

  // Set brake light output
  if(brakeLightOn)
  {
    // enable Brake Light Ouput
    IOMatrix::GetPinOut(IOMatrix::BRAKELIGHT)->Set();
  } else {
    IOMatrix::GetPinOut(IOMatrix::BRAKELIGHT)->Clear();
  }

  // END Brake light control - activate on regen OR physical brake press
  
  // speed = ABS(selectedInverter->GetMotorSpeed());//set motor rpm on interface
  // NO ABS allowed on speed as we need to know direction
  speed = selectedInverter->GetMotorSpeed(); // set motor rpm on interface
see also:
https://github.com/daan0308/Stm32-vcu/t ... eak-input_

I think it would not hurt to add this to the code base anyway since it can also work in parallel with the OEM wiring.

Allard
alucas
Posts: 32
Joined: Tue Jan 21, 2025 3:37 am
Has thanked: 4 times
Been thanked: 2 times

Re: Zombiverter Din_Brake will it trigger BrakeLight D_out

Post by alucas »

Thanks Allard for the reply
I agree it would be nice to have this added to the code base as it shouldn't have any impact, for those with the old and new HW connected. It would make things easier for you, me and maybe a few others.
Post Reply