Jpeg File transfer from Instrumental to PC.
Hello, Please give your help regarding captured Jpeg file transferring from instrumental to PC via NI-VISA on VB.NET with followings.
DMM.WriteString("MMEMory:DATA? 'AAA.jpg'")
out_Msg = DMM.ReadString
returned message includes <header> and <Bindata>.
<headder> includes Len of Bindata(num of byte).
So I removed <headder> part and converted it to byte style by following.
Dim bs As Byte() = System.Text.Encoding.GetEncoding("shift_jis").GetBytes(remain_msg)
And wrote it as binary.
fs.Write(bs, 0, bs.Length)
After that, File was saved as Jpeg but can't open as pitcure.
I compared with original Jpeg got from instrumental.and I made via above. Actual File size is little bit different from original jpeg.
Also character corruption are seen.
Does someone has idea to fix it ? or any good sample program ?