| xPC Target™ | ![]() |
| On this page… |
|---|
You can boot your target PC with the xPC Target kernel using one of the following ways from the xPC Target Explorer:
CD Boot — Boot the target PC with a CD bootable ROM
Boot Floppy — Boot the target PC with a 3.5-inch floppy.
Network Boot — Boot the target PC from a dedicated network boot image.
Target boot disks and boot images include the xPC Target kernel specific for either serial or network communication. If you installed the xPC Target Embedded Option, and you select stand-alone mode, the target boot files include the target application (see Embedded Option in the xPC Target User's Guide). If you want to boot from a device other than a CD, 3.5-inch disk, or dedicated network boot image, see Booting from a DOS Device in the xPC Target User's Guide.
Note Before you create a target boot disk, ensure that you have write permission for your current working directory. You cannot create a boot disk otherwise. |
Ensure that you have appropriately configured your xPC Target system before you create your boot disk or boot image. At a minimum, ensure that you have performed the following configurations. You can optionally set the other xPC Target Explorer configuration options; however, their default values should suffice.
Confirm that the boot tab on the Configuration pane is set to your desired boot mode:
CD Boot
Boot Floppy
Network Boot
For information on other boot modes, see the following topics in the xPC Target User's Guide:
Booting from a DOS Device, for DOSLoader mode
Embedded Option, for StandAlone mode
Check the C compiler specification (see Configuring the xPC Target Host PC for Your C Compiler).
If you are using TCP/IP communication, check that your network connections are correct. Also check the xPC Target Explorer settings (see Network Communication). Your xPC Target system shipped with a supported Ethernet card.
If you are using serial communication, check that your physical connections are correct. Also check the xPC Target Explorer settings (see Serial Communication).
Check your target PC BIOS settings (seeThe xPC Target Software and the Target PC BIOS in this chapter and BIOS Settings).
You use the target boot CD to load and run the xPC Target kernel. After you make changes to the xPC Target environment properties, you need to create a target boot CD. Note that this topic assumes you are using default environment parameter settings for the target boot CD creation. If this is not the case, see Configuring Environment Parameters for Target PCs in the xPC Target User's Guide for further details.
To create a target boot CD for the current xPC Target environment, use the following procedure. This procedure describes how to create a target boot CD for the target TargetPC1.
Ensure that you have an empty, writable CD.
Ensure that you have a CD-RW drive and CD writing software that can write ISO image files.
If the xPC Target Explorer is not open, open it now. At the MATLAB Command Window, type
xpcexplr
In the xPC Target Explorer xPC Target Hierarchy pane, select a target PC Configuration node. For example, select the Configuration node for TargetPC1.
A TargetPC1 Configuration pane appears in the rightmost pane. This pane contains a series of tabs.
In the location parameter, enter a path in which you want xPC Target Explorer to write the xPC Target CD boot ISO image. For example, enter C:\Work\matlab.

Click the Apply button.
Click the Create CD Boot Image button.
The software creates a CD image file named cdboot.iso in this directory. You will create the target boot CD with this image file.
Using the CD creation software, write the cdboot.iso ISO image to the empty CD.
Insert the CD bootable ROM into your target PC CD drive and reboot that PC.
Your next task is to install the software on the target PC and test your installation. See Testing and Troubleshooting the Installation.
You use the CD target boot disk to load and run the xPC Target kernel. After you make changes to the xPC Target environment properties, you need to create a CD bootable ROM.
To create a CD target boot disk for the current xPC Target environment, use the following procedure:
In the MATLAB window, type
xpcgetenv
Ensure that the following xPC Target properties are set as follows:
TargetBoot — CDBoot
CDBootImageLocation — Your host PC CD disk drive location
If these properties are not set with the correct values, use the setxpcenv function to set them. For example:
setxpcenv('TargetBoot','CDBoot')
setxpcenv(CDBootImageLocation,'c:\work\xpc\cdimage')
updatexpcenvxpcbootdisk
The xPC Target software displays the following message and creates the CD boot ISO image.
Current boot mode: CDBoot CD boot image is successfully created
Using the cdboot.iso and your CD creation software, create your target boot CD.
Insert the CD bootable ROM into your target PC CD drive and reboot that PC.
Your next task is to install the software on the target PC and test your installation. See Testing and Troubleshooting the Installation.
You use the 3.5-inch target boot disk to load and run the xPC Target kernel. After you make changes to the xPC Target environment properties, you need to create or update a 3.5-inch boot disk. Note that this topic assumes you are using default environment parameter settings for the target boot CD creation. If this is not the case, see Configuring Environment Parameters for Target PCs in the xPC Target User's Guide for further details.
To create a target boot disk for the current xPC Target environment, use the following procedure. This procedure describes how to create a target boot disk for the target TargetPC2. Alternatively, see Creating a 3.5-Inch Target Boot Disk with a Command-Line Interface.
If the xPC Target Explorer is not open, open it now. At the MATLAB Command Window, type
xpcexplr
In the xPC Target Explorer xPC Target Hierarchy pane, select a target PC Configuration node. For example, select the Configuration node for TargetPC2.
A configuration pane for that target PC appears in the rightmost pane.
From the tab list, select the Boot Floppy tab.

As necessary, change the drive letter of the 3.5-inch drive to a valid floppy drive. It is a: by default.
Click the Apply button.
Click the Create Bootdisk button.
The following message box opens.

Insert a formatted 3.5-inch floppy disk into the host PC disk drive, and then click OK.
All data on the disk is erased as the xPC Target software writes the xPC Target kernel and other required files to the 3.5-inch disk.
The xPC Target software displays the following dialog box while creating the boot disk. The process takes about 1 to 2 minutes.

Insert the boot disk into your target PC disk drive and reboot that PC.
Your next task is to install the software on the target PC and test your installation. See Testing and Troubleshooting the Installation.
You use the target boot disk to load and run the xPC Target kernel. After you make changes to the xPC Target environment properties, you need to create or update a boot disk.
To create a target boot disk for the current xPC Target environment, use the following procedure:
In the MATLAB window, type
xpcgetenv
Ensure that the following xPC Target properties are set as follows:
TargetBoot — BootFloppy
BootFloppyLocation — Your host PC 3.5-inch disk drive location
If these properties are not set with the correct values, use the setxpcenv function to set them. For example:
setxpcenv('TargetBoot','BootFloppy')
setxpcenv('BootFloppyLocation','a:')
updatexpcenvxpcbootdisk
The xPC Target software displays the following message.
Current boot mode: BootFloppy Insert a formatted floppy disk into your host PC's disk drive and press a key to continue
Insert a formatted floppy disk into the host PC disk drive, and then press any key.
The write procedure starts and, while creating the boot disk, the MATLAB window displays the following status information.
Creating xPC Target boot disk ... Please wait xPC Target boot disk successfully created.
Your next task is to install the software on the target PC and test your installation. See Testing and Troubleshooting the Installation.
This topic describes how to boot target PCs on a dedicated network. You do not need a boot disk. You do need to set up the host PC and target PC. This topic assumes that you know how to:
Set up a dedicated network.
Use the xPC Target Explorer to configure the target PC and host environments. You should be familiar with the following sections:
Caution Do not boot a target PC on a corporate or nondedicated network. Doing so might interfere with dynamic host configuration protocol (DHCP) servers, which will cause problems with the network. |
This procedure is similar to configuring a target boot disk. If you have previously created a target boot disk, you might not need to perform this procedure. However, you should still read the following instructions to ensure that your configuration is appropriate for booting a target PC in the dedicated network. You can configure multiple target PCs for your network.
Ensure that the host PC has a network card available for the dedicated network. As necessary, insert a second network card and configure that card for the dedicated network. This step includes assigning the host PC a unique IP address (for example, 10.10.10.10) in the same subnet as the target PC.
If the xPC Target Explorer is not open, open it now. At the MATLAB Command Window, type
xpcexplr
Add a target PC, for example, TargetPC3 (if necessary).
In the Communication Component pane for TargetPC3,
In the Host target communication field, select TCP/IP.
Enter a target PC IP address in the dedicated network, for example, 10.10.10.11.
Enter appropriate values for the remaining fields.
Click the Apply button.
In the TargetPC3 Configuration pane, select Network Boot.

The Target PC Ethernet Configuration section of the configuration pane allows you to either associate a physical target PC MAC address with the xPC Target Explorer target PC name, or allow the software to automatically find target PC MAC addresses. If you want to associate your physical target PC MAC address,
Click Manual.
In the six fields, enter the physical target PC MAC address (in hexadecimal).
Click the Create Network Boot Image button.
The software creates and starts a network boot server process on the host PC. You will boot the target PC using this process.
A minimized icon (
) representing the network boot server
process appears on the bottom right host PC system tray.
Identify the target PC that you want to boot over the dedicated network.
Perform one of the following for your target PC:
Install the Ethernet card supplied with the xPC Target product.
Use your own Ethernet card. If you choose this, ensure that:
The xPC Target product supports your Ethernet card (see Ethernet Chip Families Supported by the xPC Target Product).
Your Ethernet card must have a boot ROM that is compatible with the Preboot eXecution Environment (PXE) specification.
Connect the host PC and the target PCs within the dedicated network. For example, connect one end of a crossover cable to the dedicated network card of the host PC and connect the other end of this cable to the dedicated network card of the target PC.
Turn on the target PC.
Enter BIOS and set up the target PC for a LAN or network boot. If there is a boot order, consider setting the boot order so that the removable/boot floppy disk is the first option and the LAN is the second. Doing so ensures that if there is no xPC Target boot disk in the target PC, you can still boot the target PC from a kernel on the network.
Reboot the target PC.
The host PC network boot server displays a pop-up from the system tray indicating that the boot server is being downloaded to the target PC.
If the xPC Target Explorer target PC is not already associated with a physical target PC MAC address, the first time that the network boot server process detects a viable target PC, it displays a dialog that contains the xPC Target Explorer target PC names and the IP addresses for those names. From this list, select the physical target PC you want to associate with the target PC name.

Select the target PC name with which you want to associate the physical target PC.
The target PC receives the xPC Target kernel and boots with this kernel.
If you click the Cancel button instead of selecting a target PC name, the next time you try to boot the target PC across the network, the kernel will ignore the target PC boot request for 90 seconds.
Note the following behavior:
If the target PC name has a MAC address, and there is a physical target PC whose MAC address matches the target PC name MAC address, the software matches the two and the xPC Target Network Boot dialog does not display.
If the connection between the target PC and host PC is an RS-232 one, you cannot boot the target PC across the network.
If the StandAlone mode is enabled, you cannot boot the target PC across the network.
![]() | Serial Communication | Testing and Troubleshooting the Installation | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |