################################################################################
#
#  Install subject: swd (SpotWare 2, also called SpotWare+)
#  $Revision: 1.6 $
#
# MODIFICATIONS
# $Log: install2.cmd,v $
# Revision 1.6  2003/04/08 18:30:42  SIGADMIN
# Patch: than0804H13M55S05 Solved SPR: 1014174 Test status: NT Log: Removed erase of domain SYS in install script;
#
# Revision 1.6  2003/04/08 11:54:08  than
# SPR1014174
# Checked: rome
# Removed erase of domain SYS command
#
# Revision 1.5  2001-12-06 16:07:02+01  tose
# Removed query for IO board, install default simulated board.
#
# Revision 1.4  1999-06-08 09:39:05+02  tojoh
# Removed ram1disk:
#
# Revision 1.3  1996-06-12 10:47:39+02  elhu
# Patch: elhu1206H10M46S29  Solved SPR:  Test status: NT Log: $BOOTPATH changed to $BOOTPATH/
#
# Revision 1.2  1996/06/07  14:42:16  hekn
# flp1: changed to $BOOTPATH
#
# Revision 1.1  1996/05/10  12:13:17  swdadmin
# Initial revision\
# ^^^^^^^^^^^^ PROJECT COMMENTS BEGIN ^^^^^^^^^^^^^
#
# Revision 1.4  1996/05/10  12:01:32  swdadmin
# vvvvvvvvvvvv PROJECT COMMENTS END vvvvvvvvvvvv\
# Moved back to subject from/projects/foxsw/swd/classlib
#
# Revision 1.5  1996/04/23  12:25:19  hekn
# SpotWare identity SP installed
#
# Revision 1.4  1996/04/09  12:01:51  anma
# text sw_rapid.$LANG added,
# copy swtext_s.eng removed
#
# Revision 1.3  1996/02/20  08:37:31  alli
# SYS config moved, so it will be done even when opt. disc
# weld timer has been installed before spotware opt.
#
# Revision 1.2  1996/02/09  15:59:36  hekn
# Patch: hekn0902H16M58S51  Solved SPR:  Test status: NT Log: RCS comments "#" instead of "::"
#
# Revision 1.1  1996/02/01  13:14:59  swdadmin
# Initial revision\
# ^^^^^^^^^^^^ PROJECT COMMENTS BEGIN ^^^^^^^^^^^^^
#
# Revision 1.3  1996/02/01  13:04:00  swdadmin
# vvvvvvvvvvvv PROJECT COMMENTS END vvvvvvvvvvvv\
# Moved back to subject from/projects/foxsw/swd/classlib
#
# Revision 1.10  1996/01/24  10:16:22  gema
# add swtimer module
#
# Revision 1.9  1996/01/17  15:17:44  alli
# swboard.cmd added
#
# Revision 1.8  1996/01/16  21:27:51  hekn
# prg changed to mod
#
# Revision 1.7  1996/01/15  21:24:15  hekn
# Physical SpotWare card definition in a separate sweio_card.cfg
#
# Revision 1.6  1996/01/15  10:29:01  hekn
# Install changed to Installing
#
# Revision 1.5  1995/11/09  13:13:39  hekn
# Patch: hekn0911H14M13S21  Solved SPR:  Test status: SY Log: New module swtool
#
# Revision 1.4  1995/10/24  08:23:26  hekn
# Patch: hekn2410H09M22S55  Solved SPR:  Test status: SY Log: Mail box module removed
#
# Revision 1.3  1995/06/19  22:52:03  hekn
# -erase -domain SYS added
# swsysrp.cfg added
#
# Revision 1.2  1995/06/19  16:23:40  hekn
# Changed from $LANG to eng for language independent files
#
# Revision 1.1  1995/06/12  06:36:31  swdadmin
# Initial revision\
# ^^^^^^^^^^^^ PROJECT COMMENTS BEGIN ^^^^^^^^^^^^^
#
# Revision 1.2  1995/06/11  17:38:25  swdadmin
# vvvvvvvvvvvv PROJECT COMMENTS END vvvvvvvvvvvv\
# Moved back to subject from/projects/foxsw/swd/classlib/swd
#
#Revision 1.3  1995/06/08  17:02:30  hekn
#-label in goto-commands added
#.eng and all other language files replaced by .$LANG
#
#Revision 1.2  1995/05/18  08:38:22  mibe
# do not consider any native translation of the Rapid language
#
#Revision 1.1  1995/05/18  08:12:57  mibe
#Initial revision
#
#
################################################################################
# Install.cmd script for installation of the SpotWare+ add-on package.
#
# Use:
#      this file will be included by the root to the main installation script
#      with the specific 'include' command.
#
################################################################################
#
# Note:
#       . used variables:
#
#             var  5 = contains the basic language selected (set by base install).
#             var  6 = contains the Rapid language selected (set by base install).
#             var 17 = contains 2 if Weld Timer serial access disk has already been
#                      loaded.
#             var 18 = is set by this installation script to tell the eventual
#                      Bosch disk installation that SpotWare has been installed
#
#
################################################################################

