User Tools

Site Tools


ugbasic:user:kw:timer
Translations of this page:


ugBASIC User Manual

TIMER ✓

SYNTAX

   = TIMER
   TIMER = [50th/60th seconds]

PURPOSE

This variable represents a “timer”, which is the number of sixtieths / fiftieths of a second that have passed since the machine was turned on. This variable, when used as a value, measures the elapsed time. However, it can be set to an arbitrary value, such as 0, to measure a defined period of time.

The refresh rate of this timer depends on the type of video standard used, that is, PAL (50Hz) or NTSC (60Hz).

This variable can be abbreviated as TI.

EXAMPLE

  PRINT TIMER

See also the following example files:

ABBREVIATION

 Tmr

AVAILABLE ON

  • Dragon 32
  • Commodore 128 (Zilog Z80)
  • Commodore 128 (MOS 8502)
  • SEGA SG-1000
  • ZX Spectrum 48
  • Commodore 64
  • Commodore VIC-20
  • Atari (400/800)
  • Commodore PLUS/4
  • VG-5000
  • Olivetti Prodest PC128
  • Dragon 64
  • Thomson MO5
  • Amstrad CPC 664
  • SEGA SC-3000
  • ColecoVision
  • TRS-80 Color Computer 3
  • MSX
  • TRS-80 Color Computer

SEE ALSO

TI

ANY PROBLEM?

If you have encountered a problem using this command, if you think there is a bug or the explanation is unclear, please open an issue for this keyword on GitHub. Thank you!

POWERED BY