从RTC获取日期和时间(主板的读时间时钟) [英] Getting Date and Time From RTC(Read Time Clock of Motherboard)

查看:1420
本文介绍了从RTC获取日期和时间(主板的读时间时钟)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嘿大家



我的第一个问题是,c#lang能否与主板组件通信。像RTC(读取时间时钟)模块一样,如果是,那么告诉我如何从RTC模块获取日期和时间,以便在系统时间改变时,我的应用程序以正确的时间运行。







如果有人知道这个请尽快帮助



谢谢

Vishal Jodh

Hey everyone

My first question is that, can c# lang communicate with motherboard component. Like RTC(Read Time Clock) Module, if yes Then tell me How can i getting the Date and Time from RTC Module so that if System time is change my application running with correct time.



If any one know about this pls help as soon as possible

Thanks
Vishal Jodh

推荐答案

我不确定你能否在Win7及以上等现代操作系统中使用它们尽可能地将您与硬件隔离开来并禁止普通特权应用程序以任何方式触摸它。



但是你无论如何都不需要 - 只需使用.NET组件:DateTime.Now现在告诉你时间 - 如果系统时间改变,它返回的值也会改变,因为它每次调用时都会读取系统时间。
I''m not sure you can in modern OS''s such as Win7 and above - they do tend to isolate you from the hardware as much as possible and forbid "Normal" privilege applications from touching it in any way.

But you don''t need to anyway - just use the .NET components: DateTime.Now tells you the time right now - if the system time changes, so will the value it returns, because it reads the system time each time you call it.


这篇关于从RTC获取日期和时间(主板的读时间时钟)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