Jump to content

1,958 posts in this topic

Recommended Posts

21 hours ago, Alpha22 said:
Spoiler


here's to you :

Last login: Mon Apr  9 21:04:33 on console

iMac-di-Fabio:~ fabio$ diskutil list

/dev/disk0 (internal, physical):

   #:                       TYPE NAME                    SIZE       IDENTIFIER

   0:      GUID_partition_scheme                        *120.0 GB   disk0

   1:                        EFI EFI                     209.7 MB   disk0s1

   2:                 Apple_APFS Container disk2         119.8 GB   disk0s2

 

/dev/disk1 (internal, physical):

   #:                       TYPE NAME                    SIZE       IDENTIFIER

   0:      GUID_partition_scheme                        *250.1 GB   disk1

   1:                        EFI EFI                     209.7 MB   disk1s1

   2:                  Apple_HFS macOS Sierra            249.2 GB   disk1s2

   3:                 Apple_Boot Recovery HD             650.0 MB   disk1s3

 

/dev/disk2 (synthesized):

   #:                       TYPE NAME                    SIZE       IDENTIFIER

   0:      APFS Container Scheme -                      +119.8 GB   disk2

                                 Physical Store disk0s2

   1:                APFS Volume macOS High Sierra       97.7 GB    disk2s1

   2:                APFS Volume Preboot                 21.9 MB    disk2s2

   3:                APFS Volume Recovery                517.8 MB   disk2s3

   4:                APFS Volume VM                      20.5 KB    disk2s4

 

iMac-di-Fabio:~ fabio$ diskutil info disk1

   Device Identifier:        disk1

   Device Node:              /dev/disk1

   Whole:                    Yes

   Part of Whole:            disk1

   Device / Media Name:      MAXTOR STM3250310AS

 

   Volume Name:              Not applicable (no file system)

   Mounted:                  Not applicable (no file system)

   File System:              None

 

   Content (IOContent):      GUID_partition_scheme

   OS Can Be Installed:      No

   Media Type:               Generic

   Protocol:                 SATA

   SMART Status:             Verified

 

   Disk Size:                250.1 GB (250059350016 Bytes) (exactly 488397168 512-Byte-Units)

   Device Block Size:        512 Bytes

 

   Read-Only Media:          No

   Read-Only Volume:         Not applicable (no file system)

 

   Device Location:          Internal

   Removable Media:          Fixed

 

   Solid State:              No

   Virtual:                  No

   Hardware AES Support:     No

 

iMac-di-Fabio:~ fabio$ /Users/fabio/Downloads/smarter disk0

Medium Type:       SSD

Protocol:          SATA

Location:          Internal

Temperature:       25C°

Life:              98%

S.M.A.R.T. check disk0:  IOCreatePlugInInterfaceForService() failed with error "IOKit Common: no resource"

S.M.A.R.T. status: not capable

 

S.M.A.R.T. data (512 bytes):

UInt8 smartdata[] = {

0x01, 0x00, 0x05, 0x33, 0x00, 0x64, 0x64, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x32, 

0x00, 0x63, 0x63, 0x03, 0x11, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x0C, 0x32, 0x00, 0x60, 0x60, 0x96, 

0x0D, 0x00, 0x00, 0x00, 0x00, 0x00, 0xB1, 0x13, 

0x00, 0x62, 0x62, 0x12, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0xB3, 0x13, 0x00, 0x64, 0x64, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xB5, 0x32, 

0x00, 0x64, 0x64, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0xB6, 0x32, 0x00, 0x64, 0x64, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xB7, 0x13, 

0x00, 0x64, 0x64, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0xBB, 0x32, 0x00, 0x64, 0x64, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xBE, 0x32, 

0x00, 0x4B, 0x3A, 0x19, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0xC3, 0x1A, 0x00, 0xC8, 0xC8, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC7, 0x3E, 

0x00, 0x63, 0x63, 0x80, 0x03, 0x00, 0x00, 0x00, 

0x00, 0x00, 0xEB, 0x12, 0x00, 0x63, 0x63, 0xB5, 

0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF1, 0x32, 

0x00, 0x63, 0x63, 0x27, 0xC3, 0xC3, 0x38, 0x01, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x68, 0x10, 0x00, 0x53, 

0x03, 0x00, 0x01, 0x00, 0x02, 0x46, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xCC

}

