An alternative way to use MATLAB with typecast :
>> A = '123123123123123A'; >> B = typecast(uint32(hex2dec([A(9:end);A(1:8)])), 'uint64') B = 1310867527582290490
And vice versa in the opposite direction:
>> AA = dec2hex(typecast(B,'uint32')); >> AA = [AA(2,:) AA(1,:)] AA = 123123123123123A
The idea is to treat a 64-bit integer as two 32-bit integers.
However, Simulink does not support the int64 and uint64 , as others have already noted.
source share