Getting error: CoreTemp_Not_Found why ?

User feature requests
Planned features for Core Temp
Post Reply
Chocolade
New User
Posts: 1
Joined: Tue Dec 27, 2011 10:14 am

Getting error: CoreTemp_Not_Found why ?

Post by Chocolade »

Im using c#(csharp) and i did this code:

Code: Select all

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.IO;
using System.Reflection;
using System.Windows.Forms;
using OpenHardwareMonitor.Hardware;
using OpenHardwareMonitor.Collections;
using OpenHardwareMonitor;
using GetCoreTempInfoNET;

namespace WindowsFormsApplication1
{
    public partial class Form1 : Form
    {
         System.Timers.Timer RefreshInfo;
         CoreTempInfo CTInfo;

        public Form1()
        {
            InitializeComponent();
            CTInfo = new CoreTempInfo();
            //Sign up for an event reporting errors
            CTInfo.ReportError += new ErrorOccured(CTInfo_ReportError);

            //Initiate a Timer.
            RefreshInfo = new System.Timers.Timer();
            RefreshInfo.Interval = 1000;
            RefreshInfo.Elapsed += new System.Timers.ElapsedEventHandler(RefreshInfo_Elapsed);

            //Get info manually.
            RefreshInfo_Elapsed(null, null);

            //Start Timer counter.
            RefreshInfo.Start();

            //Press return to exit.
            Console.ReadLine();

            //Kill the timer/
            RefreshInfo.Stop();
            RefreshInfo.Dispose();

        }
        private void Form1_Load(object sender, EventArgs e)
        {
        }
        private void label1_Click(object sender, EventArgs e)
        {
        }

        private void RefreshInfo_Elapsed(object sender, System.Timers.ElapsedEventArgs e)
        {
            //Clear the screen and post the title.
            //Console.Clear();
            //Console.WriteLine("Core Temp shared memory reader:\n");
            label1.Text = "Core Temp shared memory reader:\n";

            //Attempt to read shared memory.
            bool bReadSuccess = CTInfo.GetData();

            //If read was successful the post the new info on the console.
            if (bReadSuccess)
            {
                uint index;
                char TempType;
                if (CTInfo.IsFahrenheit)
                    TempType = 'F';
                else
                    TempType = 'C';
                label2.Text = "CPU Name: " + CTInfo.GetCPUName;
                label3.Text = "CPU Speed: " + CTInfo.GetCPUSpeed + "MHz (" + CTInfo.GetFSBSpeed + " x " + CTInfo.GetMultiplier + ")";
                label4.Text = "CPU VID: " + CTInfo.GetVID + "v";
                label5.Text = "Physical CPUs: " + CTInfo.GetCPUCount;
                label6.Text = "Cores per CPU: " + CTInfo.GetCoreCount;
                for (uint i = 0; i < CTInfo.GetCPUCount; i++)
                {
                    label7.Text = "CPU #{0}"+ i;
                    label8.Text = "Tj.Max: " + CTInfo.GetTjMax[i] + "°" + TempType;
                    for (uint g = 0; g < CTInfo.GetCoreCount; g++)
                    {
                        index = g + (i * CTInfo.GetCoreCount);
                        if (CTInfo.IsDistanceToTjMax)
                            label9.Text= "Core #{0}: {1}°{2} to TjMax, {3}% Load"+ index+ CTInfo.GetTemp[index]+ TempType+ CTInfo.GetCoreLoad[index];
                        else
                            label10.Text = "Core #{0}: {1}°{2}, {3}% Load"+ index+ CTInfo.GetTemp[index]+ TempType+ CTInfo.GetCoreLoad[index];
                    }
                }
            }
            else
            {
                Console.WriteLine();
                label1.Text = "Internal error name: " + CTInfo.GetLastError;
                Console.WriteLine("Internal error value: " + (int)CTInfo.GetLastError);
                Console.WriteLine("Internal error message: " + CTInfo.GetErrorMessage(CTInfo.GetLastError));
            }
        }

        private void CTInfo_ReportError(ErrorCodes ErrCode, string ErrMsg)
        {
            Console.ForegroundColor = ConsoleColor.Red;
            Console.WriteLine(ErrMsg);
            Console.ResetColor();
        }

    }
}
No errors in runtime code but when im running to the program i see in label1 the error: CoreTemp_Not_Found

I have windows 7 64bit and gtx 580 video card. I wanted to get/display the video card gpu temperature.

Thanks for helping.

User avatar
The Coolest
Site Admin
Site Admin
Posts: 3379
Joined: Tue Feb 18, 2003 7:48 pm
Location: Tel Aviv, Israel
Contact:

Re: Getting error: CoreTemp_Not_Found why ?

Post by The Coolest »

Hi,

Do you have Core Temp actively running in the background when you try this?
Currently the shared memory library gives you access to Core Temp's data when it's running, this is not a standalone Core Temp module.
Main rig:
AMD Ryzen 9 5950X (True Spirit 140 Direct) / Mobo: Asrock Fatal1ty X470 / EVO 970 500GB + WD Blue 250GB + HDD / GPU: Dell RX 570 4GB / Mem: 2x16GB DDR4-3200 G.Skill 32GTZKW TridentZ - 32GB total / PSU: Seasonic Prime Ultra Gold 650W
NAS:
Core i7 2600K 3.4GHz @ 4.3GHz (Scythe Mugen2) / Mobo: Biostar TP67XE / 2x Inland Pro 120GB + HDDs / GPU: ATi Mach64 VT2 / Mem: 4x4GB DDR3-1600 G.Skill 8GBXL RipJawsX - 16GB total / PSU: Seasonic S12II 620W.
Secondary rigs:
Core i3 7130U / MiniPC / SanDisk SDSSDP-128G / GPU: Intel HD 620 / Mem: 1x8GB DDR3L-1600
Xeon X3430 2.40GHz @ 3.06GHz or Core i3 540 3.06GHz @ 4.0GHz (Freezer 7 Pro) / Mobo: MSI H55M-ED55 / PNY CS1111 240GB / GPU: ATI FirePro V3800 / Mem: 4x2GB DDR3-1600 G.Skill 4GBRL RipJaws - 8GB total / PSU: Seasonic S12II 620W
AMD Phenom II X4 B93 / Mobo: ASUS M2A-VM / GPU: ATI Radeon Xpress X1250 / Crucial M4 120GB / Mem: 2x2GB DDR2-800 - 4GB total / PSU: Antec 380W.

Core Temp - Accurate temperature monitor for Intel's Core/Core 2 and AMD64 processors

Post Reply

Return to “Development”