Detect a trigger from FPGA by Csharp

Hello everyone,

I would like to detect a trigger from FPGA (a ready signal from FPGA) to start a Pipe readout in Csharp. I tried with following commands
public Boolean IsTriggered(ushort addr, ushort bitnum)
{
m_dev.UpdateTriggerOuts();
return m_dev.IsTriggered((int)addr, bitnum);
}
And in my main form I use a while loop to check:
while (true)
{
if (board.IsTriggered(0x60, 1) == true)
{
result.Text = “There is a trigger”;
break;
}
}
however, it does not work. I am using Frontpanel version 4.0.3 (I prefer to keep the same version)

Could anyone please help me to detect a trigger from FPGA?

Thank you very much,
lethaiha

@lethaiha-- Please refer to the counters sample for a working example of triggers.

— Begin quote from Opal Kelly Support;4081

@lethaiha-- Please refer to the counters sample for a working example of triggers.

— End quote

Thanks, however, there is only a XML FrontPanel version in the the Counter sample. I have no problem with the XML but the Csharp. Could you please help me with Csharp code?

What I mean is, have you tried using the Counters sample bitfile to test your C# code with a known-good HDL?

Your C# code looks reasonable.