Check to see if the status flag for input power is set to "Valid", and if so, then see if the time stamp has been update since the last update.
检查电力输入的状态标志是否设置为“ Valid ”,如果是的话,检查自从上一次更新以来时间戳是否更新过。
Because volatile simplifies the coding, and the status flag does not depend on any other state in the program, this is a good use for volatile.
由于volatile简化了编码,并且状态标志并不依赖于程序内任何其他状态,因此此处非常适合使用volatile。
Otherwise, it returns the appropriate error status flag.
否则,就返回适当的错误状态标志。
应用推荐