Page 1 of 1

ResetProcessor command

Posted: 22 June 2010, 0:54 AM
by FFMan
In a quick and dirty prototype fashion I put a call to ResetProcessor thinking this would perform a warm start and execute my program from the beginning again, but at first glance it didn't appear to do anything.

Have I misunderstood what this should be doing ?

Re: ResetProcessor command

Posted: 22 June 2010, 8:32 AM
by dkinzer
FFMan wrote:[...] a call to ResetProcessor thinking this would perform a warm start and execute my program from the beginning again
The ResetProcessor() call resets the device using the WatchDog reset. Other than that, it is essentially the same as a power-on reset or an external reset.
FFMan wrote:it didn't appear to do anything.
On which device?

Posted: 22 June 2010, 8:38 AM
by FFMan
ZX24p

Posted: 22 June 2010, 8:53 AM
by dkinzer
FFMan wrote:ZX24p
I just ran a quick test (see code below) on several devices including the ZX-24p. All executed as expected, restarting every two seconds.

Code: Select all

Sub Main()
  Debug.Print "Hello, world!"
  Call Sleep(2.0)
  Call ResetProcessor()
End Sub

Posted: 22 June 2010, 9:56 AM
by FFMan
ok thanks - must be something amiss somewhere - i'll investigate