Welcome Guest,Register Now
Log In

ANT Forum

Welcome guest, please Login or Register

   

AntUSB-m stick connected to low battery android mobile is having a transmission delay.

Rank

Total Posts: 22

Joined 2015-01-28

PM

Hi,there

I am working on android app(antUSB stick connected externally to mobile) which is controlling motor (having ant build in support) speed by + or - power button on aap .

When I am using antUSB-m stick to connect to mobile. which is providing lower speed to transmit to the motor(in build ant support).(delay of 1 to 4 seconds).after this delay motor is responding.
I am also used to ANTware II software to understand this issue.

now this time i use antUSB-m stick connecting to mobile only.i found that Antware II also receive and display data with same delay.but this time if i change antUSB-m stick to computer and antUSB2 to mobile its having no transmission delay.means antUSB-m stick can't operating efficiently with mobile voltage(as it is connected to mobile and having low battery)
when i am using antUSB2 stick connected to mobile it works fast. motor is giving response as i press power button.also on ANTware II is also giving fast response.

I want my app should not have any issue regarding this.
     
Rank

Total Posts: 4

Joined 2011-08-22

PM

Hi thorat,

There should be no transmission delay because of voltage differences, I would expect the module to just stop working all together in this case. One thing to check though is to make sure that you are disabling event buffering on the usb-m, as it is enabled by default on the android stack. This causes the received data and event tx messages to be buffered on the usb and then flushed to the application once every 2 seconds which may explain your applications behaviour, especially if you are triggering the sending of new messages of EVENT_TX event. The USB-2 doesn't support this feature so that's probably why it works properly.

Hope this helps,
James      
Rank

Total Posts: 22

Joined 2015-01-28

PM

Thank you sir ,
your suggestion work for me

I have added this function like this
if(mAntChannel.getEventBufferSettings()!=null)
{
mAntChannel.disableEventBuffer();
}
getEventBufferSetting() function chech for whether its USB2 or MicroUSB.