#############
# Beginning #
#############

echo -text " "
echo -text "Installing SpotWare option"
install -name SP -resource Function
if -var 18 -value 1 -label ALREADY_DONE
if -var 18 -value 2 -label ALREADY_DONE
if -var 17 -value 1 -label ERROR
goto -label NEXT_STEP

#
#ALREADY_DONE
#
echo -text " "
echo -text "!!! SpotWare was already installed  !!!"
goto -label END

#
#ERROR
#
echo -text " "
echo -text "!!!      Timer Serial interface      !!!"
echo -text "!!!        has been installed        !!!"
echo -text "!!! for an OTHER version of SpotWare !!!"
goto -label END

#
#NEXT_STEP
#
#################################################
# Base national Language Dependent files (text) #
#################################################
echo -text "Install text files"
text -filename $BOOTPATH/rlsw.eng -package 0
text -filename $BOOTPATH/swdata.eng -package 0
text -filename $BOOTPATH/sw_elog.$LANG -package 0
text -filename $BOOTPATH/sw_rapid.$LANG -package 0

#
#########################################################
# Rapid national Language Independent files (Rapid sys) #
#########################################################
echo -text "Install Rapid files"
copy -from $BOOTPATH/swbase_s.eng -to swbase.sys
copy -from $BOOTPATH/swusrf_s.eng -to swusrf.sys
copy -from $BOOTPATH/swprcb_p.eng -to swprcb.mod
copy -from $BOOTPATH/swusrc_s.eng -to swusrc.sys
copy -from $BOOTPATH/swtool_s.eng -to swtool.sys
copy -from $BOOTPATH/swsupb_p.eng -to swsupb.mod

#
#######################################
# National Language Independent files #
#######################################

# Rapid : cfg (Rapid programming rules)
config -filename $BOOTPATH/rlsw.cfg -domain MMC
config -filename $BOOTPATH/swdata.cfg -domain MMC

# EIO   : cfg (definitions & configurations)
# N.B.  : if the Bosch disk has been loaded, it has already installed the 
#         proper EIO cfg file

# Select swboard type and position 
#include -path $BOOTPATH/swboard.cmd

if -var 17 -value 2 -label NEXT_STEP
config -filename $BOOTPATH/sweio.cfg -domain EIO
copy -from $BOOTPATH/swtimr_s.eng -to swtimer.sys

#
#NEXT_STEP
#
# CAB   : cfg (definitions & configurations)
config -filename $BOOTPATH/swsysrp.cfg -domain SYS
config -filename $BOOTPATH/swsys.cfg -domain SYS -internal

##############
# Load files #
##############

# SW : ld object file
#load -path $BOOTPATH/swdld.o

#
#set variable to tell the Bosch disk installation that (advanced) SpotWare+
#has already been installed
setvar -var 18 -value 2


#######
# End #
#######

#
#END
echo -text "...done"

#
# The following has to be done afterwards in the base install.cmd script:
#
#    new -resource cab
#    # Make System WarmStart (use startup.cmd):
#    restart
#
