通过 Java Applet 安装驱动程序

发布于 2024-08-12 14:56:09 字数 217 浏览 3 评论 0原文

只是想知道是否有人有通过 Java Applet 安装硬件驱动程序的经验。我目前正在编写一个小程序,它将访问一些硬件并将嵌入到网页中。为了让最终用户更容易,我想让它检测是否安装了驱动程序,如果没有安装它们。

这将是一个签名的小程序,因此它应该能够访问文件和系统信息。据我了解,驱动程序只是放置在正确位置的几个系统文件以及一些注册表设置。

这可行吗?我在网上找不到任何有关执行此操作的信息。

Just wondering if anyone has had any experience with installing hardware drivers via a Java Applet. I'm currently writing an applet that will be accessing some hardware and will be embedded into a web page. In order to make things easier for end users I would like to have it detect if the drivers are installed and if not install them.

This will be a signed applet, so it should be able to access files and system information. From what I understand, drivers are just a few system files being placed in the right spot with a few registry settings as well.

Is this doable? I can't find any info online about doing this.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

北风几吹夏 2024-08-19 14:56:09

在 Windows 上,我想您可以使用此处描述的方法访问注册表(运行reg 命令)。

另一种方法是 JNI 注册表接口

但我不确定这是否是最简单的方法。您可能只是尝试加载相关的驱动程序类,如果失败,请下载普通的 Windows 安装程序 .msi 或 .exe 来执行实际的驱动程序安装。如果绝对有必要对用户隐藏安装程序,您通常可以将安装程序配置为“静默”运行,无需用户交互。但这可能不是重点,因为新的硬件驱动程序可能需要重新启动 Windows。

您可能会遇到的另一个问题是大多数驱动程序需要管理员访问权限才能安装它们。

On windows I guess you could access the registry using the method described here (running the reg command).

Another approach is this JNI registry interface.

I'm not sure either is the easiest approach however. You could probably just try to load the relevant driver classes, and if that fails download a normal windows installer .msi or .exe to do the actual driver installation. You can usually configure the installer to run 'silently' without user interaction, if absolutely necessary to hide it from the user. That may be beside the point however, since it's likely that a new hardware driver will need to reboot Windows.

Another problem you will probably encounter is the most drivers will need administrator access to install them.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文