Instrument Control (GPIB, Serial, VISA, IVI)

Showing results for 
Search instead for 
Did you mean: 

C# gpib as listener with multiple secondary addresses

Hey all. I've got a little problem I've been beating my head against a wall on. 


I am writing a GPIB Listener program to emulate some hardware following the example found at as a foundation:


The issue I have is that the hardware I need to emulate uses multiple different secondary addresses for each module in it. It's an old beast. 


Anyway, is there some method in C# to create multiple listeners with different secondary addresses using only a single GPIB hardware interface? Or perhaps a way to read what the secondary address request from the message is so that I can parse it?



Message 1 of 6

Create a class gpibListener with a property secondaryAddress that is set when an object is created.


You'd end up an array of gpibListener objects.



0 Kudos
Message 2 of 6

Thanks for the response.


I tried that. What ended up happening is that since these reference a single interface (since I only have 1 in the system) then the secondary address for all members of the array are set to the value of the last member since that is the last secondary address assigned.


Another method I tried is cycling through the secondary addresses but that only gives intermittent connection at best.


I'm not currently at me work PC or I would post code.

0 Kudos
Message 3 of 6

It sounds like you have some sort of mainframe like a PXI which has 1 main address but then you have modules which plug which which has a secondary address.



0 Kudos
Message 4 of 6

That's exactly like what I'm dealing with here.

0 Kudos
Message 5 of 6

Did you find a solution? I have the same issue.

0 Kudos
Message 6 of 6