Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Visa "dummy write"

Im trying to read data from an EEPROM using I2C and VISA in LV.  The data sheet says I must do a "Dummy byte write sequence" in order to set the address to do a random read or a sequential read from a specific address, otherwise it simply reads form the current address.  So what is a dummy write and how do I do one wihtout overwirting data to the address Im dummy writing to?  What is I2C dummy write command string?  Something in the form of "\T?? ~??~??<CR>"

 

Thanks,

Rick

0 Kudos
Message 1 of 5
(4,496 Views)

Hello Rick,

 

I think this probably is explained in the datasheet, but also a quick google search can be very helpfull for general principles.

 

This page explains some basics on I2C including the dummy write, as I understand it, it simply is the write action for setting the adress (pointer) before sending a read command. 

 

Regards, W

0 Kudos
Message 2 of 5
(4,477 Views)

Thanks for the Google tip, would have never thought of that.  The data sheet says send a dummy write, period and yes I get I2C bus signaling.  What I'd like to know is the sequence of VISA commands to get these signals on the bus. Unfortunately my search of the NI knowledge base did not uncover the relation between VISA commands (\D \R \T etc) and I2C bus signaling.  Perhaps you could point me to a relevant tutorial?

 

Cheers,

Rick

0 Kudos
Message 3 of 5
(4,467 Views)

Situation: Running LabVIEW on a PC, with USB port connected to a USB to I2C converter connected to EEPROM.  Here is the part that I missed, the string sent to the VISA is a command to the converter device to create a message to send on to the I2C bus.  For this particular device the  commands required are /D~00<CR> to Select I2C device at  I2C address A0h  /*T~01<CR> to transmit single byte address of 01h if memory < 256 bytes else /*T~01~00<CR>  to set byte address to 100h.  followed by /R10 to read 16 consecutive bytes beginning from the address set by the dummy write (ie the /T command).  The "*" initiates the I2C no-stop which prevents the current master from loosing bus arbitration in a multi master system.   

0 Kudos
Message 4 of 5
(4,453 Views)

Glad to hear you found the solution to your problem, maybe you can list the hardware you are using together with the solution so others using the same hardware can use this as a reference, I'd suggest you accept that message as the solution.

 

regards, W

0 Kudos
Message 5 of 5
(4,438 Views)