Show Posts
Pages: 1 [2]
16  Products / Arduino Due / Re: I2C Repeated Start on: February 06, 2013, 02:18:30 am
You can find the code attached to one of the posts above.
The name of the attachment is MLX90614_Direct_Access.ino

Feel free to use it in any way you like.
17  Products / Arduino Due / Re: I2C Repeated Start on: February 02, 2013, 05:01:03 pm
Hello,
I use this code to read the temperature from the MLX90614 IR sensor (see attachment).
The sensore has address 0x5A and I read 3 bytes from internal address 0x07.
As you can see in the captured signal, the controller sends 2 ACK and one NACK just before the STOP condition.

I suppose there is something wrong in your code, can you send it to me to have a look? Or share it somewhere on the internet.

Best regards,
Dan.
 
18  Products / Arduino Due / Re: I2C Repeated Start on: January 30, 2013, 09:10:38 am
I have just order a Bus Pirate from a retailer in RO. I'll have it tomorrow and I'll give it a try too.
I have to look closer to this issue.
19  Products / Arduino Due / Re: I2C Repeated Start on: January 30, 2013, 02:32:36 am
Can you please post a screenshot of the output from running your algorithm with numOfBytes=2 ?
20  Products / Arduino Due / Re: I2C Repeated Start on: January 24, 2013, 01:18:34 pm
It's my mistake. Use  WIRE_INTERFACE or  WIRE1_INTERFACE
You can find both defined in variant.h
21  Products / Arduino Due / Re: I2C Repeated Start on: January 24, 2013, 10:59:24 am
The first param is a pointer to a Twi structure denoting the I2C bus that you want to use.
In the case of arduino due there are 2 I2C buses, therefore you can use WIRE_INTERFACE_ID or WIRE1_INTERFACE_ID. Both of them are defined in hardware\arduino\sam\variants\arduino_due_x\variant.h
22  Using Arduino / Interfacing w/ Software on the Computer / Re: command line development in linux on: January 23, 2013, 02:29:46 am
Hello,
I am interested in it. Does it work with the latest Arduino IDE 1.5.1? Does it support the sam architecture (as used with the Due boards) ?

Best regards,
Dan.

P.S.
You might be interested in following this issue too
http://code.google.com/p/arduino/issues/detail?id=124
23  Using Arduino / Interfacing w/ Software on the Computer / Re: Programing arduino by command line (windows) on: January 22, 2013, 03:00:45 pm
Check this out too:
https://github.com/arduino/Arduino/wiki/Arduino-IDE-1.5-from-command-line
24  Using Arduino / Interfacing w/ Software on the Computer / Re: command line development in linux on: January 22, 2013, 02:56:36 pm
Hello,
it seems that this issue is addressed in the latest IDE 1.5.1 beta.
Check this out https://github.com/arduino/Arduino/wiki/Arduino-IDE-1.5-from-command-line

I have tried it and it works. The only complain that I have is that invoking from command line also starts the GUI for the time of the execution.

Best regards,
Dan.
25  Products / Arduino Due / Re: I2C Repeated Start on: December 21, 2012, 12:35:49 pm
Hello,
I had a quick look over the LTC2489's specs and I think it would be very easy to interface it with the Due board.
  • You WRITE to the device's input register to select the input channels for the next selection. Input register is 8bit long.
  • You READ from the device's output register the value of the last conversion. The output register is 24bit long
  • The device starts a new conversion after the output register is READ and the master has generated a STOP CONDITION
  • If you want to select a different channel and read the previously converted value, in a single transaction, then you use a REPEATED START condition

Check out the attachment.
I'll have a look to the PCA9539, later this evening.
26  Products / Arduino Due / Re: I2C Repeated Start on: December 21, 2012, 09:15:35 am
Hello,
what board are you going to use ? What are the specific I2C transactions that you'll need?

With the Due board, I was able to read/write from/to an internal register of a I2C slave device (MLX90614), using the API in the libsam library. You can find the source in
arduino-1.5.1r2\hardware\arduino\sam\system\libsam\source. Look for twi.c and twi.h
The functions of interest are void TWI_StartRead and void TWI_StartWrite. They both have a parameter called uint32_t iaddress where you can put the internal address/register you want to access. If you specify it, then the controller will automatically  send a REPEATED START condition after writing the address of the slave device and of the internal register on the bus and before reading/writing the data bytes.

Best regards,
Dan.

Dan,

I'm about to start an I2C project that may require I2C repeated starts.

Have you learned anything about this issue?

-Chris
27  Products / Arduino Due / I2C Repeated Start on: December 15, 2012, 03:33:08 pm
Hi,
the last release of the Wire library has added support for an extra parameter to the Wire.endTransmission and Wire.requestFrom, to specify if a STOP should be sent or not. Nevertheless, it seems it is not working for Due. I have inspected the source code for the two aforementioned methods and they ignore the boolean parameter altogether. I have also inspected the SCL and SDA lines with an oscilloscope   and I could clearly see the STOP condition being sent.

Am I missing something? or is this not supported on Due yet?

Best regards,
Dan.

P.S.
See the attached files.
28  Products / Arduino Due / Re: I2C not working on: December 15, 2012, 03:10:49 pm
I am not sure that I2CScanner works on Due at all. I have a BMP0854 too and it failed to show up with I2CScanner, though, it works perfectly well if I am reading it's registers using the Wire library.

Just keep in mind that SDA (pin 20)/SCL (pin 21) do have  1k5  pullup resistors soldered on board while SDA 1/SCL 1 do not have them so you'll have to put them yourself.

Best regards,
Dan.
Pages: 1 [2]