14.1.2 RAYLASE Protocol |
The RAYLASE Protocol is based on the 14.1.1 Enhanced Protocol but extends it by allowing parameters of variable length.
The API does allow to either use TransceiveRaylase if an answer from the scanhead is expected or TransmitRaylase if not.
using ( ClientAPI client = new ClientAPI( myCardIP ) ) { client.System.ResetToDefaults(); int timeoutMs = 500; byte[] message = new byte[] { 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48 }; int head = 0; try { byte[] answer = client.ScannerCommunication.TransceiveRaylase( head, Axis.X, message, timeoutMs ); Console.Out.WriteLine( "Answer={0}", string.Join( " ", answer.Select( n => string.Format( "[0x{0:X2}]", n ) ) ) ); } catch ( TimeoutException e ) { Console.WriteLine( "Could not receive an answer in the given timespan. {0}", e ); } }