ABS bass shaker (cu...
 
Notifications
Clear all

ABS bass shaker (custom) effect

2 Posts
1 Users
0 Reactions
148 Views
(@simke)
New Member
Joined: 1 month ago
Posts: 2
Topic starter  

Hey there, hopefully this is a new question, did not manage to find anything similar.

I have a small bass shaker attached to my brake pedal, which I use for, among other things, ABS activation vibration.

Regardless of the effect settings, the end result is always the same, once ABS is triggered and active, the shaker vibrates at the set frequency.

This all works great and as intended, however, is there a way to pulse the ABS audio output to the shaker, hence mimicking the ABS activation? I'd like this, since my shaker is strongest at around 70hz, which is way more than the ABS sensation, at around 15-20hz.

I guess my question is, is there a way for the signal to be active for example 50ms at 70hz, followed by a pause, then active again, pause, etc, until the ABS is active. Basically, if there was a parameter to set the "pause/break" with the pulse duration, which is already on the UI, this would be perfect.

Maybe there's a custom effect script that already exists (for iRacing)? Shoud this go into feature requests?

Thanks for the solution direction 🙂

This topic was modified 1 month ago 3 times by simke

   
Quote
(@simke)
New Member
Joined: 1 month ago
Posts: 2
Topic starter  

I created a JS script for a custom effect to achieve this. You can fiddle with pulseDurationMs and cycleDurationMs values to your liking.

 

End result:

 

// Check if ABS is active using $prop('ABSActive')
if ($prop('ABSActive') === 1) {
    // Define timing parameters
    let pulseDurationMs = 45;   // 45ms active duration (middle value)
    let cycleDurationMs = 83.33; // Middle value: ~12 pulses per second

    // Get the current time in milliseconds
    let currentTimeMs = new Date().getTime() % cycleDurationMs;

    // If the time is within the pulse active period (first 45ms of each ~83ms cycle)
    if (currentTimeMs < pulseDurationMs) {
        // Return 100 for the active pulse (full intensity)
        return 100;
    } else {
        // Return 0 during the pause period (no vibration)
        return 0;
    }
} else {
    // ABS is not active, return 0 (no vibration)
    return 0;
}   

 

 

This post was modified 1 month ago by simke

   
ReplyQuote
Share: