Byte to Long in Matlab

4 views (last 30 days)
Karthick Jonagadla
Karthick Jonagadla on 13 Jan 2016
I have a byte vector a = [166;123;34;85], I want to convert this to long. I did this in C# using BitConverter.ToInt32 but not able to figure out a way in Matlab. The answer to this is known i.e. 1428323238 Please help.

Accepted Answer

Walter Roberson
Walter Roberson on 13 Jan 2016
typecast(uint8(a), 'int32')

More Answers (0)

Categories

Find more on MATLAB in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!