1

I'm new in embedded systems development. I just want to compile some C code for this system:

 uname -mrs Linux 2.6.32.28_stm24_0207 sh4 machine : STb7100 Reference board processor : 0 cpu family : sh4 cpu type : STx7100 cut : 3.x cpu flags : fpu cache type : split (harvard) icache size : 16KiB (2-way) dcache size : 32KiB (2-way) address sizes : 29 bits physical bogomips : 264.19 

Can anybody tell me the steps how to accomplish C compilation on my PC (Ubuntu) with GCC for that kind of system. I just need a little guidance.

2
  • check kpit toolchain kpitgnutools.com Commented Jul 26, 2013 at 14:20
  • 1
    Basically, you need a "cross compiler" that is hosted on your PC and which targets the STb7100. Commented Jul 26, 2013 at 14:32

3 Answers 3

1

A quick google search indicates that chip has an ST40 cpu core. Another google search turned up this link which has all of the instructions you need.

Sign up to request clarification or add additional context in comments.

2 Comments

So OS in that system is STLinux ?
Looks that way - that's what your uname output seems to indicate you're using, too.
0

Building a cross compiler is not trivial. Having said that, should you march down that path at the end you will know a lot more about how the gcc compiler really works, there are, very likely, a bunch of things you don't know that you don't know here. Then again, @Carl Norum has the easier path. Bottom line, the former path is more rewarding, the latter is easier :-)

2 Comments

I'm working with great tutorial, to learn how things are working ;) www6.software.ibm.com/developerworks/education/l-cross/…
awesome, I think this will take you down the tunnel of linker scripts and the like, you will find, for example, that there is some start-up code that gets executed before main. Incidentally, don't let anyone dissuade you from understanding assembly, if you're dealing with this stuff you'll have little trouble sorting out assembly!
0

You need a cross compiler so you can compile your app in your pc and download it to the device, the one suitable for that processor, for example the one for this : http://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=3&cad=rja&ved=0CD4QFjAC&url=http%3A%2F%2Fwww.avi-plus.com%2Fdownload%2FSTb7100MB.pdf&ei=DIbyUbXZGYay9gTB_4GYDg&usg=AFQjCNHaAj1_zgFosaQPmP1htiz9e6KGCw&sig2=TCVzRlWfaqcvyAjyU1jjsw&bvm=bv.49784469,d.eWU is Altera VHDL Compiler. After that you could need some kind of sdk.

1 Comment

errr, that's a link to a data sheet for a reference board.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.