----- continuation of previous message
And here is the ouptut for the same windows command (interestingly,
with 0ms delay only sporadigly it would give any output ...whereas for
linux every second output is displayed):
1. viParseRsrc (0x02425500, "COM3", 4, 3)
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.093 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
2. VISA Set Attribute ("COM3", TMO_VALUE, 10000)
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.093 Call Duration 00:00:00.047
Status: 0 (VI_SUCCESS)
3. VISA Set Attribute ("COM3", ASRL_BAUD, 460800)
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.140 Call Duration 00:00:00.016
Status: 0 (VI_SUCCESS)
4. VISA Set Attribute ("COM3", ASRL_DATA_BITS,
😎Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.156 Call Duration 00:00:00.015
Status: 0 (VI_SUCCESS)
5. VISA Set Attribute ("COM3", ASRL_STOP_BITS, 10)
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.171 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
6. VISA Set Attribute ("COM3", ASRL_PARITY, 0)
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.171 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
7. VISA Set Attribute ("COM3", TERMCHAR_EN, 0)
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.171 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
8. VISA Set Attribute ("COM3", TERMCHAR, 10)
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.171 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
9. VISA Set Attribute ("COM3", ASRL_FLOW_CNTRL, 0)
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.171 Call Duration 00:00:00.016
Status: 0 (VI_SUCCESS)
10. VISA Set Attribute ("COM3", ASRL_END_IN, 0)
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.187 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
11. VISA Write ("COM3", "~E.E.....")
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.187 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
12. VISA Get Attribute ("COM3", ASRL_AVAIL_NUM, 17)
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.187 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
13. VISA Read ("COM3", 17, "~k..*............")
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.187 Call Duration 00:00:00.000
Status: 0x3FFF0006 (VI_SUCCESS_MAX_CNT)
14. VISA Close ("COM3")
Process ID: 0x00000DCC Thread ID: 0x00000954
Start Time: 16:14:25.187 Call Duration 00:00:00.031
Status: 0 (VI_SUCCESS)
************************************************************************************************************
Now i do the same with 50ms time delay error under linux:
1. viParseRsrc (0x0A7318D8, "ASRL5::INSTR", 4, 5)
Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:29.914 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
2. VISA Set Attribute ("ASRL5::INSTR", TMO_VALUE, 10000)
Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:29.915 Call Duration 00:00:00.013
Status: 0 (VI_SUCCESS)
3. VISA Set Attribute ("ASRL5::INSTR", ASRL_BAUD, 921600)
Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:29.928 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
4. VISA Set Attribute ("ASRL5::INSTR", ASRL_DATA_BITS,
😎Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:29.928 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
5. VISA Set Attribute ("ASRL5::INSTR", ASRL_STOP_BITS, 10)
Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:29.928 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
6. VISA Set Attribute ("ASRL5::INSTR", ASRL_PARITY, 0)
Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:29.928 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
7. VISA Set Attribute ("ASRL5::INSTR", TERMCHAR_EN, 0)
Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:29.928 Call Duration 00:00:00.001
Status: 0 (VI_SUCCESS)
8. VISA Set Attribute ("ASRL5::INSTR", TERMCHAR, 10)
Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:29.929 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
9. VISA Set Attribute ("ASRL5::INSTR", ASRL_FLOW_CNTRL, 0)
Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:29.929 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
10. VISA Set Attribute ("ASRL5::INSTR", ASRL_END_IN, 0)
Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:29.929 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
11. VISA Write ("ASRL5::INSTR", "~E.E.....")
Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:29.929 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
12. VISA Get Attribute ("ASRL5::INSTR", ASRL_AVAIL_NUM, 19)
Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:29.986 Call Duration 00:00:00.001
Status: 0 (VI_SUCCESS)
> 13. VISA Read ("ASRL5::INSTR", 19, "~k×.(............")
> Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
> Start Time: 16:17:29.987 Call Duration 00:00:10.002
> Status: 0xBFFF0015 (VI_ERROR_TMO)
14. VISA Close ("ASRL5::INSTR")
Process ID: 0x000021C2 Thread ID: 0xB56CBBA0
Start Time: 16:17:39.989 Call Duration 00:00:00.009
Status: 0 (VI_SUCCESS)
**********************************************************************************
Under
windows I could not get any data this way I had the required 17 bytes
but normally nothing would come up (different to the vi i am using
which checks every 10ms on the port to see if bytes are waiting to be
processed ...)
but this output I get always from a serial terminal
under linux (the requested 17 bytes hence somehow labview adds the two
bytes, the driver seems to behave, please note I have 921600 baut used
at teh serial terminal):
00000000: 7e 6b 0a 9c f5 08 00 ff ff 00 00 00 00 00 00 00
00000010: 00
Hope this helps to clarify
Thanks