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 »

I was thinking about which Git commands I've used over the last 11 days or so.
  • stash
  • stash apply
  • rm <path(s)>
  • add <path(s)>
  • commit [path(s)]
  • commit -a
  • reset --soft <rev>
  • reset --hard <rev>
  • remote add <branch> <remote branch>
  • branch
  • branch <new branch>
  • checkout <branch>
  • push
  • pull
  • clone
  • svn clone
  • tag -F <file> <name> <rev>
  • status
  • diff --stat [params]
  • diff --shortstat [params]
  • diff [params]
  • log [params]
  • fsck
  • show
  • prune
  • gc
In no particular order.

I can now tell you what all of the above do and how you use them more or less. I wrote that list on paper while waiting for my hair cut. Now the hair on my chin is about as long as that on my head. Clearly I need to shave. I may do that later.

The above commands combined with some manual reading and .git/config file editing will get most stuff done. It's really not that hard if you sit down and play with it. Worst case is that you copy your work away when you are playing with it so if you screw it you can recover. And push upstream to your fork as often as you are sure it is a good idea to do it. Simple :-)

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 can now add:
  • cherry -v <branch>
  • cherry-pick <rev>
  • merge <branch>
  • mergetool
To the list of Git tools I've played with :-)

Consequently Sean's stuff is merged into the my master branch.

Sean should, when he gets home from his holiday, pull my changes and reset --hard HEAD to zero him in on the same stuff as the public master. Then he should push up to his public and we should see a pretty graph :-)

I'll do further doc changes tonight. I'll release what I have on sunday night as 0.0.19 and move on with talking to the tuning app and ironing out the hardware information. The rest of the doxy stuff can be gradual as I (or others!!!) come across it.

I think in order to have a running engine by the end of feb I need to really focus on a few aspects :

Serial comms with the tuner
Scheduling algorithm creation
Nippon Denso wheel decoder completion
Ignition logic code - first version will feed a fuel channel for now

These would also be nice-to-haves :

Math tidy up
Warm up algorithm
Transient algorithm

I'm fully aware that the hardware stuff can't move without further input, but I think getting something working should take priority and we can build hardware for it after it goes. I'll be working on that during weekends where time permits.

In order to get my engine running I also need to complete my graft between xdp and toy ecus.

8 weeks to do at least :
  • Serial comms with the Tuner
  • Scheduling algorithm creation
  • Nippon Denso wheel decoder completion
  • Ignition logic code
  • OEM ECU hacks to Toyota hardware
It's doable! (just)

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 »

Idea :

Duplicate some of the counters (all maybe) and have a main loop routine that iterates through the ones that are incremented by ISR code looking for non zeros, sends appropriate error codes and for each error sent, decrements the matching counter in the first bank and increments it in the second.

This way you get to know about errors etc in close enough to real time and you don't lost track of how many have occurred total.

Another enhancement that I'm intending to do is add an args region to the error packet definition. That way I could reduce it to sending the count of errors since last check and reset the counter while adding its value to the other bank.

Just noting this here until I get a chance to do something about it.

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 »

Close to half of the .c files are now documented in the public master branch.

I should finish that tomorrow and be able to do my first release from Git :-)

0.0.19 will be out soon, on with the real stuff again!

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 »

Probably much the same as the last release, but for those that don't look at Jared's Doxygen pages, here is a sample freshly generated from the latest dev code :

Image

Cool ey? :-)

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 »

Code: Select all

/home/user/workspaces/home/freeems-vanilla/src> cat ../.git/config 
[core]
        repositoryformatversion = 0
        filemode = true
[remote "origin"]
        url = git@github.com:fredcooke/freeems-vanilla.git
        fetch = +refs/heads/*:refs/remotes/origin/*
[remote "seansrepo"]
        url = git://github.com/seank/freeems-vanilla.git
        fetch = +refs/heads/master:refs/remotes/seansrepo/master
[branch "master"]
        remote = origin
        merge = refs/heads/master
[branch "public"]
        remote = origin
        merge = refs/heads/master
[branch "release"]
        remote = origin
        merge = refs/heads/release
[branch "seank"]
        remote = seansrepo
        merge = refs/heads/master
/home/user/workspaces/home/freeems-vanilla/src> git remote show origin
* remote origin
  URL: git@github.com:fredcooke/freeems-vanilla.git
  Remote branch merged with 'git pull' while on branch master
    master
  Remote branch merged with 'git pull' while on branch public
    master
  Remote branch merged with 'git pull' while on branch release
    release
  Tracked remote branches
    master release
/home/user/workspaces/home/freeems-vanilla/src> git remote show seansrepo
* remote seansrepo
  URL: git://github.com/seank/freeems-vanilla.git
  Remote branch merged with 'git pull' while on branch seank
    master
  Tracked remote branch
    master
Sweet :-)
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 »

Now Sean is almost up to date, and Abe has forked and played a little there is a pretty graph to see :

Image

Hopefully we can have some vertical lines in it in future!

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 think I've at least mostly completed doxygenating the header files. I now need to go through the source files, document each one, and each function within each one. Still lots to do, but it's coming together nicely.

I'll try to get some actual work done in the morning rather than the docs. I'll structure and split up the fixed config stuff. I may even add more configuration stuff to it. I'll add all the blocks to the dictionary too.

If I get further time I'll try to work on the JSON files. This weekend I'll work on the hardware docs some more and probably start work on the scheduler as that is key to running an engine well soon. It also lays the foundations for others to build different decoders such as nissan, miata, missing tooth and subaru.

As always, lastest changes are pushed to the server as I type.

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 would imagine that by the end of tomorrow I'll have the doxygen stuff pretty much out of the way. I have done half of the .c source files now. The other half to go and that is about it really. After that it's fine tuning from the doxy kid and suggestions etc from others.

In more exciting news :

Image

Mint, Sean has merged my stuff back into his branch. Next time I take something from a brancher it will be a totally clean change set that i will just merge. That will give us more of such lines which are pleasing to the eye and mind :-)

I will still attack the fixed config structuring soon, I'll branch for the scheduler as well and start work on that at some point soon. 0.0.20 will be all about serial talking with Aaron and docs around that. Hopefully we can produce a working pair of releases by mid Jan. That will free me up to work on the few remaining things that need to be done before the engine will run with this controller.

Exciting times :-)

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've been working on the Makefile. How dull you say. Well, yes and no. You see, this new make file will build N firmware S19 files and associated memory maps and debug files. Why would you want that? Decoders. The time has come to get humming and have multiple people submitting code to the project at the same time. With this setup anyone can submit decoders and they will only have to update the makefile and it wont affect the rest of the code at all. Pretty cool! I'll have that finished tomorrow and Sean, Subaru man, and others can start work on their particular interests.

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