Tips
 
Main page [CHM]
Components Index
CPU Components
Compilers








 
 All Tips of the Day

Level: 1, Category: General

Term Component

The Term component provides communication with a user terminal via an asynchronous serial channel. The component can be found in the category CPU External Devices / Display. It offers a high-level methods for writing strings and numbers, cursor and line operations etc.

Level: 1, Category: General

Documentation For The Component

The detailed documentation for a specific component can be easily obtained

  • Within a Components Library or Project Panel - use the Help command in a pop-up menu which is available after the right mouse-click on the component's icon.
  • Within the Component Inspector - a Help menu contains the command Help on Component.

Level: 1, Category: General

Method Invocation

To place method invocation into the code

  1. Find the method in the Component's subtree in the Project Panel
  2. Drag the method name to the editor
  3. Type the parameter values.

Level: 1, Category: General

Application Design Documentation

The Processor Expert help chapter Application Design helps users to

  • Understand the Embedded Components concept
  • Understand the process of the Code Generation
  • Contains many other useful information and tips helping users to speed up the development and to create an optimized and properly designed application.

Level: 1, Category: General

Copying Or Moving Components With Settings

  1. Select the component in the source project using the left mouse button and the Shift or Ctrl key.
  2. Use the Copy or Cut command from the pop-up menu of the Project Panel.
    This menu is invoked by right button click on the white background of the Project Panel.
  3. Switch to the destination project.
  4. Use the Paste command from the Project Panel pop-up menu.

Level: 1, Category: General

Changing Number Format For The Generated Code

Use the Number format option in Project options to choose between the decimal or hexadecimal format.

Level: 1, Category: General

Renaming CPU Peripherals

Names of the peripherals (like pins, timers or converters) used by components can be changed.
Use Peripheral names editor invoked from CPU component pop-up menu to change peripheral's name or reset it to a default one.

Level: 1, Category: General

Components Library

Use Components Library to find an Embedded Component suitable for your application and add it to the project. Categories, On-chip prph, Alphabet tabs offer components sorted and grouped using specific rules. The Assistant tab offers easy component selection by answering simple questions.
Use Quick-help button to get more information for the selected component.

Level: 1, Category: General

Undo and Redo Commands in Processor Expert

Restores the state of the project before/after a last operation. These commands are invoked from Processor Expert menu and affects only changes in the project or components (i.e. adding or removing components, disabling components, changing settings etc.). Functionality of these commands is influenced by the environment option Number of UNDO operations. The '0' value of this option disables Undo and Redo commands in PE.

Level: 1, Category: General

Switching Between Memory Area Definition And Memory Map Window

  • Every memory area definition (in Build Options tab of the CPU) contains a button that will open a Memory Map window and graphically highlight the area.
  • After double-click on the used memory area within Memory Map window, it's definition is opened and selected in the Inspector.

Level: 1, Category: General

TRUE and FALSE values of bool type

Processor Expert defines the TRUE symbol as 1, however TRUE and FALSE values are defined according to ANSI-C:

  • FALSE is defined as 0 (zero)
  • TRUE is any non-zero value.

It follows from this definition, that the bool value cannot be tested using the expressions like if (value == TRUE). The correct C expression for such test is if (value).

Level: 1, Category: General

Synchronization of the Inspector and Project Tree

Enable the environment option Synchronize Project Tree With Inspector if you wish to always highlight the currently inspected object in the tree in the Project Panel. It may be useful especially if inherited or shared components settings are used.

Level: 1, Category: General

Target CPU window

Target CPU window allows to view

  • Complete CPU package with all pins and components using these pins
  • CPU peripherals allocation by components
  • CPU block diagram of functional blocks and their connections

Level: 1, Category: General

Processor Expert Web Pages

Visit our web pages at www.processorexpert.com for latest updates, and product information.

Level: 1, Category: General

Peripheral Initialization Window

Peripheral Initialization Window allows to view control registers of a selected peripheral and their initial values that will be set by Processor Expert initialization routines. An influence of the last change in a component settings is immediatelly shown and highlighted.

