; --------------------------------------------------------------------------------
; @Title: Load SIEVE example compiled with COSMIC compiler
; @Description:
; This example loads the SIEVE example at 0x2000 which was compiled with the
; Cosmic compiler v4.2.2.
; To do this its necessary that the target CPU and memory are inizialized
; in advance.
; This will be usually done by the firmware on the AMCC evaluation boards.
; Just do a SYStem.Up, run the uboot application from the flash (Go or F7)
; and stop the CPU (Break or F8) as soon as the uboot wait for a key to stop
; loading the Linux in ther serial monitor.
;
; @Board:
; @Chip:
; @Keywords:
; @Author: hstainl
; @Copyright: (c) 1989-2014 Lauterbach GmbH, licensed for use with TRACE32(R) only
; --------------------------------------------------------------------------------
; $Id: cosmic.cmm 8293 2015-04-07 13:40:20Z hlohn $


 WinPAGE.Create cosmic
 WinCLEAR

 IF SYStem.MODE()<5
 (
 	DIALOG.OK "CPU is in SYStem.Down mode! Please initialize the CPU and target memory first!"
 	ENDDO
 )

 IF run()
 	Break.direct

 Data.LOAD.auto cosmic.elf /Verify
 Go.direct sieve
 Break.RESet
 Var.Break.Set  \\cosmic\sieve\flags[6]; /W /SPOT

 IF !WINDOW.NAME(careaW)
 (
	WinPOS 0% 0% 50% 50% 0 0 careaW
 	AREA.view
 )
 IF !WINDOW.NAME(cdlW)
 (
	WinPOS 50% 0% 50% 50% 0 0 cdlW
 	List.auto
 )
 IF !WINDOW.NAME(varframeW)
 (
 	WinPOS 0% 50% 50% 50% 0 0 varframeW
 	Frame /Locals /Caller
 )
 IF !WINDOW.NAME(varwatchW)
 (
 	WinPOS 50% 50% 50% 50% 0 0 varwatchW
 	Var.Watch
 	Var.AddWatch ast; %Open flags
 )

 ENDDO