iMac-di-Fabio:~ fabio$

 

 

Thanks this will help me!

Share this post


Link to post
Share on other sites
Advertisement
1 hour ago, Slice said:

Xcode also recommends

https://yadi.sk/i/USFuTKtJ3UHvhH

But this is old Xcode7.3 which can't compile the project

In fact I'll never do that. Suppose that @IBAction (IB = Interface Builder.. i.e. connected in Xcode GUI using xibs) is connectet to multiple objects (sender) you can do that:

@IBAction func actionFromMultipleObjects(sender: AnyObject) {

    if sender is NSButton {

      // AnyObject is a button, so I can use NSButton library to interact with him

    } else if sender is NSTextField {

      // AnyObject is a text field, so I can aquire its text or change it

    } else if sender is NSSlider {

      // AnyObject is a slider, so I can aquire its position and calculate something

    }

  }

 

AnyObject means that inherent to NSObject.h which averything is based on regarding Cocoa (#import <Foundation/Foundation.h> + #import <AppKit/AppKit.h>) to produces interfaces.

Anyway you can see differences because as you know swift is a new language and Xcode7.3 probably can compile at max Swift 2.x while the latest is Swift 4.x. This year Swift 5 will comes out which will be the final release and it will be embedded in the new macOS 10.14 (may be that Apple will decide to update some of the older OSes as well because Swift 5 will have a stable ABI). We are using the latest available today but as any other old version the swift library is totally included in the app bundle, why can this work. With Swift 5 newer apps will be smaller because we will no longer need to include the entire library.. Anyway Swift 5's compiler will be compatible with Swift 4 and We'll be able to produces apps compatible with all old OSes starting from 10.9. So differences with Swift 4 and 5 will be the stable ABI due to small changes their will do (under testing) about the "String" library which is the most used. After that I'm sure Apple will recompile the entire OS to use everything was done using objective c with the new language.

For us, I think, that the project will at least require very very small changes (or nothing)... anyway in two months Xcode 10 will comes for testing and we'll know what.

 

Edited by vector sigma

Share this post


Link to post
Share on other sites
On 8/4/2018 at 1:06 PM, vector sigma said:

Hi Fabio, your instead is bad but I think that the program should have exited before showing untrue data because it says "no resources". Can you kindly show me the output of:


diskutil list

and also


diskutil info disk1

thanks

Last login: Sun Apr 15 09:42:01 on console

iMac-di-Fabio:~ fabio$ diskutil list

/dev/disk0 (internal, physical):

   #:                       TYPE NAME                    SIZE       IDENTIFIER

   0:      GUID_partition_scheme                        *250.1 GB   disk0

   1:                        EFI EFI                     209.7 MB   disk0s1

   2:                  Apple_HFS macOS Sierra            249.2 GB   disk0s2

   3:                 Apple_Boot Recovery HD             650.0 MB   disk0s3

 

/dev/disk1 (internal, physical):

   #:                       TYPE NAME                    SIZE       IDENTIFIER

   0:      GUID_partition_scheme                        *120.0 GB   disk1

   1:                        EFI EFI                     209.7 MB   disk1s1

   2:                 Apple_APFS Container disk2         119.8 GB   disk1s2

 

/dev/disk2 (synthesized):

   #:                       TYPE NAME                    SIZE       IDENTIFIER

   0:      APFS Container Scheme -                      +119.8 GB   disk2

                                 Physical Store disk1s2

   1:                APFS Volume macOS High Sierra       97.6 GB    disk2s1

   2:                APFS Volume Preboot                 21.9 MB    disk2s2

   3:                APFS Volume Recovery                517.8 MB   disk2s3

   4:                APFS Volume VM                      20.5 KB    disk2s4

 

iMac-di-Fabio:~ fabio$ /Users/fabio/Downloads/smarter disk0

Medium Type:       HDD

Protocol:          SATA

Location:          Internal

Temperature:       55834574872C°

S.M.A.R.T. check disk0:  IOCreatePlugInInterfaceForService() failed with error "IOKit Common: no resource"

S.M.A.R.T. status: not capable

 

S.M.A.R.T. data (512 bytes):

UInt8 smartdata[] = {

0x0A, 0x00, 0x01, 0x0F, 0x00, 0x6D, 0x63, 0x9D, 

0x6E, 0x4F, 0x01, 0x00, 0x00, 0x00, 0x03, 0x03, 

0x00, 0x62, 0x61, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x04, 0x32, 0x00, 0x5D, 0x5D, 0x26, 

0x1D, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x33, 

0x00, 0x64, 0x64, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x07, 0x0F, 0x00, 0x54, 0x3C, 0x42, 

0x9D, 0x32, 0x0E, 0x00, 0x00, 0x00, 0x09, 0x32, 

0x00, 0x5F, 0x5F, 0x28, 0x12, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x0A, 0x13, 0x00, 0x64, 0x63, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x32, 

0x00, 0x60, 0x60, 0x78, 0x11, 0x00, 0x00, 0x00, 

0x00, 0x00, 0xBB, 0x32, 0x00, 0x01, 0x01, 0x68, 

0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xBD, 0x3A, 

0x00, 0x60, 0x60, 0x04, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0xBE, 0x22, 0x00, 0x4C, 0x35, 0x18, 

0x00, 0x13, 0x18, 0x00, 0x00, 0x00, 0xC2, 0x22, 

0x00, 0x18, 0x2F, 0x18, 0x00, 0x00, 0x00, 0x0D, 

0x00, 0x00, 0xC3, 0x1A, 0x00, 0x72, 0x3F, 0x81, 

0xC7, 0x89, 0x03, 0x00, 0x00, 0x00, 0xC5, 0x12, 

0x00, 0x64, 0x64, 0x06, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0xC6, 0x10, 0x00, 0x64, 0x64, 0x06, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC7, 0x3E, 

0x00, 0xC8, 0xC8, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0xC8, 0x00, 0x00, 0x64, 0xFD, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xCA, 0x32, 

0x00, 0x64, 0xFD, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x82, 0x00, 0xAE, 0x01, 0x00, 0x5B, 

0x03, 0x00, 0x01, 0x00, 0x01, 0x5C, 0x02, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x03, 

0x03, 0x03, 0x02, 0x03, 0x03, 0x03, 0x03, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 

0x5A, 0xE1, 0x52, 0x0F, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0xD6, 0x93, 0xC0, 0xF9, 0xFC, 0x01, 

0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x5A, 0xE1, 0x52, 0x0F, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0F, 0x00, 

0x00, 0x00, 0x40, 0x77, 0xDC, 0x81, 0x03, 0x00, 

0x00, 0x00, 0x02, 0x9C, 0x01, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x27, 0x12, 0x00, 0x00, 0x00, 0x00, 

0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 

0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x25

}

 

iMac-di-Fabio:~ fabio$ diskutil info disk0

   Device Identifier:        disk0

   Device Node:              /dev/disk0

   Whole:                    Yes

   Part of Whole:            disk0

   Device / Media Name:      MAXTOR STM3250310AS

 

   Volume Name:              Not applicable (no file system)

   Mounted:                  Not applicable (no file system)

   File System:              None

 

   Content (IOContent):      GUID_partition_scheme

   OS Can Be Installed:      No

   Media Type:               Generic

   Protocol:                 SATA

   SMART Status:             Verified

 

   Disk Size:                250.1 GB (250059350016 Bytes) (exactly 488397168 512-Byte-Units)

   Device Block Size:        512 Bytes

 

   Read-Only Media:          No

   Read-Only Volume:         Not applicable (no file system)

 

   Device Location:          Internal

   Removable Media:          Fixed

 

   Solid State:              No

   Virtual:                  No

   Hardware AES Support:     No

 

iMac-di-Fabio:~ fabio$ 

Edited by Alpha22

Share this post


Link to post
Share on other sites

Guys this package: HWSensors-3_r118.pkg.zip contains an improved version of HWMonitorSMC2.app:

- new SMART core made in swift (world first?) that can read s.m.a.r.t. attributes from ATA and finally from NVMe disks B)

