nickdademo / cp2112_demo

Demo code for reading SMBus battery parameters using the Silicon Labs CP2112 board.
15 stars 10 forks source link

Then I’m trying to read from usb-to-i2c converter cp2112, using C and DLL, I'm obtain HID_SMBUS_INVALID_PARAMETER error from HidSmbus_GetReadResponse #4

Open mihail-popovkin opened 3 years ago

mihail-popovkin commented 3 years ago

Function

status = HidSmbus_GetReadResponse(device, &status0, _buffer, HID_SMBUS_MAX_READ_RESPONSE_SIZE, &numBytesRead);

returns HID_SMBUS_INVALID_PARAMETER I'm use amd64 dll from this repo What I'm doing wrong?

nickdademo commented 3 years ago

@mihail-popovkin Can you share a bit more of your code? i.e. the actual parameter values