system.vibrate

Hello,

I have tried adding system.vibrate() to an app and have added the permission to build.settings, see below, but no sound is generate like the documentation indicates in the simulator.  I have *not* tried to deploy to a device.

****** snip ******

    android =
    {
        versionCode = “11”,
        usesPermissions =
        {
            “android.permission.VIBRATE”,
        }
    },

****** snip ******

Thank you, please advise.

Noral

Hi @Noral,

Which OS are you using, Mac or Windows? I tested this on Mac and it produces a beep; perhaps on Windows it does not. I’ll check into it.

Best regards,

Brent

Thanks Brent,

I guess I should have mentioned that ;)  I am working on Windows 7 - x64.  I am using the lates Starter build of Corona.

Thank you,

Noral

PING

Well I know Brent’s a bit buys with another project.  The engineers confirmed today that on Windows, vibrate should do nothing.

I’ve submitted a request to get the docs clarified on this. 

Rob,

Do I understand you correctly that this will not be fixed in the Windows simulator?  How hard is it to make the console beep or just play a wav/mp3?  I mean a beep in C++, on Windows, it is as simple as:

BOOL WINAPI Beep(
  _In_  DWORD dwFreq,
  _In_  DWORD dwDuration
);

Beep( 750, 300 );

While no one has specifically said this I am getting the feeling from reading the forums and stackoverflow that Corona is focusing mainly on iOS and there seems to be more functionality/focus on the simulator for the Mac.  It also troubles me that the Windows simulator does not have, at the very least, simulated keys for Volume Up, Volume Down, Menu, Back … let alone Home, Power, Search for complete Android key functionality or the ability to simulate a device like the GPS(not a static location).  Installing the package on a device to test these items seems rather unproductive.

I am not trying to be difficult - I am researching options for application creation on multiple devices and weighing the options of each cross platform toolkit.

Noral

 

Hi @Noral, I’m not sure you can take chatter on Stackoverfow as reality.  I would suggest you look through the release notes for the last public build and compare the number of iOS related entries to the Android entries, as well as the Windows entries to the Mac entries you will see that Android and Windows gets more than a fair share of developer attention.   Sure a few years ago, iOS/Mac got quite a bit more, but at that time the market was all about iOS and Android wasn’t that big,  Today, we pretty much give them equal attention if not a bit more skewed to Android.

Please don’t take this the wrong way, but of all the features that need added and the bugs that need fixed, getting the simulator to beep for system.vibrate() is pretty low on the list. There will always be things that need to be done on device and vibration is a device feature.  If it’s really important to get feedback in the simulator, you could easily override it with some code that checked if your on a simulator and play a buzzing sound. 

As for the simulated keys, on the Mac we only get Rotate Left, Rotate Right and shake.  There are no facilities in the Mac for those android keys as well.  I think having those feature would be quite nice to support.  We’ve recently added a bunch of keyboard support for Android (which Windows got and Mac did not) for handling keyboards, controllers and mice.  These simulated keys would be a core change to affect both platforms, but they are pretty important.

What I would would recommend is that you visit  http://feedback.coronalabs.com  and put in feature requests for these items.  Those items may already be there, in which case you can vote up any existing requests.  This is our system for collecting features that the community feels are important and we actively use that list to help sort out features to be worked on in the future.

Back to the beep.  I’m not going to say it won’t be fixed.  You will need to goto the feed back site and put in a feature request for it as well.  Given that it doesn’t impact building apps or the functioning of apps and it’s easily worked around, it’s not going to be a high priority item to fix, but it’s also probably a trivial thing to fix.  When the engineers pick the things they are going to work on, they will add in some of these easy fixes too.  This is the method for getting this kind of request in front of the engineers as they decide what to work on.

Hi @Noral,

Which OS are you using, Mac or Windows? I tested this on Mac and it produces a beep; perhaps on Windows it does not. I’ll check into it.

Best regards,

Brent

Thanks Brent,

I guess I should have mentioned that ;)  I am working on Windows 7 - x64.  I am using the lates Starter build of Corona.

Thank you,

Noral

PING

Well I know Brent’s a bit buys with another project.  The engineers confirmed today that on Windows, vibrate should do nothing.

I’ve submitted a request to get the docs clarified on this. 

Rob,

Do I understand you correctly that this will not be fixed in the Windows simulator?  How hard is it to make the console beep or just play a wav/mp3?  I mean a beep in C++, on Windows, it is as simple as:

BOOL WINAPI Beep(
  _In_  DWORD dwFreq,
  _In_  DWORD dwDuration
);

Beep( 750, 300 );

While no one has specifically said this I am getting the feeling from reading the forums and stackoverflow that Corona is focusing mainly on iOS and there seems to be more functionality/focus on the simulator for the Mac.  It also troubles me that the Windows simulator does not have, at the very least, simulated keys for Volume Up, Volume Down, Menu, Back … let alone Home, Power, Search for complete Android key functionality or the ability to simulate a device like the GPS(not a static location).  Installing the package on a device to test these items seems rather unproductive.

I am not trying to be difficult - I am researching options for application creation on multiple devices and weighing the options of each cross platform toolkit.

Noral

 

Hi @Noral, I’m not sure you can take chatter on Stackoverfow as reality.  I would suggest you look through the release notes for the last public build and compare the number of iOS related entries to the Android entries, as well as the Windows entries to the Mac entries you will see that Android and Windows gets more than a fair share of developer attention.   Sure a few years ago, iOS/Mac got quite a bit more, but at that time the market was all about iOS and Android wasn’t that big,  Today, we pretty much give them equal attention if not a bit more skewed to Android.

Please don’t take this the wrong way, but of all the features that need added and the bugs that need fixed, getting the simulator to beep for system.vibrate() is pretty low on the list. There will always be things that need to be done on device and vibration is a device feature.  If it’s really important to get feedback in the simulator, you could easily override it with some code that checked if your on a simulator and play a buzzing sound. 

As for the simulated keys, on the Mac we only get Rotate Left, Rotate Right and shake.  There are no facilities in the Mac for those android keys as well.  I think having those feature would be quite nice to support.  We’ve recently added a bunch of keyboard support for Android (which Windows got and Mac did not) for handling keyboards, controllers and mice.  These simulated keys would be a core change to affect both platforms, but they are pretty important.

What I would would recommend is that you visit  http://feedback.coronalabs.com  and put in feature requests for these items.  Those items may already be there, in which case you can vote up any existing requests.  This is our system for collecting features that the community feels are important and we actively use that list to help sort out features to be worked on in the future.

Back to the beep.  I’m not going to say it won’t be fixed.  You will need to goto the feed back site and put in a feature request for it as well.  Given that it doesn’t impact building apps or the functioning of apps and it’s easily worked around, it’s not going to be a high priority item to fix, but it’s also probably a trivial thing to fix.  When the engineers pick the things they are going to work on, they will add in some of these easy fixes too.  This is the method for getting this kind of request in front of the engineers as they decide what to work on.