diff options
author | Michael J. Chudobiak <mjc@avtechpulse.com> | 2012-10-15 12:48:09 -0400 |
---|---|---|
committer | Michael J. Chudobiak <mjc@avtechpulse.com> | 2012-10-15 12:48:09 -0400 |
commit | 047fcb18ded8438d5763ad537c64a2c110052a11 (patch) | |
tree | 9d1389954f929466c7f2a4dad6721c27387b7435 /gpib.c | |
parent | c3f7e27f94563adc50e857d31c602ec03c2e7332 (diff) |
first attempt at gpib query responses
Diffstat (limited to 'gpib.c')
-rw-r--r-- | gpib.c | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -3,6 +3,7 @@ #include "flash.h" #include "error_utils.h" #include "bus.h" +#include <glib.h> /* TNT Configuration --------------------------------------------------------*/ @@ -770,12 +771,18 @@ static void TNT_Holdoff_off() } -int GPIB_send_query_response(char *out_buffer) +int GPIB_send_query_response(char *in_string) { if (!globals.HWDetect.gpib) { return OK; } + if (GPIB_response_already_pending()) { /* if MAV already, data will be lost. Set QYE bit in STB. */ + queue_error_for_gpib_only(query_error_interrupted); + } + + gchar *out_buffer = g_strdup_printf ("%s\n", in_string); + /* message must be available if this function has been called */ unsigned long int out_cnt; |