LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to delete a single byte out of a word array

hi my question is about how to delete a single byte out of a wordarray
my problem is that i write 9 bytes (string) to an array (word) so the smallest unit is two bytes per cell in this array
so i want to delete the last byte out of a 5 word array
i allready cut the string in little 2 byte blocks but nothing works till now so if anyone could help
feel free to answer thx tobias
0 Kudos
Message 1 of 5
(3,123 Views)
Hi,
do it like in the attached jpeg. First, you should determine the length of the string then just substract the bytes and use this as an input for string subset. Sorry for the crappy pic if you need a better pic I will try to give you another in the afternoon...

Mike

Message Edited by mischi_miyagi on 12-07-2006 05:09 AM

Win XP, LabView 8.20
0 Kudos
Message 2 of 5
(3,116 Views)
1. of all thx 4 the help but this is unfortunatly not the answer i m looking for
to describe the problem again
 
i build an array of words so 2 bytes per cell
 
i have some variables which are odd when i sum them so i get e.g 39 bytes
the next step is to get them in the array no problem cause i can use 20 words=40 bytes, but i have to write this array
to an eeprom where the adress of the 40th byte is allready used so my question is now is there any
possibillity to delete the 40th byte out of the wordarray
 
i hope the question gets clear now so i hope u or maybe someone else know how to do this
thx 4 all tobi
0 Kudos
Message 3 of 5
(3,089 Views)

If you are going to use a I16 (2 bytes), then you must have an even number of bytes.  There is no way to tell LabVIEW or really an language that I can think of that I want to have an array of I16s that is 1.5 bytes long, which is basically what you want.  In the physical memory that word is 2 bytes.

Why not simply use bytes or I8s instead.  You can then define the array to be 39 bytes long.

0 Kudos
Message 4 of 5
(3,077 Views)

hi evan could you send me a picture of the facts you told me or even better a small vi cause i didnt work with l16 so it would be interesting to see how that finally works

this would be very nice

in addition thx 4 your help

hear u again..... hope so ??? ciao tobi

0 Kudos
Message 5 of 5
(3,061 Views)