There is 1 other file named unique.sim in the archive. Click here to see a list.
! UNIQUE will return increasing integer numbers.
! The returned value will increase with one each jiffy
! (1/50 or 1/60 second).
! The returned value is a number in which bit 1-11 contains
! the day number since 1977-01-01 (mod 4096) and bit 12-35
! contains time of day in jiffies.
! The sequence will restart (from zero) every 4096th day
! (11 years and 81 days).
EXTERNAL INTEGER PROCEDURE gettab;
INTEGER PROCEDURE unique;
! Take daynumber after 1977-01-01, put it into bit 0-11
! and add no. of jiffies (always < 2^23);
! 262144 = 2^18 8388608 = 2^23;
unique:= Mod(gettab(9,43)//262144-43144,4096)*8388608 + gettab(9,8);
END of unique;