Page 1 of 2
Installing tools
Posted: Fri Apr 19, 2013 9:31 pm
by andg
So I did a writeup from installing the tools
on github for my mac
Re: Installing tools
Posted: Sat Apr 20, 2013 12:13 am
by Fred
Fink stuff is likely way out of date. I use a native setup that Dave did ages ago. In general macports is the preferred tool set on Mac for everything except firmware, though. Sorry about shitty tool support for non-"32 deb" :-(
Re: Installing tools
Posted: Sat Apr 20, 2013 5:48 pm
by andg
I will get a dedicated ubuntu machine then. If I understand you correctly it ought to be 32 bit.
Re: Installing tools
Posted: Sat Apr 20, 2013 8:21 pm
by Fred
A deb or ubuntu VM isn't a bad idea right now, sadly. You CAN use Mac, I do, but the fink package is WAY old.
git clone that git://github.com/djandruczyk/FreeEMS-OS-X-toolchain-builder.git
I'm on hash 72f519d762619b046cbd1c7a1369ffa2a7f7aaa3, maybe. I have a bunch of variants built on my file system, and just change their path depending on which I want to use.
This doesn't require fink or macports. You will need macports anyway to build QT tools like EMStudio and Sean's loader. Fink may work, but it's been a LONG time since I tried.
Fred.
Re: Installing tools
Posted: Tue Apr 23, 2013 3:48 pm
by andg
Good ol' dependencies:
Code: Select all
andg:mc9s12x-OS-X-toolchain-builder andg$ ./make_OS-X_toolchain
LLVM compiler detected, searching for alternative...
gcc is unsuitable
gcc-4.2 is unsuitable
i686-apple-darwin11-llvm-gcc-4.2 is unsuitable
llvm-gcc is unsuitable
llvm-gcc-4.2 is unsuitable
Invalid args, need <all|get_pre_reqs|clean>
andg:mc9s12x-OS-X-toolchain-builder andg$
Code: Select all
sudo port selfupdate
sudo port install gcc-select
sudo port select --list gcc
This informs me I have:
Code: Select all
Available versions for gcc:
llvm-gcc42
none (active)
I'll compile it with llvm-gcc42 for now.
Code: Select all
sudo port select --set gcc llvm-gcc42
./make_OS-X_toolchain
I get the same error message and this time I read it more carefully. It mentions gcc 4.2 is unsuitable not that it can't be found. I am trying this:
Code: Select all
sudo port select --set gcc mp-gcc45
Code: Select all
./make_OS-X_toolchain
Invalid args, need <all|get_pre_reqs|clean>
looking much better, now running:
measures of sweet success
Code: Select all
Cloning binutils git tree locally
Cloning into 'FreeScale-s12x-binutils'...
remote: Counting objects: 221807, done.
remote: Compressing objects: 100% (40787/40787), done.
remote: Total 221807 (delta 180287), reused 221241 (delta 179721)
Receiving objects: 100% (221807/221807), 75.81 MiB | 1.71 MiB/s, done.
Resolving deltas: 100% (180287/180287), done.
Downloading GCC from seank's repo
Cloning into 'FreeScale-s12x-gcc'...
remote: Counting objects: 16278, done.
remote: Compressing objects: 100% (12179/12179), done.
Re: Installing tools
Posted: Wed Apr 24, 2013 2:07 am
by andg
output of cat README truncated:
Code: Select all
...
sudo mv toolchain /opt/FreeEMS-Toolchain
export PATH=$PATH:/opt/FreeEMS-Toolchain/bin
Here I've personally elected to mv to a subdirectory of my home directory where /opt = ~/git/freeems
Code: Select all
sudo mv toolchain ~/git/freeems
export PATH=$PATH:~/git/freeems
but that won't survive a new iTerm session, or the whole bash paradigm so I'll have to update what I do in time with this. Besides I'm likely to just write code on this machine anyway, so I may not be doing any uploading of firmware from this directory. I take separate QA and deployment threads like any good engineer.
The first thing that strikes me about this directory is the complete lack of documentation. Even if this is a compiled version I can't navigate it. Just saying--don't kill the msg(r)
Here is some of my favorite documentation
Edit: I'm realizing these are the tools to interface with the FreeScale architecture to load the firmware. I will need to modify the code to reflect that this isn't the firmware code but rather the freeems-tools
Re: Installing tools
Posted: Wed Apr 24, 2013 2:11 am
by andg
Next up is EMS studio, the real genius of Free EMS (Just kidding)
Re: Installing tools
Posted: Wed Apr 24, 2013 8:41 am
by Fred
LOL
You can put that dir where ever you want it. Now that it's built, you should test it. I'm unsure which hash I'm using, you'll need two available, if you want to screw with experimental code. I tend to rename and/or re-symlink for purpose, this is my rather large /opt dir:
Code: Select all
freeair:~ fred$ l /opt/
total 16
drwxr-xr-x 22 fred admin 748 Jul 24 2012 .
drwxr-xr-x 35 root admin 1258 Feb 14 23:45 ..
lrwxr-xr-x 1 fred admin 39 Jul 24 2012 freeems-tools -> freeems-tools.last.old.before.new.hash/
drwxr-xr-x 8 fred staff 272 Nov 19 2010 freeems-tools.0
drwxr-xr-x 10 fred staff 340 Dec 21 2011 freeems-tools.1b0f53a.xg.binutils.hash
drwxr-xr-x 10 fred staff 340 Jan 5 2012 freeems-tools.41909e2.xg.binutils.hash
drwxr-xr-x 10 fred staff 340 Jan 5 2012 freeems-tools.46ab71b69.xg.binutils.hash
drwxr-xr-x 10 fred staff 340 Jan 4 2012 freeems-tools.52c0a45d66.xg.binutils.hash
drwxr-xr-x 11 fred staff 374 Jan 4 2012 freeems-tools.5a1cb92c.xg.binutils.hash
drwxr-xr-x 10 fred staff 340 Jan 5 2012 freeems-tools.7a5dcd2956.xg.binutils.hash
drwxr-xr-x 10 fred staff 340 Jan 10 2012 freeems-tools.8bc858c.hash
drwxr-xr-x 10 fred staff 340 Mar 12 2011 freeems-tools.built.by.f8e2381
drwxr-xr-x 10 fred staff 340 Sep 8 2011 freeems-tools.c3a0c9a.xg.binutils.hash
drwxr-xr-x 10 fred staff 340 Dec 30 2011 freeems-tools.c7148660.xg.binutils.hash
drwxr-xr-x 10 fred staff 340 Jan 6 2012 freeems-tools.final.hash
drwxr-xr-x 10 fred staff 340 Jan 25 2012 freeems-tools.first.of.daves.new.tools.25.jan.2012.fresh.clone.binutils.daves.repo
drwxr-xr-x 10 fred staff 340 Jan 6 2012 freeems-tools.goodbye.code.hash
drwxr-xr-x 10 fred staff 340 Jan 7 2012 freeems-tools.goodbye.even.more.code.hash
drwxr-xr-x 10 fred staff 340 Jan 6 2012 freeems-tools.goodbye.more.code.hash
drwxr-xr-x 10 fred staff 340 Jan 15 2012 freeems-tools.last.old.before.new.hash
lrwxr-xr-x 1 fred admin 39 Feb 21 2012 freeems-tools.no.error -> freeems-tools.last.old.before.new.hash/
drwxr-xr-x 15 root admin 510 Aug 16 2012 local
NO idea what any of it means, cept a lot of wasted disk space... :-)
Find a hash that can build my master with a clean git status and label that and use it. Sean can tell you which hash to use for his stuff. symlink/adjust path as appropriate :-)
Fred.
Re: Installing tools
Posted: Wed Apr 24, 2013 8:40 pm
by andg
last.old.before.new
lol. I have the toughest time with making meaningful names for backups
Re: Installing tools
Posted: Sat May 04, 2013 3:21 am
by andg
I went to install the EMS Studio on an old xp laptop that I was planning on using for tuning. I went to
EMS studio downloads and clicked on the first link to download. The install took all of 30 seconds, and suddenly I was ready to interface with firmware. This was the easiest thing yet that I've done on track to setting up my car. I had spent about 10 minutes on #freeems-ot on freenode IRC chatting with the developer about the implementation I had intended with the greatest respect I could imagine a developer providing a user. Fred has been helpful with requirements but Mike was very open with his use, and encouraging. There was no confusing questions for setting up EMS Studio that I had to think twice about, and the tool was installed to the start menu. The tools opened as expected and informed me that the serial interface wasn't hooked up, as I expected.