Fred's firmware development diary

Official FreeEMS vanilla firmware development, the heart and soul of the system!
User avatar
Fred
Moderator
Posts: 15433
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary

Post by Fred »

More USBDM hell. Now it won't work on the EEE at all, either. I did find a fix for the small monitor thing, though. It's not devilspie, which the USBDM app ignores the commands of, rather this:

Code: Select all

xrandr --output LVDS1 --mode 1024x600 --fb 1024x1024 --panning 1024x1024
bdm&
sleep 1 # maybe 2 sometimes
xrandr --output LVDS1 --mode 1024x600 --fb 1024x600 --panning 1024x600
IE, give myself a scrollable view port through which to look at an imaginarily big desktop.

Success! Looks like the cable between the BDM and the device is too long. Having it straight makes it work. Any kinks = fail. Can't blame that on Mr BDM Australia. My single biggest reason to not like that country right now.

Fred.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
Fred
Moderator
Posts: 15433
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary

Post by Fred »

viewtopic.php?f=55&t=1938&p=34361#p34361 time for some progress on lucky number 13, I think! :-)
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
Fred
Moderator
Posts: 15433
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary

Post by Fred »

I need some replacement "development" equipment, any advice or generosity gladly accepted: viewtopic.php?f=13&t=2147
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
Fred
Moderator
Posts: 15433
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary

Post by Fred »

And the mouse too, what fun. viewtopic.php?f=13&t=2149

You should see my jeans and underwear :-p They're also in a bad state of disrepair. Gotta turn this around somehow, and soon.

Fred.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
Fred
Moderator
Posts: 15433
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary

Post by Fred »

Help designing T-Shirts for printing VERY SOON! Please: viewtopic.php?f=41&t=2152
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
Fred
Moderator
Posts: 15433
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary

Post by Fred »

Working on improving the RPM calculation setup and using Sean's R1 which is 4 cylinder with a 720 degree decoder current calcs have a step of 69 RPM (from 12042 to 11973 taken from his log 0.2.0-SNAPSHOT-173-g19e741f-DEV-SEANKR1 / Sat Sep 15 10:42:15 MST 2012). New code on the other hand, correctly configured, will have a step size of just 4 by default (@ 12100 RPM), and a step size of just 1 if I add an optimisation. The optimisation will only really help large cylinder count engines that turn high RPMs. At lower RPMs the step size will be that of the variable, IE, 0.5 RPM. The new way that I'll be doing it is optimal, period. To do better requires a finer timer resolution, which isn't a good idea, and would be largely pointless. This is a nice improvement in performance, and will later be supplemented by improved sched calculations too. The main benefit of the new calculations is NOT the accuracy, but rather the smoothness of data. Current code has values which jump around a lot, this doesn't matter much in practice as they are typically used from a consistent location/value. But the logs look very ugly... and that's not good for publicity :-p This post typed in very very slowly with one hand... :-/
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
Fred
Moderator
Posts: 15433
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary

Post by Fred »

Here's a screen shot of the problem, file name is "ULV.SeansR1.peak.RPM.limiter.poor.granularity.png" which describes what it is pretty well:

Image
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
Fred
Moderator
Posts: 15433
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary

Post by Fred »

From that same log, and I may have posted this before, the DRPM figure is:

60091 - 60364 = 273ms
4588.5 - 12042 = 7453.5 RPM change
(7453.5 / 273) * 1000 = 27302.1978022

Final of 27302 RPM/second, which is quite a lot.

If we assume our main loop is horribly slow @ 10ms, then we have a 273 RPM difference from one calculation to the next, and a potential error, if we're not taking rate into account, of:

273 / current RPM % in our timing calculations.

On the brighter side, under acceleration, timing will be retarded, only under deceleration of the same rate will it be advanced more than the tune. The only time this is a real problem is when the clutch hits hard while under load. Be warned.

Fred.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
Fred
Moderator
Posts: 15433
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary

Post by Fred »

I have about 500 lines added for the RPM calculation change, and I'm about half way through. Hopefully I can get it usable/testable tomorrow some time.

Also from the above mentioned log: 96 milliseconds from closed throttle to wide open throttle. This indicates TPS readings need to be taken every 10ms or less to be effectively useful.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
Fred
Moderator
Posts: 15433
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary

Post by Fred »

If anyone knows of one of these laying in the back of a garage somewhere, hit me up: viewtopic.php?f=28&t=2157
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Locked