Jump to content

As of July 17, 2015, the LabJack forums here at forums.labjack.com are shut down. New registrations, topics, and replies are disabled. All forums are in a read-only state for archive purposes.

Please visit our current forums at labjack.com/forums to view and make new posts. To post on the current forums, use your labjack.com login account. Your old LabJack forums login credentials have been retired. There are no longer separate logins for labjack.com and LabJack forums.


Photo

U3/LJTick channel reversal


  • Please log in to reply
2 replies to this topic

#1 brodsky

brodsky
  • Members
  • 17 posts

Posted 09 January 2014 - 12:27 PM

I've duplicated the LJTick commanding code given in the exodriver example "u3LJTDAC.c" for use in my own applications.

I'm using a U3-HV with LJTick connected to the FI04/FIO5 section.

 

This works fine, EXCEPT:  I'm finding that between applications, the channel 0 and channel 1 outputs can BE REVERSED.

In other words, in one application, when I send a command to channel 0, the voltage registers on FIO4 as expected (with none on FIO5).

But in another app, it's reversed:  commanding channel 0 results in voltage on FIO5 (none on FIO4), and vice-versa.

 

I know the channel numbers and command voltages as I'm printing them right before the call to getTdacBinVoltCalibrated()

 

How can this happen?

 

Thanks,

- Pete

 



#2 LabJack Support

LabJack Support
  • Admin
  • 8677 posts

Posted 09 January 2014 - 12:55 PM

Perhaps you are not setting the correct command byte for DACA and DACB in your I2CBytes. For the I2C bytes you send, the first byte is the command byte specifying the DAC to set and the next two bytes are the voltage. DACA is address h0x30 and DACB is h0x31. The example demonstrates setting both and look like this when configuring the I2CBytes/bytesCommand specifying which DAC to set:

bytesCommand[0] = (uint8)(0x30);  //LJTDAC command byte : h0x30 (DACA)
bytesCommand[0] = (uint8)(0x31);  //LJTDAC command byte : h0x31 (DACB)

If that doesn't help, post the parameters you pass to the I2C function or the command bytes of the I2C low-level function in you applications.



#3 brodsky

brodsky
  • Members
  • 17 posts

Posted 09 January 2014 - 01:09 PM

That was it!

 

Thank you.

- Pete




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users