Byte to Long in Matlab

3 vues (au cours des 30 derniers jours)
Karthick Jonagadla
Karthick Jonagadla le 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.

Réponse acceptée

Walter Roberson
Walter Roberson le 13 Jan 2016
typecast(uint8(a), 'int32')
  1 commentaire
Karthick Jonagadla
Karthick Jonagadla le 13 Jan 2016
thanks :-)

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur MATLAB dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by