Level: 2, Category: General

Generation of ISRs for Peripheral Initialization Components

  • Enabling the Project option Generate ISR will enable generation of the empty Interrupt Service Routines (ISRs) for the interrupts that needs to be serviced by a user (typically with usage of Peripheral Initialization Components).
  • Generated ISRs are placed in the CPU component's Event module.
  • Generated ISRs contains a fast interrupt handling instructions according to selected priority.

Level: 2, Category: General

How to switch between two variants of component's settings using configurations?

  1. Create a configuration (if there is no active), insert a first component and configure it.
  2. Create another configuration and select it is as active.
  3. Disable the first component.
  4. Insert a second component of the same type and rename it to the same name as the first component.
  5. Switch to the first configuration and disable the second component

Level: 2, Category: General

Review of changes in generated code

To review changes in files generated by Processor Expert after every code generation switch on the Track/review changes after code generation option in Project options.

Level: 2, Category: General

Exporting Components

To save a component or group of components including their settings to the file:

  1. Select components in the Project Panel.
  2. Use the Export... command from the Project Panel pop-up menu invoked using the right button click on the white Project Panel background.

The previously exported .pe file can be imported using the Import components... command from the Project Panel pop-up menu.

Level: 2, Category: General

Automatic Configuration and Target Switching

When the CodeWarrior target is switched to another, the Processor Expert searches for the configuration with the same name. If it exists, it is set as active.
Respectively, when the configuration is switched, the target with the same name is searched and if found it is set as active.
Note: The configuration and target names are case-sensitive.

Level: 2, Category: General

Generation of ISRs for Peripheral Initialization Components

  • Enabling the Project option Generate ISR will enable generation of the empty Interrupt Service Routines (ISRs) for the interrupts that needs to be serviced by a user (typically with usage of Peripheral Initialization Components).
  • Generated ISRs are placed in the CPU component's Event module.

Level: 2, Category: General

Signal Names

Processor Expert allows to assign signal names to individual pins used by Embedded Components. The list of all signals and related pins is automatically generated into the text document {projectname}_signals. This file is accessible directly in the Documentation folder of the Project Panel.

Level: 2, Category: General

Software Delay Method

The CPU component method Delay100US provides a speed-mode independent delay of 100 microseconds multiple implemented as a pure software loop (It doesn't utilize any hardware timer). The parameter specifies a delay time as a number of multiples of 100uS. See the method hint for details.
Note: Occurrences of interrupts can protract the delay time.

Level: 2, Category: General

Viewing the Interrupt Vectors Table

The list of all MCU interrupt vectors with information on allocation by components is available in the Interrupts tab of the Peripheral Usage window. The View menu option Show Used Peripherals Only allows to filter only the resources allocated by components.
This window also shows the usage of other MCU resources like pins, timers or communication channels.

Level: 2, Category: General

Specific Pin Options

Specific pin options, such as LED drive, IR LED drive and slew rate, can be set in the CPU component inspector - Internal peripherals - I/O module.

Level: 2, Category: General

Optimization of the Generated Initialization Code

The size of common initialization code executed at the application start can be optimized by enabling the option Use after reset values in the Configuration Inspector. If this option is enabled, the registers that would be set to the values equal to after-reset state won't be initialized.

Warning: This optimization shouldn't be used if the application performs a soft-reset.

See the Configuration Inspector help for details and other optimization options.

Level: 2, Category: General

Do you want the generated code to be faster and smaller ?

See the chapter Application Design / Embedded Components Optimizations of the Processor Expert help.

Level: 2, Category: General

Specific Pin Options

Specific pin options, such as slew rate and drive strength, can be set in the CPU component inspector - Internal peripherals - I/O module. By default, the pins are set to slew rate = no, drive strength = high.




PROCESSOR EXPERT is trademark of Freescale Semiconductor, Inc.
Copyright 1997 - 2010 Freescale Semiconductor, Inc.