I would then start putting explicit casts in the offending line. The PC's compiler may be secretly promoting the chars to ints or something. MS
Igor wrote: > > > ---------- Forwarded message ---------- > From: *Igor* <igorcomp...@gmail.com <mailto:igorcomp...@gmail.com>> > Date: 2010/7/20 > Subject: Re: [Tinyos-help] String manipulation > To: Michael Schippling <sc...@santafe.edu <mailto:sc...@santafe.edu>> > > > Hi, thanks for your help. > > I actually misstyped when i was writing the previous message. > > I have two keys, k1 and k2 declared like this: uint8_t k1[10] = > "1234543253"; uint8_t k2[10] = "1234543323" > I need to distribute those keys btween the motes and to do that in a > secure way i need to do the xor between k1 e k2. So i did like this > > int i ; > uint8_t result[10]; > for(i = 0; i < 10; i++) > result[i] = k1[i] ^ k2[i]; > > I don't know what is wrong with this algorithm, but the compiler have > returned the following error: invalid value in assignment. > > I don't know what to do to solve this problem, i have already googled > but i am still lost here. > > Thanks for your help. > > I forgot to mention that this error just happens when I try to compile > in the sumulation mode -> make micaz sim > > > ------------------------------------------------------------------------ > > _______________________________________________ > Tinyos-help mailing list > Tinyos-help@millennium.berkeley.edu > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help _______________________________________________ Tinyos-help mailing list Tinyos-help@millennium.berkeley.edu https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help