Forums | developer.brewmp.com Forums | developer.brewmp.com

Developer

Forums

Forums:

Hello,

I am writing a Perl script for automation. The application is showing a slideshow or video after pressing the OK key in the device.

1. How does the script be written so that it can automatically detect if the video is playing or not? Is there any API (though I didnot see in brew grinder)?

2. How can the script detect and displays what is the listings in the main menu?

3. If everything is successful the testcase should pass otherwise its failed. How it detects if the application is running successfully?

So far my scripts can send specific key events at specific intervals using grinder API . Some code :

#Send individual key events
GrinderPl::SendKey(AVK_SELECT);
#GrinderPl::PressKey(AVK_SELECT,20000);
GrinderPl::SetEventInterval(22000); #22 seconds interval between events

GrinderPl::SendKey(AVK_SELECT);
GrinderPl::PressKey(AVK_SELECT,5000);
sleep(12);
print ("Video Playing....\n");

But my intension is, the script should detect everything automatically.

Any help would be appreciated :confused:
Thanks in advance.