Fred's firmware development diary comments thread

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

Re: Fred's firmware development diary comments thread

Post by Fred »

Fair enough :-)
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!
davecramer
DIP8 - Involved
Posts: 18
Joined: Sat Sep 18, 2010 1:32 pm
Location: Orangeville, Ontario, Canada

Re: Fred's firmware development diary comments thread

Post by davecramer »

Serial communications options on a mac

http://hints.macworld.com/article.php?s ... 9133825654

I actually use zterm, while not a great app it works

minicom works as well.

Dave
User avatar
jbelanger
LQFP144 - On Top Of The Game
Posts: 387
Joined: Sat Feb 23, 2008 8:58 pm
Contact:

Re: Fred's firmware development diary comments thread

Post by jbelanger »

What's the point in going with 0.02 degree of timing resolution? What are the actual requirements for this? And I'm not being facetious but I simply don't see the point unless you're thinking of doing direct injection and even then I'd be interested in seeing actual requirements.

Jean
User avatar
Fred
Moderator
Posts: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary comments thread

Post by Fred »

This is the granularity of the calculations in the scheduler. IE, if the resolution was 10 degrees it would step by that much and never be in between, and so on. 0.02 is the smallest round number that fits inside 16 bits, there is no need for it to be this fine, but no or very small cost to doing this over any other arbitrary granularity. I hope that answers your question suitably. :-)
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
jbelanger
LQFP144 - On Top Of The Game
Posts: 387
Joined: Sat Feb 23, 2008 8:58 pm
Contact:

Re: Fred's firmware development diary comments thread

Post by jbelanger »

I understand that and it was obvious that this was to have the finest resolution in a 16-bit variable. I can see the use in doing computation using the finest resolution possible to minimize any computation errors but my question is more related to how you use this value. Are you going to try to schedule events at that resolution and what impact does using this have on other computations and processes down the line.

It's just that you seemed so concerned about saving memory and going through the (desired) software development process of getting requirements for the timing tables yet you seem to just go with that resolution for the scheduler just because it fits. I may well be wrong since I haven't looked at the code at all or anything related to it but hopefully you see my point. A 0.02 degree resolution represents 0.417us at 8000RPM so it's definitely not something you'd use for an angle clock for example (not that I'm saying you would).

Jean
User avatar
Fred
Moderator
Posts: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary comments thread

Post by Fred »

It's worth noting that my diary thread contains things from meta to micro and everything in between. I talk about tiny code implementation details and broader issues. If you read this garbage that I write, which you seem to, then you know that :-)
jbelanger wrote:and what impact does using this have on other computations and processes down the line.
This is the end of the line! :-)
It's just that you seemed so concerned about saving memory and going through the (desired) software development process of getting requirements for the timing tables yet you seem to just go with that resolution for the scheduler just because it fits.
This is an internal implementation detail. I can change the multiplier to any number from 1 - 91 (or is it 92?) and it will continue to work the same, just more or less well... The requirement was determined empirically when I could not specify the angles of the decoder events accurately enough to give reasonable RPM calcs on small angle differences because the 0.5 degree difference (worst case) was a sufficiently large percentage of such small angles to screw up the numbers entirely. I determined this a month ago, maybe more, and posted about it then. You didn't comment then, though :-)

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!
MotoFab
1N4001 - Signed up
Posts: 307
Joined: Thu May 29, 2008 1:23 am
Location: Long Beach CA

Re: Fred's firmware development diary comments thread

Post by MotoFab »

Fred wrote:I determined this a month ago, maybe more, and posted about it then. You didn't comment then, though :–)
As you do all the determinin', it may not have mattered if he had. :–)

Jim
User avatar
Fred
Moderator
Posts: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary comments thread

Post by Fred »

MotoFab wrote:As you do all the determinin', it may not have mattered if he had. :–)
Others are always welcome to do ground work, research and provide genuine fixes and contributes ;-)

All I did was take readings with code and data and figure out that there was no possible data point that was perfect, both 68 and 69 were wrong, despite mitsi/mazda recommending 70. 68.7 will be my next guess, probably. I can't fine tune it without a real sensor, though.

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: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary comments thread

Post by Fred »

I have to say, it was really nice the night before last to adjust the decoder to engine offset (ms calls it "trigger angle") by 0.02 degrees and have it EXACTLY correct :-) We needed 1.52 degrees to correct it after the final course change. Of course, you'll say I couldn't be that accurate with my eyes, but you forget the CNC nature of my body, esp eyes and elbows :-) It was rock solid and perfectly centred, one degree would not have gotten us an exact base timing. 0.1 would probably have been good enough, but the extra finesse came at no cost, so...
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: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Fred's firmware development diary comments thread

Post by Fred »

RPM and sync on the LT1 today, but the base firmware needs some changes before it can run Sean's engine. I'll get it done over the next few days while we wait for some parts to arrive. Exciting times! :-)
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!
Post Reply