Giter VIP home page Giter VIP logo

Comments (1)

GoogleCodeExporter avatar GoogleCodeExporter commented on August 17, 2024
Problem solved - needed to add subhardware.Update() line to get it to work - 
code I used below if useful to anyone else

For i As Integer = 0 To cp.Hardware.Count() - 1
            Dim hardware = cp.Hardware(i)
            hardware.Update()

            Select Case hardware.HardwareType
                Case HardwareType.Mainboard
                    TextBox3.AppendText("Motherboard: " & hardware.Name & vbCrLf & vbCrLf)
                    For k = 0 To hardware.SubHardware.Count - 1
                        Dim subhardware = hardware.SubHardware(k)
                        subhardware.Update()
                        TextBox3.AppendText(subhardware.Name & vbCrLf & vbCrLf)
                        For j = 0 To subhardware.Sensors.Count - 1
                            Dim sensor = subhardware.Sensors(j)
                            Select (sensor.SensorType)
                                Case 0
                                    TextBox3.AppendText("Voltage: " & sensor.Name & " - " & sensor.Value & vbCrLf)
                                Case 1
                                    TextBox3.AppendText("Clock: " & sensor.Name & " - " & sensor.Value & vbCrLf)
                                Case 2
                                    TextBox3.AppendText("Temperature: " & sensor.Name & " - " & sensor.Value & vbCrLf)
                                Case 3
                                    TextBox3.AppendText("Load: " & sensor.Name & " - " & sensor.Value & vbCrLf)
                                Case 4
                                    TextBox3.AppendText("Fan Speed: " & sensor.Name & " - " & sensor.Value & vbCrLf)
                                Case 5
                                    TextBox3.AppendText("Flow: " & sensor.Name & " - " & sensor.Value & vbCrLf)
                                Case 6
                                    TextBox3.AppendText("Fan Control: " & sensor.Name & " - " & sensor.Value & vbCrLf)
                                Case 7
                                    TextBox3.AppendText("Level: " & sensor.Name & " - " & sensor.Value & vbCrLf)
                                Case 8
                                    TextBox3.AppendText("Factor: " & sensor.Name & " - " & sensor.Value & vbCrLf)
                                Case 9
                                    TextBox3.AppendText("Power: " & sensor.Name & " - " & sensor.Value & vbCrLf)
                                Case 10
                                    TextBox3.AppendText("Data: " & sensor.Name & " - " & sensor.Value & vbCrLf)
                                Case Else
                                    TextBox3.AppendText(sensor.SensorType & " - " & sensor.Name & " - " & sensor.Value & vbCrLf)
                            End Select
                        Next
                        TextBox3.AppendText(vbCrLf)
                    Next

End Select

Original comment by [email protected] on 9 Apr 2015 at 10:49

from open-hardware-monitor.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.