Keil Logo

Peripheral Simulation

For CybraTech SOC-3000 — Clock, Timer Rate & External Memory Stretch Control

Simulation support for this peripheral or feature is comprised of:

  • Accurate simulation of special on-chip features.
  • Dialog boxes which display and allow you to change peripheral configuration.
  • VTREGs (Virtual Target Registers) which support I/O with the peripheral.

These simulation capabilities are described below.

MOVX Duration

The feature allows the programmer to adjust the speed of external memory accesses by adding machine cycles the MOVX instruction. Increasing machine cycles lengthens the RD and WR strobe signals for each MOVX instruction executed, thereby allowing access to slower memory or peripherals. The MOVX Duration setting affects the speed of the MOVX instruction only.

Clock Control Dialog

Clock Control

The Clock Generation dialog displays and allows you to specify the configuration for the MCU clock.

Control Register

  • CKCON contains the MOVX duration selection setting, as well as the Watchdog Timer mode setting and Timer/Counter Clock selection bits.

Timer Rate Control

  • T2M if set, the Timer 2 clock frequency equals the system clock divided by 4. If reset, it equals the system clock divided by 12.
  • T1M if set, the Timer 1 clock frequency equals the system clock divided by 4. If reset, it equals the system clock divided by 12.
  • T0M if set, the Timer 0 clock frequency equals the system clock divided by 4. If reset, it equals the system clock divided by 12.

Oscillators & CPU Clock

  • XTAL Freq. specifies the crystal oscillator frequency in Hz.
  • Ring Osc. specifies the ring oscillator frequency in Hz.
  • CPU CLock displays the resulting system clock frequency.
  • RGMD (Ring Oscillator Mode) is set to indicate the clock source is the Ring Oscillator. If reset, the clock source is an external crystal or oscillator.
  • RGSL (Ring Oscillator Select) is set to use the Ring Oscillator to start up from Stop mode. If reset, the software must wait for the crystal warm-up period to complete.

External Memory Access

  • MOVX Duration[Cycles] selects the number of machine cycles the the MOVX instruction will use. The RD and WR strobes are lengthened by this interval to allow use of slower memory or peripheral devices.

RING VTREG
Data Type: unsigned long

The RING VTREG contains the frequency of the internal ring oscillator (in Hertz) which may be used to drive the microcontroller. You may change the value of RING using the command window. For example:

RING=5000000

You may also output the current value of RING using the following:

RING

XTAL VTREG
Data Type: unsigned long

The XTAL VTREG contains the frequency of the oscillator (in Hertz) used to drive the microcontroller. The value is automatically set from the value specified in Project Options - Options for Target. However, you may change the value of XTAL using the command window. For example:

XTAL=12000000

You may also output the current value of XTAL using the following:

XTAL

XTAL may be used in calculations to synchronize external scripts with the simulated microcontroller.

Get more information about the
Peripheral Simulation Capabilities
of the µVision Debugger.
  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.