Page 1 of 1
Calculated Brake Pressure
Author Message
Calculated Brake Pressure
Hi Everyone,

Is it possible to create a calculated brake channel based on negative g acceleration in the forward direction?

I'm open to doing this post run via excel. Or alternatively via a calculated math channel in LUA.

I'm clueless as how I might correlate negative G to brake pressure.

Has anyone tried this?

Here is a way that it has been done.

http://www.jameshakewill.com/brake-trace.pdf

I wrote a script that included it which is in the second post here:

https://forum.autosportlabs.com/viewtopic.php?t=5227

Thank you!!!

###### Mustangkev wrote:
Here is a way that it has been done.

http://www.jameshakewill.com/brake-trace.pdf

I wrote a script that included it which is in the second post here:

https://forum.autosportlabs.com/viewtopic.php?t=5227

I found some time tonight to integrate your brakeg script. I ran into two issues; see bold. The first was the missing parentheses. Easy enough. The second was that brakeG was displaying acceleration Gs. I removed the sign switch and that fixed the issue.

###### Code:

local g1=getImu(0)
local u3=getGpsSpeed()
local b2=([b]-1*[/b]g1)-((u3^2/10000)[b])[/b]
if b2>0 then
setChannel(brakegId,b2)
end
local g2=getImu(1)
local g3=((g1^2)+(g2^2))^(0.5)
setChannel(totalgId,g3)

Now that I have brakeG I assume I point RaceRender at this channel as my brake input. How did you scale it from 0 to 100 for brake input? Can you set 0 Gs = 0 and my highest brake G as 100? This doesn't necessarily represent the brake pedal input. Am I missing something or is this as good as it gets without a brake pressure sender?

Yes, I did miss a parenthesis.

I haven't really played with this too much but your suggestion of scaling the result from 1-100 seems reasonable.

boggie what did you decide to do about scaling the data?

This worked great. Really good document to explain everything as well. Thank you.

I scaled it 0-100 and ended up needing to use 200000 instead of the 50000 called out in the PDF. Our 318ti chump car is a bit less aerodynamic than a Formula Ford used in the documentation haha.

 Display posts from previous: All Posts1 Day7 Days2 Weeks1 Month3 Months6 Months1 Year Oldest FirstNewest First
 Page 1 of 1
 You cannot post new topics in this forumYou cannot reply to topics in this forumYou cannot edit your posts in this forumYou cannot delete your posts in this forumYou cannot vote in polls in this forumYou cannot attach files in this forumYou cannot download files in this forum Select a forum Autosport Labs----------------General DiscussionNews and AnnouncementsNew Project Suggestions CAN Devices----------------ShiftX2AnalogX RaceCapture App----------------RaceCapture App Operation and General Q&ARaceCapture App Bug Reporting / Feature Requests CAN bus and OBDII integration----------------CAN mapping discussionOBDII PIDs discussion RaceCapture/Pro | RaceCapture/Apex | PodiumConnect----------------RaceCapture/Pro introductionsRaceCapture/Pro General Q&ASensorsHardware and InstallationLua ScriptingTelemetryBug ReportingFeature Requests RaceCapture/Track----------------RaceCapture/Track IntroductionsRaceCapture/Track OperationRaceCapture/Track InstallationRaceCapture/Track Bug Reporting / Feature Requests Megajolt/E and Megajolt Lite Jr. (MJLJ)----------------Ignition Map LibraryPowered by Megajolt GalleryAssemblyInstallationOperationQ&AFuture UpgradesBug ReportingFixes/Patches/UpdatesHard Rev Limiter