SmileBASIC has two things: MAINCNT and MILLISEC. MAINCNT shows how many frames have passed since SmileBASIC was launched, while MILLISEC is the same, but display the milliseconds. What you could do is take the MILLISEC value at some time (call it OLD_M), and then do a loop to do a comparison with an updated MILLISEC (call it NEW_M) to have the actual seconds independently of framerate.