weak reference event listeners for amfcaller
usleep instead of sleep for examples
stop repeat on change method
usleep instead of sleep for test