文件名称:conversion_gui
-
所属分类:
- 标签属性:
- 上传时间:2012-11-16
-
文件大小:7.69kb
-
已下载:0次
-
提 供 者:
-
相关连接:无下载说明:别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容来自于网络,使用问题请自行百度
function ret = Int2Hex(var)
Prints integer array to hexadecimal string
varType = class(var)
cast signness away:
if ( u ~= varType(1) )
varType = [ u varType]
var = typecast(var,varType)
end
nBits = str2double(varType(5:end))
if (64 == nBits)
split 64 bit case into two 32 s
cuz dec2hex doesn t handle 64 bit...
varType(5:end) = 32
var = typecast(var,varType)
end
ret = dec2hex(var)
if (64 == nBits)
littleEndian = all(typecast(uint32(1), uint16 )==[1 0])
first = 1 + littleEndian
second = 2 - littleEndian
ret = [ret(first:2:end,:),ret(second:2:end,:)]
end
end-function ret = Int2Hex(var)
Prints integer array to hexadecimal string
varType = class(var)
cast signness away:
if ( u ~= varType(1) )
varType = [ u varType]
var = typecast(var,varType)
end
nBits = str2double(varType(5:end))
if (64 == nBits)
split 64 bit case into two 32 s
cuz dec2hex doesn t handle 64 bit...
varType(5:end) = 32
var = typecast(var,varType)
end
ret = dec2hex(var)
if (64 == nBits)
littleEndian = all(typecast(uint32(1), uint16 )==[1 0])
first = 1 + littleEndian
second = 2 - littleEndian
ret = [ret(first:2:end,:),ret(second:2:end,:)]
end
end
Prints integer array to hexadecimal string
varType = class(var)
cast signness away:
if ( u ~= varType(1) )
varType = [ u varType]
var = typecast(var,varType)
end
nBits = str2double(varType(5:end))
if (64 == nBits)
split 64 bit case into two 32 s
cuz dec2hex doesn t handle 64 bit...
varType(5:end) = 32
var = typecast(var,varType)
end
ret = dec2hex(var)
if (64 == nBits)
littleEndian = all(typecast(uint32(1), uint16 )==[1 0])
first = 1 + littleEndian
second = 2 - littleEndian
ret = [ret(first:2:end,:),ret(second:2:end,:)]
end
end-function ret = Int2Hex(var)
Prints integer array to hexadecimal string
varType = class(var)
cast signness away:
if ( u ~= varType(1) )
varType = [ u varType]
var = typecast(var,varType)
end
nBits = str2double(varType(5:end))
if (64 == nBits)
split 64 bit case into two 32 s
cuz dec2hex doesn t handle 64 bit...
varType(5:end) = 32
var = typecast(var,varType)
end
ret = dec2hex(var)
if (64 == nBits)
littleEndian = all(typecast(uint32(1), uint16 )==[1 0])
first = 1 + littleEndian
second = 2 - littleEndian
ret = [ret(first:2:end,:),ret(second:2:end,:)]
end
end
(系统自动生成,下载前可以参看下载内容)
下载文件列表
conversion_gui/
conversion_gui/conversion_gui.fig
conversion_gui/conversion_gui.m
conversion_gui/conversion_gui.fig
conversion_gui/conversion_gui.m
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.