- on right click over any rows (not all but most of it) show detailed info about:

  1. CPU (brand string, system usage)
  2. RAM
  3. S.M.A.R.T. attributes with detailed informations about your disks (BSD name, vendor name, serial etc.),
  4. Battery (laptops) with capacity, max capacity, cycle count, temperature etc. (anyway not with VoodooBattery but works with Rehabman's kext or in a real mac)
  5. SYSTEM with info about processes, threads and more.
  6. POWER (if supported), with info about cpu limit, thermal level etc. 

Please show a screen shot about S.M.A.R.T on SATA and NVMe because I worked hard on this. Big thanks goes to @fabiosun for tens and tens of tests made who helped me a lot debugging smart on mechanical and nvme drives (which I did not own).

Thanks goes also to SystemKit.framenwork, now embedded into the project and smartmontools for the reverse engineering that make possible acquire smart datas for NVMe drives on macOS!

 

TODO:

- do a better layout of the datas showned when you right click fixed

- find gpu information somehow

 

@Slice, soon (tonight) I'll commit those changes, just waiting some tests here

EDIT

commited

Edited by vector sigma
committed to r118

Share this post


Link to post
Share on other sites
11 minutes ago, Cyberdevs said:

@vector sigma

Nice work :) Thanks a lot man. Everything seems to be working fine. I just have to say I'm using my previous sensors. Haven't tested my rig with the sensors included in the package. I'll test them later and report back.

