Home

Moxa Proactive Monitoring Windows Software User`s Manual

image

Contents

1. 0 Get CPU Average Usage cpuCoreIndex O GetCpuStatus cpuCoreIndex amp cpuUsage printf Average CPU Usage d n cpuUsage return 0 2 3 Proactive Monitoring Windows Manual API GetCpuUsage int GetCpuUsage int index double value Parameters index CPU Index Start from 1 value The CPU usage of a specific CPU core Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetCpuUsage function is used to obtain CPU utilization of each core by index To get the total CPU core count call the GetCpuCount function Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv int cpuLogicCount 0 int cpuCoreIndex O double cpuUsage 0 Get CPU Usage of each core for cpuCoreIndex 1 cpuCoreIndex lt cpuLogicCount cpuCorelndex GetCpuStatus cpuCoreIndex amp cpuUsage printf CPU Usage of core d d n cpuCoreIndex cpuUsage return 0 2 4 Proactive Monitoring Windows Manual API GetCpuCount int GetCpuCount int value Parameters value The total CPU core count Return Value ret 0 Success Return value ret is zero on success a negative error code on failure Description The GetCpuCount function is used to obtain th
2. Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv double memoryTotalSize 0 double memoryAvailableSize 0 Get total memory size GetMemTotalSize ememoryTotalSize printf memoryTotalSize 164d n memoryTotalSize 1024 1024 return 0 GetMemAvailSize int GetMemAvailSize double value Parameters value Available memory size in megabytes Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetMemAvailSize function is used to obtain the available physical memory in the system Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv double memoryAvailableSize 0 Get available memory size GetMemAvailSize amp memoryAvailableSize printf memoryAvailableSize 164d n memoryAvailableSize 1024 1024 return 0 2 6 Proactive Monitoring Windows Manual API UART Information GetUartCount int GetUartCount int value Parameters value Available COM ports Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 The system cannot get device name Description The GetUartCount function is used to obtain the available COM ports in t
3. CPU Temperature J CPU Voltage 1 6 Proactive Monitoring Windows Manual Installation and Usage 5 The CPU status shown on the dashboard will be updated based on your selection 4 Moxa Proactive Monitoring DA 681A ns i lt CPU Logic Count 2 CPU Total Usage 3 CPU Temperature 47 C CPU Voltage 0 62V Drive CA OMB free 6GB total 97 7 Memory Items Memory Usage 41 Total Memory Size 1 91GB Available Memory Size 1 12GB Memory Voltage NIA Setting System Alerts Take the following steps to set system alerts 1 Click Settings Mainboard Items 50 C Mainboard Temperature El Mainboard Voltage 5 024V Moxa Proactive Monitoring DA 681A CPU Items CPU Logic Count 2 CPU Total Usage 4 CPU Temperature 46 C CPU Voltage 0 62V Memory Items 40 Memory Usage Total Memory Size 1 91GB Available Memory Size 1 14GB Memory Voltage N A Disk Items Drive CA OMB free 6GB total 97 Mainboard Items 50 C Y Mainboard Temperature Mainboard Voltage 5 024V Proactive Monitoring Windows Manual Installation and Usage 2 Click the mouse button to change to the alert setting pages you can configure the alert settings here to monitor system status and send alarms to relay output when the system status is over the threshold value of the alert settings NOTE Only some Moxa computers are equipped with a relay ou
4. 2 3 GPU to MAA caes 2 3 Memory Information sis aldeia dada ana AS A A GAS ag See Ata 2 5 VART Informatio TA TA load DS dio ES I DS I AAA 2 7 Ethernet Information a aa aa aa aa Een AREEN EREE EnEn 2 9 DIST MON UA aia ban MOS SR GUAS 2 13 BIOS A MTORMALIOMN simi aut acudan batuta iaded sda dad etat E ata 2 15 1 Installation and Usage The following topics are covered in this chapter Installing Moxa Proactive Monitoring Monitoring System Status Customizing Your Own Monitoring Items Setting System Alerts Clearing Alert Output 00900000 Changing the Device Configuration Proactive Monitoring Windows Manual Installation and Usage Installing Moxa Proactive Monitoring In this section we describe how to install the Moxa Proactive Monitoring software 1 Run the exe file provided in the setup package B Moxa_Proactive_Monitoring_x86_V1 2 2 Click Next Welcome to the InstallShield Wizard for Moxa Proactive Monitoring The InstallShield R Wizard will install Moxa Proactive Monitoring on your computer To continue click Next WARNING This program is protected by copyright law and international treaties 3 Click Install 1 Ready to Install the Program The wizard is ready to begin installation If you want to review or change any of your installation settings click Back Click Cancel to exit the wizard Current Settings C Program Files Moxa Proactive Monitoring User Informati
5. Area Connection 5 LAN6 Local Area Connection 6 Mainboard Temperature Mainboard Power Indicator Alarm trigger V Enable Alarm Y When the usage exceeds the threshold of When the usage falls the threshold of Alarm Action E Set alert output E Enable Log Clear alert outp Edit Custom Program 2 Edit the program file name and arguments in the Alert Start section and Alert Stop section NOTE startAlertoutput exe is just an example you may your own exe file name here Alert start Fi leName StartAlertoutput exe Argumentsz i 5 Alert stop Fi leName StopAlertoutput exe Li 5 Arguments 7 Proactive Monitoring Windows Manual Installation and Usage 3 Click Apply to save the settings CPU Usage CPU Temperature Memory Usage Partition Usage Drive C LAN1 Local Area Connection LAN2 Local Area Connection 2 LAN3 Local Area Connection 3 LANA Local Area Connection 4 LANS Local Area Connection 5 LAN6 Local Area Connection 6 Mainboard Temperature Mainboard Power Indicator Alarm trigger V Enable Alarm When the usage exceeds the threshold of When the usage falls the threshold of Alarm Action Set alert output Enable Log Clear alert output it Custom Program 1 13 API The Moxa Proactive Monitoring API provides a set of C functions for communicating
6. relayOutput return 0 2 17 Proactive Monitoring Windows Manual API GetMilliVolt int GetMilliVolt int index unsigned int value Parameters index Voltage type 0 CPU 1 DRAM 2 5V value Voltage value Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetMilliVolt function is used to obtain the sensor voltage in the system Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv double mainboardVoltage 0 Get mainboard voltage GetMilliVolt 3 amp mainboardVoltage printf Mainboard voltage d mV n mainboardVoltage return 0 NOTE Some MOXA boards may not support all voltage type Please refer to the board s manual for information I 2 18 Proactive Monitoring Windows Manual API GetTemperature int GetTemperature int index unsigned int value Parameters index Temperature type O cpu 1 system value Temperature value Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description Example The GetTemperature function is used to obtain the sensor temperature in the system include stdafx h include lt windows h gt include Mx
7. M2 is In Use n else printf TCOM2 is available n return 0 2 8 Proactive Monitoring Windows Manual API Ethernet I nformation GetEthCount int GetEthCount int value Parameters value Total number of available network adapters Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetEthCount function is used to obtain the total number of network adapters Example include stdafx h include lt windows h gt include lt math h gt include MxProMonApi h int _tmain int argc _TCHAR argv int connectionStatus 0 int linkSpeed 0 double utilization 0 int networkAdapterCount 0 Get number of network adapter GetEthCount amp networkAdapterCount printf Network adapter count d n networkAdapterCount return 0 2 9 Proactive Monitoring Windows Manual API GetEthSpeed int GetEthSpeed int index int value Parameters index Network adapter index starts from 1 value Current link speed Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetEthSpeed function is used to obtain the link speed of a specific network adapter Example include stdafx h include lt wind
8. Moxa Proactive Monitoring Windows Software User s Manual Edition 1 0 November 2015 www moxa com pr t MOXA 2015 Moxa Inc All rights reserved Moxa Proactive Monitoring Windows Software User s Manual The software described in this manual is furnished under a license agreement and may be used only in accordance with the terms of that agreement Copyright Notice Trademarks 2015 Moxa Inc All rights reserved The MOXA logo is a registered trademark of Moxa Inc All other trademarks or registered marks in this manual belong to their respective manufacturers Disclaimer Information in this document is subject to change without notice and does not represent a commitment on the part of Moxa Moxa provides this document as is without warranty of any kind either expressed or implied including but not limited to its particular purpose Moxa reserves the right to make improvements and or changes to this manual or to the products and or the programs described in this manual at any time Information provided in this manual is intended to be accurate and reliable However Moxa assumes no responsibility for its use or for any infringements on the rights of third parties that may result from its use This product might include unintentional technical or typographical errors Changes are periodically made to the information herein to correct such errors and these changes are incorporated into new editions of th
9. ProMonApi h int _tmain int argc _TCHAR argv double mainboardTemperature 0 Get mainboard temperature GetTemperature 2 amp mainboardTemperature printf Mainboard Temperature d cC n mainboardTemperature 248 return 0 2 19
10. age 4 If you want to set the relay output when the alert occurs select the Set alert output option and then click Apply CPU Usage CPU Temperature Memory Usage Partition Usage Drive CA LAN1 Local Area Connection LAN2 Local Area Connection 2 LAN3 Local Area Connection 3 LAN4 Local Area Connection 4 LANS Local Area Connection 5 LAN6 Local Area Connection 6 Mainboard Temperature Mainboard Power Indicator Alarm trigger M Enable Alarm di When the usage exceeds the threshold of l When the usage falls the threshold of di Enable Log 1 9 Proactive Monitoring Windows Manual Installation and Usage Clearing Alert Output 1 When the alert occurs the relay output signal will be kept until it is cleared There are two ways to clear the alert output a Click the Clear alert output button CPU Usage CPU Temperature Memory Usage Alert Items Alarm trigger Partition Usage Drive C LAN1 Local Area Connection LAN2 Local Area Connection 2 LAN3 Local Area Connection 3 LANA Local Area Connection 4 LANS Local Area Connection 5 LAN6 Local Area Connection 6 Mainboard Temperature Mainboard Power Indicator Y Enable Alarm Y When the usage exceeds the threshold of l When the usage falls the threshold of Alarm Action I s b Double click the alert item on the dash
11. board DA 681A CPU Items CPU Logic Count 2 CPU Total Usage 5 CPU Voltage 064V 1 Memory Usage 41 I Total Memory Size 1 91GB Available Memory Size 1 11GB i Memory Voltage N A 2 SS CPU Memory Disk Memory Items Wwanooas MO Serai Nemo Disk Items Drive CA OMB free 6GB total 97 Mainboard Items Mainboard Temperature 50 C y Mainboard Voltage 5 024V I 1 10 Proactive Monitoring Windows Manual Installation and Usage And then select Yes to clear the relay output Moxa Proactive Monitoring Ce ies E N a a PASA cra Menos os TS TS Network CPU Items CPU Logic Count 2 Drive CA OMB free 6GB total 97 i CPU Total Usage 5 CPU Temperature CPU Voltage Memory Items Mainboard Items Memory Usage Mainboard Temperature 50 C Total Memory Size Mainboard Voltage 5 024V 4 Available Memory Size 1 10GB Memory Voltage N A 1 11 Proactive Monitoring Windows Manual Installation and Usage Changing the Device Configuration The alert output can be assigned to your programs when the alert is enabled or disabled Take the following steps to assign the alert output 1 Click the Edit Custom Program button CPU Usage CPU Temperature Memory Usage Partition Usage Drive C LAN1 Local Area Connection LAN2 Local Area Connection 2 LAN3 Local Area Connection 3 LANA Local Area Connection 4 LANS Local
12. e number of CPU cores Example stdafx h include lt windows h gt MxProMonApi h include include int _tmain int argc _TCHAR argv int cpuLogicCount 0 int cpuCoreIndex O Get CPU Logic Count GetCpuCount amp cpuLogicCount printf TCPU Logic Count din return 0 cpuLogicCount Memory Information GetMemUsage int GetMemUsage int value Parameters value Memory usage in percentage Return Value ret 0 Success ret 101 Unable to open shared memory Return value ret is zero on success a negative error code on failure Description The GetMemUsage function is used to obtain the memory usage as a percentage Example stdafx h include lt windows h gt MxProMonApi h include include int _tmain int argc _TCHAR argv double memoryUsage 0 Get memory usage GetMemUsag amp memoryUsage printf memoryUsage d n return 0 memoryUsage Proactive Monitoring Windows Manual API GetMemTotalSize int GetMemTotalSize double value Parameters value Total memory size in megabytes Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetMemTotalSize function is used to obtain the total amount of physical memory in the system
13. e publication Technical Support Contact I nformation Moxa Americas Toll free 1 888 669 2872 Tel 1 714 528 6777 Fax 1 714 528 6778 Moxa Europe Tel 49 89 3 70 03 99 0 Fax 49 89 3 70 03 99 99 Moxa India Tel 91 80 4172 9088 Fax 91 80 4132 1045 www moxa com su ort Moxa China Shanghai office Toll free 800 820 5036 Tel 86 21 5258 9955 Fax 86 21 5258 5505 Moxa Asia Pacific Tel 886 2 8919 1230 Fax 886 2 8919 1231 Table of Contents Installation and USAGE ocoonocnononannocncnnrncnnrnnnnrnnnnrnnnn enn rana nn rana enn TA AA TA TA Te 1 1 Installing Moxa Proactive Monitoring ooccoocccccnccnnnccnnnccnnnncnnncrnnnr aah aAa aaa a aaa a a ala rn anna al AA Aa lala 1 2 Monitoring System Status SE O 1 3 Customizing Your Own Monitoring Ite MS c cece eet n teeta e ee eaten 1 5 Seto AENA A Wala nae Grae alan a ava era we are A 1 7 Clearing Alert Dutti dataci n 1 10 Changing the Device Configuration sisian cnn nr nr nn rr aa aa aa n aa aaa e aaa a a a aA AA AAA 1 12 AP TN 2 1 APIO VE Watios aio 2 2 API Function SUMMA Y at EN A ECA CU a ule PORN DATA TA CN CRA CA CA BOWE balk COME CTR CE a 2 2 COMINO ON A gen See ATA 2 2 Memory Intormation Sosa as de ata bata i 2 2 UART In TORIA CIO cada tocar a aa cc dc cc cd da 2 2 NT ORO 2 2 DISICEAFO MAA ii a 2 2 BIOS Information A A AA AO NAO E DS gine oy 2 3 O 2 3 API Details vetas catarata O de id tan a GA St Sea ide taa Ser a da Sa Ara cagada
14. etDiskAvailSize int GetDiskAvailSize char diskpath double value Parameters diskpath Drive letter e g C value Available disk size in megabytes Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetDiskAvailSize function is used to obtain the available disk size in megabytes Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv int diskIndex 0 double diskAvailableSize 0 Get disk available size GetDiskAvailSize diskIndex amp diskAvailableSize printf Disk Avaliable Size d MB n diskAvailableSize return 0 2 14 Proactive Monitoring Windows Manual API BIOS Information GetDeviceName int GetDeviceName unsigned char value Parameters value Model name e g DA 681A Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetDeviceName function is used to obtain model name on target device Example tinclude stdafx h tinclude lt windows h gt tinclude MxProMonApi h int _tmain int argc _TCHAR argv unsigned char deviceName MAX_PATH Get Device Name GetDevName deviceName printf Device Name s n deviceName return 0 GetBiosVe
15. he system Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv int uartStatus 0 int uartCount 0 Get serial port count GetUartCount amp uartCount printf Uart count d n uartCount return 0 2 7 Proactive Monitoring Windows Manual API GetUartStatus int GetUartStatus int index int value Parameters index COM port index starts from 1 value The buffer to hold the return message Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetUartStatus function is used to obtain the status of a specific COM port by index value 1 The UART port is currently in use value 0 The UART port is available Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv int uartStatus 0 int uartIndex 1 int uartCount 0 Get serial port count GetUartCount amp uartCount printf Uart count d n uartCount Get serial port status uartIndex 1 COM1 GetUartStatus uartIndex suartStatus if uartStatus 1 printf TCOM1 is In Use n else printf TCOM1 is available n uartIndex 2 COM2 GetUartStatus uartIndex amp uartStatus if uartStatus 1 printf TCO
16. ic ethernet port link GetEthUsage Display specific ethernet port speed GetEthCount Display the total ethernet port number Disk Information GetDiskUsage Display specific disk utilization of the system GetDiskTotalSize Display the specific total amount of disk size in the system GetDiskAvailSize Display the specific amount of available disk size 2 2 Proactive Monitoring Windows Manual API BIOS Information GetDeviceName Display the device name on main board GetBiosVer Display the bios version GetSerNum Display the bios serial number GetMilliVolt Display the sensor voltage in the system GetTemperature Display the sensor temperature in the system I O Ports GetPwrStatus Display the power supply status SetRelay Set relay status API Details CPU Information GetAverageCpuUsage Parameters value int GetAverageCpuUsage double value The average CPU usage Return Value Return value ret is zero on success a negative error code on failure ret 0 ret 101 Success Unable to open shared memory Description The GetAverageCpuUsage function is used to obtain the average CPU utilization of the system Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv int cpuLogicCount 0 int cpuCoreIndex O double cpuUsage
17. inboard Temperature 38 C Mainboard Voltage 496V t 3 The dashboard displays four kinds of system status at the same time To display other system status items click the previous button on the left or the next button on the right to change which items are displayed amp Moxa Proactive Monitoring Senal Items COM1 Available COM2 Available COM3 lt COM4 Local Area Connection Available Available Available Disconnected Local Area Connection 2 Disconnected Local Area Connection 3 Disconnected Disconnected Local Area Connection 4 Local Area Connection 5 Disconnected cle sss Settings Monitor Ite Monitor Item 1 4 Proactive Monitoring Windows Manual Installation and Usage Customizing Your Own Monitoring I tems 1 You can select your own system status to display on the dashboard by turning on or off the monitor status For example if you don t want to monitor the CPU and memory status you can turn off these features by clicking the buttons under the CPU and Memory figures The dashboard will be updated based on the selection amp Moxa Proactive Monitoring DA 681A cr Memory Items Memory Usage Available Memory Size 1 06GB Memory Voltage N A Total Memory Size 1 91GB Mainboard Items Mainboard Temperature 50 C y Mainboard Voltage 5 024V t COM1 Available COM2 Available 3 Available COM4 Avai
18. lable COM5 Available Local Area Connection Local Area Connection 2 Local Area Connection 3 Local Area Connection 4 Local Area Connection 5 Disconnected Disconnected Disconnected Disconnected Disconnected 2 Furthermore you can customize which items are displayed For example if you don t want to show the CPU usage of each core you can turn off that item by clicking the Settings button Moxa Proactive Monitoring DA 681A CPU Items CPU Logic Count 2 CPU Total Usage 4 CPU Temperature 46 C CPU Voltage 0 62V Memory Items Memory Usage Total Memory Size 1 91GB Available Memory Size 1 14GB Memory Voltage N A Disk Items Drive CA OMB free 6GB total 97 Y Mainboard Items Mainboard Temperature Mainboard Voltage 1 5 50 C 5 024V y Proactive Monitoring Windows Manual Installation and Usage 3 When the settings page opens select the second icon to change to the member item selection page Firmware Version BIOS Version V1 00501 OS Version Microsoft Windows NT 6 1 7601 Service Pack 1 System Information CPU Intel R Celeron R CPU 1047UE E 1 40GHz Installed Memory 1 91GB 4 Select CPU Status in the top section of the window and then deselect CPU Usage Each Process in the bottom section of the window Disk Status Mainboard Status SerialPort Status Network Status di CPU Usage Percentage ic Count
19. letter e g C value Disk usage in percentage Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetDiskUsage function is used to obtain the disk usage in percentage Example GetDiskStatus cpp Defines the entry point for the console application include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv int diskIndex 0 double diskUsage 0 Get disk usage GetDiskUsage diskIndex amp diskUsage printf Disk Usage 3d n diskUsage return 0 2 13 Proactive Monitoring Windows Manual API GetDiskTotalSize int GetDiskTotalSize char diskpath double value Parameters diskpath Drive letter e g C value Disk total size in megabytes Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetDiskTotalSize function is used to obtain the total disk size in megabytes Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv int diskIndex 0 double diskTotalSize 0 Get disk total size GetDiskTotalSize diskIndex amp diskTotalSize j printf Disk Total Size d MB n diskTotalSize return 0 G
20. on Name moxa Company 1 2 Proactive Monitoring Windows Manual Installation and Usage 4 Click Finish InstallShield Wizard Completed The InstallShield Wizard has successfully installed Moxa Proactive Monitoring Click Finish to exit the wizard Monitoring System Status Take the following steps to monitor system status 1 Execute Moxa Proactive Monitoring from All Programs gt Moxa gt Moxa Proactive Monitoring Default Programs Desktop Gadget Gallery Internet Explorer pm 3 Windows Fax and Scan as Windows Media Player El Windows Update lt A XPS Viewer Accessories Maintenance Music Moxa Documents Pictures B I Proactive Computer oCam Startup Subsystem for UNIX based Applications Devices and Printers Control Panel Default Programs Help and Support 4 Back Search programs and files P Shut down I J 1 3 Proactive Monitoring Windows Manual Installation and Usage 2 The system status can be determined by viewing the dashboard Fr Moxa Proactive Monitoring x ae na CPU Memory E E l CPU Items CPU Logic Count 2 CPU Total Usage CPU Core1 Usage CPU Core2 Usage CPU Temperature Memory Items Memory Usage Total Memory Size 1 90GB Available Memory Size 1 21GB Memory Voltage N A Disk Items Drive CA 8GB free 14GB total 40 Drive DA 392MB free 7GB total 94 Y Mainboard Items Ma
21. ows h gt include lt math h gt include MxProMonApi h int _tmain int argc _TCHAR argv int connectionStatus 0 int linkSpeed 0 double utilization 0 int networkAdapterCount 0 Get number of network adapter GetEthCount amp networkAdapterCount printf Network adapter count d n networkAdapterCount Get network link speed GetEthSpeed 1 amp linkSpeed printf Link speed d Mbps n linkSpeed printf Network utilization d n utilization return 0 2 10 Proactive Monitoring Windows Manual API GetEthLink int GetEthLink int index int value Parameters index Network adapter index starts from 1 value Connection status of the network adapter Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetEthLink function is used to obtain the link status of a specific network adapter Example include stdafx h include lt windows h gt include lt math h gt include MxProMonApi h int _tmain int argc _TCHAR argv int connectionStatus 0 int linkSpeed 0 double utilization 0 int networkAdapterCount 0 Get number of network adapter GetEthCount amp networkAdapterCount printf Network adapter count d n networkAdapterCount Get network connection
22. r int GetBiosVer unsigned char value Parameters value BIOS version string Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetBiosVer function is used to obtain BIOS version string Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv unsigned char biosBersion MAX_PATH Get BIOS Version GetBiosVer biosBersion i printf BIOS Version s n biosBersion return 0 2 15 Proactive Monitoring Windows Manual API GetSerNum int GetSerNum unsigned char value Parameters value Serial number string Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetSerNum function is used to obtain the serial number string Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv unsigned char serialNumber MAX_PATH Get Serial Number GetSerNum serialNumber printf Serial Number s n serialNumber return 0 GetPwrStatus int GetPwrStatus int port int value Parameters port Power module index Start from 1 value Power module status Return Value Return value
23. ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description The GetPwrStatus function is used to obtain the power module status in the system Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv double mainboardPowerStatus 0 Get mainboard power status GetPwrStatus 1 amp mainboardPowerStatus printf Mainboard Power Status d n mainboardPowerStatus return 0 NOTE Some MOXA boards may not support power supply indicator Please refer to the board s manual for information 2 16 Proactive Monitoring Windows Manual API SetRelay int SetRelay int port int value Parameters Return Value port Relay index Start from 1 reserved value 1 on O off Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description This function can also be used to setting relay status if you relay set 1 relay is on on the other hand set 0 relay is off Note Only support on DA 820 and DA 681A Example include stdafx h include lt windows h gt include MxProMonApi h int _tmain int argc _TCHAR argv int powerModulelndex 1 int relayOutput 1 Set local relay output SetRelay powerModuleIndex amp
24. status GetEthLink 1 amp connectionStatus printf Connection Status d n connectionStatus return 0 2 11 Proactive Monitoring Windows Manual API GetEthUsage int GetEthUsage int index int value Parameters index Network adapter index Start from 1 value The network utilization of specific network adapter Return Value Return value ret is zero on success a negative error code on failure ret 0 Success ret 101 Unable to open shared memory Description Example The GetEthUsage function is used to obtain the network utilization of specific network adapter GetNetworkStatus cpp Defines the entry point for the console application include stdafx h include lt windows h gt include lt math h gt include MxProMonApi h int _tmain int argc _TCHAR argv int connectionStatus 0 int linkSpeed 0 double utilization 0 int networkAdapterCount 0 Get number of network adapter GetEthCount amp networkAdapterCount printf Network adapter count d n networkAdapterCount Get network utilization GetEthUsage 1 amp utilization printf Network utilization d n utilization return 0 2 12 Proactive Monitoring Windows Manual API Disk Information GetDiskUsage int GetDiskUsage char diskpath double value Parameters diskpath Drive
25. tput CPU Usage CPU Temperature Memory Usage Partition Usage Drive C LAN1 Local Area Connection LAN2 Local Area Connection 2 LAN3 Local Area Connection 3 LANA Local Area Connection 4 LANS Local Area Connection 5 LAN6 Local Area Connection 6 Mainboard Temperature Mainboard Power Indicator Alarm trigger V Enable Alarm di When the usage exceeds the threshold of When the usage falls the threshold of Alarm Action Set alert output dl Enable Log Clear alert output Edit Custom Program 3 For example suppose alert settings for CPU usage is enabled and the threshold value of CPU usage is 80 In this case when CPU usage is over 80 the icon on the dashboard will change to red and the alert will be logged in the log file Alert Items CPU Usagi PU E perature Memory Usage Partition Usage Drive C LAN1 Local Area Connection LAN2 Local Area Connection 2 LAN3 Local Area Connection 3 LANA Local Area Connection 4 LANS Local Area Connection 5 LAN6 Local Area Connection 6 Mainboard Temperature Mainboard Power Indicator Alarm trigger Enable Alarm When the usage exceeds the threshold of When the usage falls the threshold of Alarm Action Set alert output W Enable Log Clear alert output Edit Custom Program 1 8 Proactive Monitoring Windows Manual Installation and Us
26. with hardware devices The following topics are covered in this chapter O API Overview O API Function Summary gt CPU Information Memory Information UART Information Ethernet Information Disk Information BIOS Information 1 0 Ports O API Details VV VV WV CPU Information Memory Information UART Information Ethernet Information Disk Information VV VV V WV BIOS Information Proactive Monitoring Windows Manual API API Overview The API provides support for the following tasks e Obtaining BIOS information e Obtaining CPU information e Obtaining the amount of free and used system memory e Obtaining disk information e Obtaining Ethernet information e Set or get 10 port status API Function Summary CPU Information GetAverageCpuUsage Display average CPU utilization of the system GetCpuUsage Display per core CPU utilization of the system GetCpuCount Display the number of CPU units available Memory Information GetMemUsage Display the total amount of used disk in the system GetMemTotalSize Display the total amount of disk in the system GetMemAvailSize Show the total amount of available physical memory in the system UART Information GetUartCount Display the number of UART units available GetUartStatus Display the UART port status Ethernet Information GetEthSpeed Display specific ethernet port speed GetEthLink Display specif

Download Pdf Manuals

image

Related Search

Related Contents

Surpresseur/réservoir d`air  DECT—Freisprech—Box mit Bluetooth  Manuale in linea dell`utente per Mac OS, dalla versione  Manual de instrucciones  PDF Version  Metro 100 XT-2 Metro 100 XT-3  HAC4 - DE - Fahrrad Kaiser  TPE-224WS Quick Installation Guide  PCI E Series Register-Level Programmer Manual  Printed in China Booktop M1022 User`s Manual Original  

Copyright © All rights reserved.
Failed to retrieve file