LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Writing characters to text file to convert the data into image

Hi Hasan,

is the data from your post before the entire image? Is it all you have? Can you upload a vi with your data in a string constant? What is the expected image format? Looks like jpg for me.

 

Mike

0 Kudos
Message 11 of 31
(2,038 Views)
While we are at this. Kudo this idea.....
0 Kudos
Message 12 of 31
(2,036 Views)
I need to write all the data into text file. The value 0x00 is interpreted as 0x20 in labview. how can I handle this?
0 Kudos
Message 13 of 31
(2,031 Views)

Hi Hasan,

as already mentioned, write your file as binary file.

Can you upload such an example?

 

Mike

0 Kudos
Message 14 of 31
(2,027 Views)
The problem i think is that .... while writing data to the file, labview converts 0x00 to 0x20 ...... how can i handle this?
0 Kudos
Message 15 of 31
(2,026 Views)

hi mike... this is not the whole data, its only the frst package. I have 12 packets similar like this.

 

am attaching the file that i need to write them in text file as characters and then convert the extension of that txt file into jpg. so that i can read the image.

 

i have attached the whole file. I need to display this file as jpeg image. the image should look like the attached image (image.jpg)

Download All
0 Kudos
Message 16 of 31
(2,017 Views)

Mike

 

the source code is very cumbersome to obtain all the data one by one following the protocols.

 can you please tell me how to convert the file (example values.txt) into jpeg image  using labview?... the image should look like the second attachment (image.jpg) in the previous post

0 Kudos
Message 17 of 31
(2,014 Views)

Hi Hasan,

if i write it like this, then i get the result you show in your post.

 

Mike

Message Edited by MikeS81 on 04-13-2010 09:52 AM
0 Kudos
Message 18 of 31
(2,013 Views)

Mike

 

How are you converting/writing this hex file into jpeg image? can you please post your code?

what i am getting the image is attached here (Distorted image.jpg)

only first row is visible but the rest of the image is distorted. Please tell me how can I obtain the actual image?

0 Kudos
Message 19 of 31
(2,008 Views)

Hi Hasan,

if you have the image data as text, as you have posted before, then the attached code works to generate the jpg file.

 

Mike

Message Edited by MikeS81 on 04-13-2010 10:08 AM
0 Kudos
Message 20 of 31
(1,998 Views)