Screen Shot 2018-04-15 at 9.48.37 PM.png

Very good! No matter the kexts you installed unless too old.

Edited by vector sigma

Share this post


Link to post
Share on other sites
10 hours ago, vector sigma said:

Guys this package: HWSensors-3_r118.pkg.zip contains an improved version of HWMonitorSMC2.app:

 

Battery (laptops) with capacity, max capacity, cycle count, temperature etc. (anyway not with VoodooBattery but works with Rehabman's kext or in a real mac)

 

@Slice, soon (tonight) I'll commit those changes, just waiting some tests here

 

Thanks!

The package is reloaded to sf.net

About VoodooBattery what is missing? AFAIK Rehabman's kext calculate temperature as current divided by constant as no real sensor exists.

Share this post


Link to post
Share on other sites

1. There should be

Quote

#import "../SMART/NVMe.h"

?

 

2. No such module SystemKit?

 

3. What is the GPU-17635765476125348?

2018-04-16_07-30-07.png

 

4. Right click on HDD gives me empty window

2018-04-16_07-35-31.png

 

Share this post


Link to post
Share on other sites
16 hours ago, Slice said:

1. There should be

?

 

2. No such module SystemKit?

 

 

I didn't experience any of those issues but:

1. is referenced in the Xcode project and I didn't expect this is the issue.

2. Well, the issue is that the compiled framenwork is not present because not yet built

possible remedy, go in "Build Settings" and under "Framework Search Paths" add these if missing in two lines:

$(inherited)
${TARGET_BUILD_DIR}/SystemKit.framework

the first is a common solution, the second tells Xcode to link the framenwork in the target build dir where should be present since Xcode build it before everything. Tell me if work because until tonight I cannot try.

If that is not enough we should consider to build the framenwork separately and then add it already compiled.

Anyway the project should compile.. isn't?

16 hours ago, Slice said:

3. What is the GPU-17635765476125348?

At the moment I've no idea but I can image is a bad format argument.

16 hours ago, Slice said:

4. Right click on HDD gives me empty window

2018-04-16_07-35-31.png

 

Yesterday we experience an issue that was causing the app to crash. I'll revise the relevant part of code. In the meantime this is a command line I made to test smart with fabiosun  and contains the code already present in the app. please post the result here so that I can take a look on it (just double click on it)

Edited by vector sigma
typo

Share this post


Link to post
Share on other sites
45 minutes ago, vector sigma said:

Try this commandline please: hwsensorsmart

(cliccaci sopra e posta il risultato)

iMac-di-Fabio:~ fabio$ /Users/fabio/Downloads/hwsensorsmart 

----------------------------------------------------

disk0

ATASMARTData(vendorSpecific1: (10, 0, 1, 15, 0, 109, 99, 157, 110, 79, 1, 0, 0, 0, 3, 3, 0, 99, 97, 0, 0, 0, 0, 0, 0, 0, 4, 50, 0, 93, 93, 142, 29, 0, 0, 0, 0, 0, 5, 51, 0, 100, 100, 0, 0, 0, 0, 0, 0, 0, 7, 15, 0, 84, 60, 181, 17, 51, 14, 0, 0, 0, 9, 50, 0, 95, 95, 52, 18, 0, 0, 0, 0, 0, 10, 19, 0, 100, 99, 0, 0, 0, 0, 0, 0, 0, 12, 50, 0, 96, 96, 121, 17, 0, 0, 0, 0, 0, 187, 50, 0, 1, 1, 104, 1, 0, 0, 0, 0, 0, 189, 58, 0, 96, 96, 4, 0, 0, 0, 0, 0, 0, 190, 34, 0, 67, 53, 33, 0, 19, 33, 0, 0, 0, 194, 34, 0, 33, 47, 33, 0, 0, 0, 13, 0, 0, 195, 26, 0, 88, 63, 37, 97, 114, 4, 0, 0, 0, 197, 18, 0, 100, 100, 6, 0, 0, 0, 0, 0, 0, 198, 16, 0, 100, 100, 6, 0, 0, 0, 0, 0, 0, 199, 62, 0, 200, 200, 0, 0, 0, 0, 0, 0, 0, 200, 0, 0, 100, 253, 0, 0, 0, 0, 0, 0, 0, 202, 50, 0, 100, 253, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), offLineDataCollectionStatus: 130, selfTestExecutionStatus: 0, secondsToCompleteOffLineActivity: (174, 1), vendorSpecific2: 0, offLineDataCollectionCapability: 91, SMARTCapability: (3, 0), errorLoggingCapability: 1, vendorSpecific3: 0, shortTestPollingInterval: 1, extendedTestPollingInterval: 92, reserved: (2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), vendorSpecific4: (0, 0, 0, 0, 4, 1, 1, 1, 2, 3, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 90, 225, 82, 15, 0, 0, 0, 0, 0, 0, 155, 7, 138, 80, 254, 1, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 90, 225, 82, 15, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 1, 0, 0, 0, 15, 0, 0, 0, 175, 69, 225, 129, 3, 0, 0, 0, 183, 224, 67, 0, 0, 0, 0, 0, 39, 18, 0, 0, 0, 0, 152, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), checksum: 59)

SMARTValidateReadData

SMARTReadDataThresholds

----------------------------------------------------

disk1

ATASMARTData(vendorSpecific1: (1, 0, 5, 51, 0, 100, 100, 0, 0, 0, 0, 0, 0, 0, 9, 50, 0, 99, 99, 16, 17, 0, 0, 0, 0, 0, 12, 50, 0, 96, 96, 152, 13, 0, 0, 0, 0, 0, 177, 19, 0, 98, 98, 19, 0, 0, 0, 0, 0, 0, 179, 19, 0, 100, 100, 0, 0, 0, 0, 0, 0, 0, 181, 50, 0, 100, 100, 0, 0, 0, 0, 0, 0, 0, 182, 50, 0, 100, 100, 0, 0, 0, 0, 0, 0, 0, 183, 19, 0, 100, 100, 0, 0, 0, 0, 0, 0, 0, 187, 50, 0, 100, 100, 0, 0, 0, 0, 0, 0, 0, 190, 50, 0, 72, 58, 28, 0, 0, 0, 0, 0, 0, 195, 26, 0, 200, 200, 0, 0, 0, 0, 0, 0, 0, 199, 62, 0, 99, 99, 131, 3, 0, 0, 0, 0, 0, 235, 18, 0, 99, 99, 181, 8, 0, 0, 0, 0, 0, 241, 50, 0, 99, 99, 234, 223, 213, 57, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), offLineDataCollectionStatus: 0, selfTestExecutionStatus: 0, secondsToCompleteOffLineActivity: (104, 16), vendorSpecific2: 0, offLineDataCollectionCapability: 83, SMARTCapability: (3, 0), errorLoggingCapability: 1, vendorSpecific3: 0, shortTestPollingInterval: 2, extendedTestPollingInterval: 70, reserved: (0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), vendorSpecific4: (0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0), checksum: 199)

SMARTValidateReadData

SMARTReadDataThresholds

------------------------------------------------

BSD Name: disk0

Product Name: MAXTOR STM3250310AS                     

Product Revision Level: 3.AAC   

Serial Number: 6RY3EDGC

Medium Type: HDD

Capacity: 250,06 GB (250059350016 bytes)

Physical Interconnect: SATA

Physical Interconnect Location: Internal

Temperature: 33C°

S.M.A.R.T. status: Ok

 

------------------------------------------------

BSD Name: disk1

Product Name: Samsung SSD 840 EVO 120GB               

Product Revision Level: EXT0AB0Q

Serial Number: S1D5NEAD713475A

Medium Type: SSD

Capacity: 120,03 GB (120034123776 bytes)

Physical Interconnect: SATA

Physical Interconnect Location: Internal

Temperature: 28C°

Life: 98%

S.M.A.R.T. status: Ok

Share this post


Link to post
Share on other sites
6 hours ago, fabiosun said:

special version..remember :P:)

