example-3

所属分类:系统编程
开发工具:Visual C++
文件大小:71KB
下载次数:2
上传日期:2008-03-17 20:11:58
上 传 者weilixiang
说明:  This application has one task that reads characters from stdin and sends them to a second task. This converts the characters to upper case and sends them back to the first task for printing. Each task will execute on a different processor.

文件列表:
example-3\DRIVER.C (478, 2007-08-23)
example-3\DRIVER.C.bak (476, 2004-04-16)
example-3\DRIVER.obj (1568, 2007-08-23)
example-3\driver.tsk (64468, 2007-08-23)
example-3\Dual.app (113664, 2007-08-23)
example-3\Dual.bat (198, 2002-10-30)
example-3\DUAL.CFG (915, 2004-09-01)
example-3\MAKEFILE (310, 2002-10-30)
example-3\UPC.C (454, 2002-10-30)
example-3\UPC.obj (897, 2007-08-23)
example-3\upc.tsk (10942, 2007-08-23)
example-3 (0, 2007-08-23)

This application has one task that reads characters from stdin and sends them to a second task. This converts the characters to upper case and sends them back to the first task for printing. Each task will execute on a different processor. Before building the application, check the configuration file, DUAL.CFG. It has two PROCESSOR statements: processor root DEFAULT processor node DEFAULT These assume that you have set a default processor when you installed Diamond. If you did not, you will need to do one of two things: 1: set a default using the utility ProcType; or 2: change the configuration file to specify your actual processor type. For example, if you have an SMT361: processor root TYPE=SMT361 If your modules are not both the same type, change the types appropriately. For example, processor root smt361 processor node smt335 Also check that comport connections between the modules are correct. You will need: TIM 1 Comport 1 connected to TIM 2 Comport 4 to correspond with the configuration file statement: wire ? root[1] node[4] You can do this in two ways: 1: Attach an FMS cable to the connectors at the back of the carrier board (T1C1-O connects to T2C4-I). Don't forget to give the cable a twist: one end should have the blue side out, the other should have the silver side out. 2: If you have an SMT310Q carrier board, you can use the Quick Switches. These can be set using the Sundance BoardInfo program or from from the Diamond server under Board/Properties. There are two ways to build this application: 1: If you have a suitable MAKE utility (NMAKE is a common one), you can use the supplied MAKEFILE: C> NMAKE 2: If you do not have a MAKE utility, you can execute the batch file, DUAL.BAT: C> Dual When the application runs, it will request input from the keyboard. Type some text and terminate each line with Return. Your input should be printed to the output window with all the letters in upper case. Note that the server will copy everything you type to the output window. You can stop this by clearing the "Echo stdin to stdout" box in the input window. You terminate the program by pressing "End of File" or typing Ctrl+Z. You could try redirecting stdin and running the program again. You can do this from the server by selecting: View/Options/Standard I/O Under "stdin" select "File" and either type the name of a file containing text or browse to one using the "..." button. Select OK and run your program again (Go/Run or F5 or the green toolbar button). To avoid surprises later, don't forget to set stdin back to the keyboard when you have finished: View/Options/Standard I/O/Stdin/Keyboard

近期下载者

相关文件


收藏者