petr4ppc Well-Known Member Licensed User Longtime User Mar 2, 2022 #1 Dear friends, please for advice, how can I write the value of bytes from this Arduino code: B4X: long firstvalue = 0 long secondvalue = 500 buf(0)=secondvalue >> 8 buf(1)=firstvalue >> 16 buf(2)=firstvalue >> 24 in B4R? Best regards p4ppc
Dear friends, please for advice, how can I write the value of bytes from this Arduino code: B4X: long firstvalue = 0 long secondvalue = 500 buf(0)=secondvalue >> 8 buf(1)=firstvalue >> 16 buf(2)=firstvalue >> 24 in B4R? Best regards p4ppc
R RJB Active Member Licensed User Longtime User Mar 2, 2022 #2 B4X: buf(0) = Bit.ShiftRight(secondvalue, 8) ? buf(0) = second byte of secondvalue (from LSB) Upvote 0
petr4ppc Well-Known Member Licensed User Longtime User Mar 2, 2022 #3 Thank you very much RJB, Best regards, p4ppc Upvote 0