SUB-20 error: Failed to submit async transaction

All about Sub-20 Multi Interface USB Adapter USB to I2C, SPI, GPIO, RS232, RS485, Ir, LCD

Moderator: serg

Post Reply
eryn
Posts: 4
Joined: Mon Dec 13, 2010 10:11 am

SUB-20 error: Failed to submit async transaction

Post by eryn »

Hi,

I am currently using the SUB-20-B multi interface USB adapter to connect my motor drivers via GPIO and communicate with core board using USB.
I always get the error

"Failed to submit async transaction" for I2C application.

May I know what is the probable cause for this error?

Thank you very much.

xol
Site Admin
Posts: 241
Joined: Sat Aug 29, 2009 8:04 am

Re: SUB-20 error: Failed to submit async transaction

Post by xol »

Hi,
Please tell us what OS do you use?
What API calls?
How often it happens?

eryn
Posts: 4
Joined: Mon Dec 13, 2010 10:11 am

Re: SUB-20 error: Failed to submit async transaction

Post by eryn »

We are using Emdebian 2.6.26.
We are trying to write speed and instruct motor to start at one direction using sub_i2c_write.
It happen quite often and when this happen we have to restart our OS in order to get the I2C works at normal condition.

Sometimes it happens since the first call and sometimes after a few calls.

xol
Site Admin
Posts: 241
Joined: Sat Aug 29, 2009 8:04 am

Re: SUB-20 error: Failed to submit async transaction

Post by xol »

In this case let's try to disable ASYNC transactions and use synchronous one.
Comment out in libsub.h this definition:

Code: Select all

#define ASYNC_OUT

eryn
Posts: 4
Joined: Mon Dec 13, 2010 10:11 am

Re: SUB-20 error: Failed to submit async transaction

Post by eryn »

As I know async transaction prevent other master to use the bus line when it is busy.
Normally, our program transmit data to only one slave at a time. So, I am confuse on this.

Meanwhile, may I know what is affected or different by changing of asynchronous mode to synchronous mode?
Thank you very much.

xol
Site Admin
Posts: 241
Joined: Sat Aug 29, 2009 8:04 am

Re: SUB-20 error: Failed to submit async transaction

Post by xol »

Hi,
In your case there should be no affection. Async transaction was introduced In libusb-1-x we are using as bottom layer. It let's submit USB request and do not block until it's completion. We use it to speed up back to back API calls.
But in case of I2C you should not see any difference as I2C is pretty slow compared to USB and we will wait any way for the transaction processing.

As for arbitration it has no difference. Arbitration is done in open function. Once you open SUB-20 no other process could do it.

eryn
Posts: 4
Joined: Mon Dec 13, 2010 10:11 am

Re: SUB-20 error: Failed to submit async transaction

Post by eryn »

Maybe commenting asynchronous transaction out may help.
But I am still curious on what might be the event that trigger this error, if you don't mind to tell me.
Thanks

xol
Site Admin
Posts: 241
Joined: Sat Aug 29, 2009 8:04 am

Re: SUB-20 error: Failed to submit async transaction

Post by xol »

First of all check it with commented line to be sure it helps. Otherwise our assumptions are useless and we have to look for another reason of the problem.

Post Reply