How to compile TOPPERS JSP kernel from vanilla code
Written by :  Ataya P
Date : 7 April 2007

Introduction
    For people who intend to use OS for Embedded system.If you want to talk to Japanese about this.I'm sure they will talk to you about ITRON (Industrial TRON:The Real-time Operating system Nucleus) and one of them that follow this specification is TOPPERS(Toyohashi OPen Platform for Embedded Real-time Systems)  Most of  Japan side MPU can running TOPPERS(I think so) It is open platform but  not easy for newbie to use this.Let's try to compile it  from beginning \(* . *)/

Before cooking
     Ok.First of all. We need some ingredients  for making this project work. Here is a list
 - Hardware
    PC : my  PC is desknote VIA cpu 500 MHz RAM 256MByte
              Window 2000 --little bit slow. (ToT)  
    Hardware : M30620FCAFP 128KByte flash ROM  MPU board with Extension OAKS LCD board.

- Software
   TM  (Mitsubishi project management tool) with NC30        
             compiler  version 4.0 release 2 (I try to use newer
              version but it has error about LValue problem)
   TOPPERS JSP source code(for window compile) that you
              can download from their website.I use JSP version
              1.4.2
    Cygwin  using compile tool for TOPPERS . You need to
              install  these packages too.

              - gcc for c-compiler
              -  make for make makefile   
              - automake for make makefile
              - pearl for runing make script
              and don't forget to set PATH  to <drive>:\cygwin\bin
    Borland C++ compiler version 5.5 (free download) because
              TM  is tool that working on window platform. At theJSP
               compile time  will use DOS prompt.That why we can't
               using gcc to compile all program we need.It has
               some  problem about CR\LF in the source code.

Making time
   
First of all. Install Cygwin and extract JSP source code. Install Borland C++  compiler (for me, All at c:\) and make 2 config file in the c:\Borland\Bcc55\bin directory.
          First , bcc32.cfg just push this text and save
           -I"c:\Borland\Bcc55\include"
           -L"c:\Borland\Bcc55\lib"
         Second, ilink32.cfg just push this text and save
           -L"c:\Borland\Bcc55\lib"
     Now take a look at JSP source code directory first .As I know are ....
       cfg : config kernel tool. this directory must compile with
                 borland c++ DOS command.
       config :c  header and source file  for each platform that
                     can running TOPPERS
       doc : TOPPERS documents( All in Japanese Language)          kernel : TOPPERS kernel source code
       sample : user sample source code .You can define you
                         own  code here but config file must be define on                            Tool/M16C-RENESAS/sample1.cfg
       tool :   compile tool for each platform . For 
M30620FCAFP                      MPU  we have to use M16C-RENESAS directory                           that they provide TM file for using
       utils : utilities for each platform .we have to compile
                  m16coffset.exe and m16cvec.exe using gcc.
                  TM will ask for these tools during compile kernel
                   time.

       Ok,After kick off.We will compile all tool. Let's  start at cfg directory first. Open Dos command prompt and set PATH by type

          path=c:\Borland\bcc55\bin <enter>

        go to cfg directory and delelte Makefile file .Afterthat just change Makefile.bcc to Makefile and type
       
  make <enter>

      This will using Borland make command to compile config tool.After  a while(well,my PC is a slow processing type)you will get cfg.exe and chk.exe that TM will ask for during the compile sample source time.
         Next , Let's compile  utilities tools by using Cygwin and gcc . Just open  Cygwin bash shell and go to JSP directory.
at  jsp/utils/m16c-renesas and tytpe
       
  make <enter>

       If everything  ok you will get  m16coffset.exe and m16cvec.exe these two files is for making offset and interrupt vector when building kernel with TM 
         Now we ready to compile JSP kernel  by open TM
 and open project file in c:\jsp\tool\ M16C-RENESAS directory . Once you try to compile it . TM will ask for  offset.inc Anyway it  already made in tool working directory. Just copy it to c:\jsp\config\m16c-renesas and compile again.If everything is in the right order you will  finish compilation without no problem.

         Next ,Just burn your JSP14sample1.mot to your board using Flash program.After that , Connect your board and PC with  serial cable and set up Hyper Terminal at 19200 and no flow control. Push restart button on your board .You will received JSP message on your Terminal screen.Good luck baby. (  =_)
   (_*   )
       
           
   












TOPPERS JSP directory
Pic 1 :  TOPPERS JSP source directory 
kernel config tool using Borland C++ compile
Pic 2 : cfg.exe and chk.exe in  cfg directory
compile utility tool using gcc and make
Pic 3 : Compile Utility tool using GNU gcc and make
OAKS m16c board
Pic 4 :   OAKS m16c board
OAKS lcd board
Pic 5 :   OAKS LCD  board
File and Source code :
>> JSP14sample1.mot << : Already compiled kernel TOPPERS JSP for M16C MPU
*** due to software license . the others file you should download from the original website  by yourself.
Useful links :

TOPPERS  project
http://www.toppers.jp/  for TOPPERS JSP  sourcecode
http://www.oaks-ele.com/  for data about M16C board
http://www.borland.com/jp/products/cbuilder/freecompiler.html for Borland C++ Compiler

Others
This page is  Made with Nvu
All pictures are Graphics by GIMP
>> Back to home page << How to import TM make file to HEW project


© All stuffs that appear in this website are reserved for Lemongrass-studio (Ataya P)Since 2004 AD .