Sure, next version will show also the rotation rate for mechanical hard drives (like Rotation Rate = 7200rpm")

rpm.png.ae1582eaecf98660904140166cbafbe2.png

On 16/4/2018 at 5:46 AM, Slice said:

About VoodooBattery what is missing?

Max cycles and current cycles count. Didn't remembar if also the vendor show up.

Edited by vector sigma
apict added

Share this post


Link to post
Share on other sites

@Alpha22, thanks, your looks fine now.

On 17/4/2018 at 5:15 PM, Slice said:

I think you forgot to check an optional value != nil before unwrap it.

Can be and also due to a wrong logic. Please test this: [removed] I'm working on. running it in Xcode you should see where is crashing.

P.S. some code commented and moved, needs a clean up.

Edited by vector sigma

Share this post


Link to post
Share on other sites

Hi @vector sigma,

I made the follow change compared to rev 121

  public func temperature(_ unit: TemperatureUnit = .celsius) -> Double {
    var temperature: Double?
    if let prop = IORegistryEntryCreateCFProperty(service,
                                               Key.Temperature.rawValue as CFString!,
                                               kCFAllocatorDefault, 0) {
    
      temperature = prop.takeUnretainedValue() as! Double / 100.0
    } else {
      temperature = 0
    }
    
    switch unit {
    case .celsius:
      // Do nothing - in Celsius by default
      // Must have complete switch though with executed command
      break
    case .fahrenheit:
      temperature = Battery.toFahrenheit(temperature!)
    case .kelvin:
      temperature = Battery.toKelvin(temperature!)
    }
    
    return ceil(temperature!)
  }

That way if prop=nil then temperature=0

It is not good way but the way there is no crash at as! unwrap. The better will be to keep temperature to be optional Double.

Share this post


Link to post
Share on other sites
3 hours ago, Slice said:

It is not good way but the way there is no crash at as! unwrap

Good. The following is working as well?

public func temperature(_ unit: TemperatureUnit = .celsius) -> Double {
    var temperature: Double = 0
    if let prop = IORegistryEntryCreateCFProperty(service,
                                                  Key.Temperature.rawValue as CFString!,
                                                  kCFAllocatorDefault, 0) {
      
      temperature = prop.takeUnretainedValue() as! Double / 100.0
    }
    
    switch unit {
    case .celsius:
      // Do nothing - in Celsius by default
      // Must have complete switch though with executed command
      break
    case .fahrenheit:
      temperature = Battery.toFahrenheit(temperature)
    case .kelvin:
      temperature = Battery.toKelvin(temperature)
    }
    
    return ceil(temperature)
  }

No optional value, just initialize the temperature variable.

This framenwork was a swift 3.2 converted to 4 by me, also I've made similar corrections. Later I'll send to the mantainer a pull request with our changes.

EDIT

from the same dev I found this: https://github.com/beltex/SMCKit, later I'll take a look if there's something suitable for us..

EDIT II

Slice please tell me if you have Xcode 9.3 ... some changes I want to do for newer version of Swift... a step to be ready for the incoming Swift 5

Edited by vector sigma

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By fusion71au
      This is a brief guide on how to create a vanilla El Capitan (also same process for Sierra) OS X Installer USB with an updated prelinked kernel containing FakeSMC.

      It is tailored for those users who want to understand the “nuts and bolts” of how to create an installer and also to help brush up on their terminal skills (rather than have one made for them with the numerous automated “tools” available or even Apple’s createinstallmedia) :
       
       
      Specifically, it is also a “Proof of Concept” which shows that installation is possible without even having to rely on boot loader kext injection.

      Prerequisites
      Existing Yosemite installation (or Mavericks - see post#4 for steps 7,8) “Install OS X El Capitan.app" downloaded to the Applications folder Pacifist FakeSMC.kext - Slice or Kozlek branch Bootloader - Clover or Chameleon 8GB or larger USB drive (16GB recommended), formatted HFS+ (MBR or GUID) named “Installer”  
      Procedure
      1.  Boot into Yosemite with the kext-dev-mode=1 boot flag
      2.  Open OS X terminal and type the following lines, followed by <Enter> after each line.
          The image restore and file copying may take a while to complete, and at the end of the process, the Installer volume is renamed to “OS X Base System"....
       
      sudo -s hdiutil attach /Applications/Install\ OS\ X\ El\ Capitan.app/Contents/SharedSupport/InstallESD.dmg asr restore -source /Volumes/OS\ X\ Install\ ESD/BaseSystem.dmg  -target /Volumes/Installer -erase -format HFS+ -noprompt -noverify rm /Volumes/OS\ X\ Base\ System/System/Installation/Packages cp -av /Volumes/OS\ X\ Install\ ESD/Packages /Volumes/OS\ X\ Base\ System/System/Installation cp -av /Volumes/OS\ X\ Install\ ESD/BaseSystem.dmg /Volumes/OS\ X\ Install\ ESD/BaseSystem.chunklist /Volumes/OS\ X\ Base\ System diskutil unmount /Volumes/OS\ X\ Install\ ESD exit 3.  Right click on the “OS X Base System” Volume and click “Get Info”
       

      4.  Click on the lock icon and untick “Ignore ownership on this volume”
       

      5.  Extract/Copy the El Capitan Kernels folder into /System/Library/ of the USB with Pacifist.  NB It is found in the "Essentials.pkg" in /System/Installation/Packages
       

      6.  Delete or Rename the original /System/Library/PrelinkedKernels/prelinkedkernel —> OG.prelinkedkernel
       

      7.  Copy FakeSMC.kext and other necessary kexts (e.g. VoodooPS2Controller.kext for laptops) into the /Library/Extensions folder of the installer USB using Finder.
       

      8.  Back in terminal, type the following lines, followed by <Enter> after each line to rebuild the prelinkedkernel…..
       
      sudo -s chmod -R 755 /Volumes/OS\ X\ Base\ System/Library/Extensions chown -R 0:0 /Volumes/OS\ X\ Base\ System/Library/Extensions touch /Volumes/OS\ X\ Base\ System/System/Library/Extensions kextcache -u /Volumes/OS\ X\ Base\ System exit Any errors should be noted but the output below is normal e.g.


      9. Install your Bootloader targeting the OS X Base System volume
       
       
       
       
      10.  Boot your system with the USB without injected kexts into the OS X Installer GUI....
       
       
       
       
       
      Post Install
      The original prelinked kernel in a fresh install of El Capitan will also lack FakeSMC ie it will only be linked to Apple signed kexts.  In order to boot into El Capitan the first time around without boot loader kext injection, the PLK needs to be rebuilt for the El Capitan volume like we did for the installer:
       
      1.  Boot into Yosemite with the kext-dev-mode=1 boot flag
      2.  Delete or Rename the original /System/Library/PrelinkedKernels/prelinkedkernel for the El Capitan volume —> OG.prelinkedkernel
      3.  Copy FakeSMC.kext and other necessary kexts (e.g. VoodooPS2Controller.kext for laptops) into the /Library/Extensions folder of El Capitan using Finder
      4.  Back in terminal, type the following lines, followed by <Enter> after each line to rebuild the prelinkedkernel.  In this example, the El Capitan volume is named "El_Capitan" - change if you have named it something else...
      sudo -s chmod -R 755 /Volumes/El_Capitan/Library/Extensions chown -R 0:0 /Volumes/El_Capitan/Library/Extensions touch /Volumes/El_Capitan/System/Library/Extensions kextcache -u /Volumes/El_Capitan exit 5. Install your Bootloader targeting the El Capitan volume.  This step is only necessary if you are installing El Capitan on a new drive without existing boot loader (not required if installing on a disk with existing boot loader beside Yosemite).
      6. Reboot your system without injected kexts into El Capitan!
       
       
      Other links
      The All-In-One Guide to Vanilla OS X for beginners
       
      Updates for Sierra and High Sierra   Custom Prelinkedkernel Generator Tool I have made a custom prelinkedkernel generator "PLK.tool" for Sierra + El Capitan.  Instructions:   1.  Download and extract the attached BaseSystem_PLK.tool.zip into your ~/Downloads folder.   2.  Copy any extra kexts necessary for booting your hack to ~/Downloads/BaseSystem/ExtraKexts (e.g. FakeSMC, VoodooPS2Controller), making sure SIP is disabled. 3.  Copy BaseSystem.dmg to ~/Downloads/BaseSystem  4.  Open terminal and run the following commands... cd ~/Downloads/BaseSystem chmod +x PLK.tool ./PLK.tool ---> supply your admin password ---> will place your new custom prelinkedkernel on the desktop.       macOS High Sierra bypass Firmware and MBR checks in post#13.
      BaseSystem_PLK.tool_ElCap.zip
      BaseSystem_PLK.tool_Sierra.zip
      BaseSystem_PLK.tool_Mojave.zip (need to run in Mojave to avoid dependency errors)
      BaseSystem_PLK.tool_Catalina.zip
    • By Slice
      Dell laptops and desktop can be monitored by SMM methods as mentioned is the old topic
       
      I made a plugin SMIMonitor for FakeSMC in 2014 but it was 32bits and was not working. Only now I made it to be 64bits (as darkvoid did with kozleks branch) and got positive results
        
      and after heating 
      So I have monitoring of 4 additional temperature sensors (CPU Proximity, GPU, DIMM, and Motherboard) and a CPU fan which initially stay at 0 rpm and start rotating after heating with 2882rpm.
       
      Moreover I implemented a function for brave people to control fans
      sudo SMC_util3 -kF0As -w2 The last digit 2 is a FAN speed you want to set
      0 = Off
      1 = Low
      2 = High
      If you have more then 1 fan then you can manage other one by choosing next key F1As, F2As etc.
       
      Precaution! Writing the fan speed is dangerous and may cause a computer damage. Do this at your own risk!
      Note. SMIMonitor.kext will work only with FakeSMC v3 provided with HWSensors3 in my signature.
      Official release at sf.net contains SMIMonitor without write possibility.
       
      Please test and report your successes and fails.
       
       
      SMIMonitor.kext-110.zip
      SMC_util3.zip
      smcwrite.zip
    • By DaHarry
      I have installed Hackintosh on to my System, but the CPU cooler is obviously louder then on Windows.
      I am using right now VirtualSMC.kext, but since FakeSMC provides temperature measurement tools, and VirtualSMC not, I asked my self if that might be a hint for my loud cooler?
      My question, has somebody tried maybe both and even compared them? And is FakeSMC maybe less noisy?
      Is it enough to just mount EFI partition, and delete the VirtualSMC.kext and put instead FakeSMC.kexts ? Without any fancy kext installation tool or terminal commands, just replace files and restart in enough?
      My System:
      Mainboard: Gigabyte Aorus Z390 Ultra
      CPU: Intel i9 9900k
      CPU Cooler: BeQuiet! Dark Rock 4
      GPU: Vega 64
      Ram: 2x16GB Corsair 3200
      SSD: 1TB Adata M.2
       
      The Tutorial i have used - https://github.com/cmer/gigabyte-z390-aorus-master-hackintosh/blob/master/STEP_BY_STEP.md
       
      Really works like a charm besides, the more noisy cooler, which i bought because it is extra quietly.
      I asked first at tonymac's forum, but they deleted the post because I haven't used their tool, really disgustig.. I really hope to never use their tools, and I hope here the information freedom is more respected.
      #f. tonyhoremacs
    • By vector sigma
      HWSensor Features
      Control temperature of Intel and AMD CPU Control temperature of AMD, Intel and NVidia cards Control temperature of motherboard Control FANS Control Voltages Control HDD/SSD state (SATA & NVMe) with S.M.A.R.T. monitoring  Control frequencies Laptop Battery Monitoring Different applications support High Sierra compatible Installation to /S/L/E or in the ESP (Clover only)  
      Supported languages:
      English (base), Russian, Italian, Korean and semplified Chinese
       
      Source code: at https://sourceforge.net/p/hwsensors/hwsensors3/code3/HEAD/tree/
      Bugs report at https://sourceforge.net/p/hwsensors/hwsensors3/tickets/
      Topic for discussion at: https://www.insanelymac.com/forum/topic/299861-hwsensors3/
       
      Chief Developer @Slice, new HWMonitorSMC2.app and package by @vector sigma
×