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 »

Day 43:

Replaced plugs and checked for 4 cyl operation, all good
put rubber edging around gauge cluster
pulled bench seat out, test fitted rails, measured up seats, spacing, rails, on 3 mazda vehicles
powered up my puma and tested it for serial monitor action, failed to run freeems code due to reset issues to be solved tomorrow
specced what I need to do code wise to achieve my goal
drank 2 bottles of wine between 3 people to celebrate, cab sav and cab shiraz penfolds something or other hill 2008, very good value (12/13nzd on special), nice enough wine
tempered various angry sleepless neighbours...
tidied up garage/tools/parts quite a bit, more to do, though

Refer yesterday for next 3 days. This thread should be back on topic again as of now... Thanks for your patience! :-)

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?p=13008#p13008

Refer to this post and subsequent posts for my hw development.

Today I also picked up a couple more seats and rails and spent some time test fitting them and have a game plan for getting the GTAE seats into the ute. I also tested the db37 loom and sussed out which pins go to which injectors ready for sequential with FreeEMS. Next up is to either find a matching plug for ign, swap to a diff plug i have two of, or integrate ign drive through the db37 also. Along with mount the seats, and the PCB stuff and code stuff.

More later tonight, hopefully, in either this thread or the linked one, or both.

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 »

Oh, and FreeEMS ran on my Puma card in NZ about an hour ago :-) Hooray! I guess that's two countries for puma+freeems on the bench, now. Who is next? Come on guys! :-)
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 »

The last 3 days were insane, I spent them trying to get a puma completed and installed and trying to write enough code to run my truck, I failed by a matter of a day or a few hours or something. The deadline was a car meetup and about 30 people showed up, and there was a lot of attention around the Puma boards (and me/the truck in general), which was good. The more high profile vehicles get Puma+FreeEMS on them ASAP the better. I'll be running it in a few days, who will be next? Marcos? SeanK? Are there any other serious contenders? AbeFM?
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 »

This morning I worked with Dave to get FreeEMS table tuning into MTX, IE, he added functionality, I fixed minor bugs and advised on things. Here we have the result :

Image

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 »

A log captured with MTX/Tunix displayed using the new java log viewer:

Image

Each of the false RPMs indicates sync on a different event number. RPM is event number * 500, see the code comments for event number details if you're interested.

The forum for the log viewer is here:

viewforum.php?f=32

Get using it and get gufi some feedback :-)

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 »

8am, a fine time to be posting, especially after staying up all night hacking and testing and thinking and tossing ideas back and forward with other devs.

I've been doing some RPM cranking tests, and they didn't succeed completely, there is a bug in there. Not surprising considering the lack of sleep, and probably not too hard to find and fix, either.

In one direction I get 3 similar RPMs and in the other I get 1 wildly wrong RPM. I'll have to think about and test the polarity/inversion of the input and mull over the logs more before I make any changes.

Image

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 »

Still hacking away, the challenge is getting information out of the device in an accurate and presentable way. Tomorrow morning i'm going to verify my disk measurements with the first real application of my logic analyser idea. Gufi's log viewer can/will be adjusted to handle such logs and provide a nice little tool for future dev of decoders (and ign).
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 »

figured it out! The LED reads the gaps WIDER than they are, not surprising, the light could sneak around the edge, i guess.

I got these numbers for rpm from my code:

0 170.5
1 108
2 140.5
3 107.5
4 139.5
5 107.5
6 139.5
7 162
8 108
9 162

number measured between tooth on same line, and tooth on line before.

I saw the two 162 measurements and realised that it's high there because those are based off of two end of light slots rather than one end of light and one end of dark with the two ends one worse than the other due to being by percentage and being a longer slot. the 170.5 figure is more wrong because its got two errors towards each other!

So, solution is:

remove plugs to remove compression effects and use a flat battery to slow the engine down, and take a binary logic analyser log device, and then base my array of angles from that. Then the RPM will come right (the code was fine) and I can readd the desyncing code based off the periods (which were wrong due to angles being wrong) and everything will be golden. So, on sunday arvo NZn time, I'll be back, with a flat battery, no plugs, some minor code adjustments, and binary packets ready to swap log types, and as soon as I setup those numbers in the array, I can work on scheduling and dwell and fuel output, even in a rough way. Expect the truck to run FreeEMS on Sunday arvo NZ time :-) There could be other issues, but I reckon it'll be sweet.

Disk/Sensor measurements screwed me... nevermind, i've got it sorted now!

Pics/files:

Logic analyser display:

Image

bin file, use OLV for that:

http://stuff.fredcooke.com/portT.min.1.la

http://stuff.fredcooke.com/4and1.finall ... mpling.png - too long for phpbb3 image tags, apparently...

Image

Solved! :-)

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 »

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