专栏
标签
代码无法生成动态库
一般问题
发布于 2025-01-17 13:50:20
查看 23过去527天

julia代码:
using TyPlot
using TySignalProcessing
function DSB(f_s,f_c)
t = [0:1/f_s:1-1/f_s;]
s = cos.(2pi150*t)
rx, = modulate(s,f_c,f_s,"fm",0.1)
y= demod(rx,f_c,f_s,"fm",0.1)
plot(s)
hold("on")
plot(y)
grid("on")
end

@static if @isdefined(SyslabCC)
SyslabCC.static_compile("DSB", DSB, (Int64,Int64,))
end

执行命令:scc main.jl -o main\dsbtest.dll --bundle --mode shared

报错信息:Compiler Error(6): dynamic call(SyslabCCPatches.convert, SyslabCCPatches.String, arg2(s)::Any): invoke(typeof(convert),Type{String},Any) failed
in the body of Type{ArgumentError}
File D:\tools\MWorks\Syslab 2024a\Tools\SyslabCC\juliapkgs\SyslabCCPatches\src\basics.jl, line 25, in SyslabCCPatches.PatchHandler

in the body of typeof(Base.steprangelen_hp)
File range.jl, line 493, in Base.StepRangeLen
File range.jl, line 498, in Base.StepRangeLen
File twiceprecision.jl, line 377, in Base.StepRangeLen
File twiceprecision.jl, line 346, in Base.steprangelen_hp

in the body of typeof(Base.floatrange)
File twiceprecision.jl, line 392, in Base.floatrange

in the body of Colon
File twiceprecision.jl, line 416, in Base.Colon

in the body of typeof(DSB)
File range.jl, line 10, in Base.Colon
File D:\tools\MWorks\Syslab 2024a\MyProject\julia\main.jl, line 4, in Main.DSB

疑问:请问这个报错信息是什么?生成代码有没有具体的文档?syslab里的scc命令有许多已经无法使用了

所属专栏:Syslab基础平台
产品信息:Syslab科学计算环境
通信科学计算
采纳的回答
发布于 2025-01-20 13:42:50

您好,信号处理工具箱中的demod函数和图形工具箱暂不支持代码生成,请您尝试其他方式哈。

全部回答 2

发布于 2025-01-20 08:36:45

TyPlot重度依赖外部二进制,Syslab CC暂时无法支持TyPlot

发布于 2025-01-20 13:42:50

您好,信号处理工具箱中的demod函数和图形工具箱暂不支持代码生成,请您尝试其他方式哈。

用户
和原帖交流更多问题细节吧,去
我要发帖 我要发帖
资料中心 资料中心
查看更多>
热门帖子 热门帖子
主要贡献者 主要贡献者
过去7天