Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Java (http://www.chiefdelphi.com/forums/forumdisplay.php?f=184)
-   -   I2C class (http://www.chiefdelphi.com/forums/showthread.php?t=154543)

mikets 31-01-2017 19:28

I2C class
 
We are planning to write some I2C code and am looking at the I2C class. It seems this class only provides synchronous access to an I2C device. Is this correct? If so, is there a class that will provide asynchronous access? I.e. providing methods to check if the bus is not busy so we can fire off a bus transaction and either have a callback when the data is ready to be read or some sort of isCompleted() method to check if the transaction is completed.

codedr 03-02-2017 23:40

Re: I2C class
 
Why not start a thread and process your I2C requests inside of it?
Post your results in the class and provide a method to call from the robot main loop to fetch the most current value.

mikets 04-02-2017 00:28

Re: I2C class
 
Yep, that's what we came to that conclusion.


All times are GMT -5. The time now is 09:55.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi