Author Topic: Serial to usb on Kunkin KP184 electronic load  (Read 46777 times)

0 Members and 1 Guest are viewing this topic.

Offline belzrebuth

  • Frequent Contributor
  • **
  • Posts: 482
  • Country: gr
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #25 on: July 03, 2020, 08:41:13 am »
Is there a guide somewhere on how to setup the USR-232-T2 ethernet to RS232 module?
I've managed to connect to it via LAN but I think it needs a serial to TTL converter (3.3 to 5V in order to work with the KP184)
The FTDI clone I have does now work with the load.
It has a FTDI chip so there must the level conversion again that's probably incompatible.
Could it work with a diy level shifter?
I've seen some designs with a couple of transistors..
« Last Edit: July 03, 2020, 12:47:47 pm by belzrebuth »
 

Online coromonadalix

  • Super Contributor
  • ***
  • Posts: 5780
  • Country: ca
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #26 on: July 03, 2020, 02:24:51 pm »
The one i use the most is  a model  sp-880   usb to rs232, it as a real ft232 with an transceiver ic   betwwen the rs232 plug and the ftdi chip

maybe some other source ??

https://www.amazon.ca/Connectors-SP-880-UT-880-Compatibility-Yoton/dp/B07Q6HW46V


https://botland.com.pl/en/converters-usb-to-uart-rs232-rs485/4371-ft232rl-sp-880-usb-converter-rs232-com-10v-with-db9-connector-adafruit-18.html
 

Offline belzrebuth

  • Frequent Contributor
  • **
  • Posts: 482
  • Country: gr
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #27 on: July 03, 2020, 02:38:01 pm »
Mine has a jumper for 3.3V or 5V operation.
I've set it for 5V and still nothing.
The adapter is working because I use it very often so maybe it's their combination that's somehow problematic.

My settings on the Kunkin are :
address 001, baud rate 19200.
And on the adapter I've set the baud rate to 19200 and N 8 1 with delay 100mSec.
I've checked the RX and TX pins of my FTDI adapter and they're both 5V when I set the jumper to 5V so it's not the voltage level..
I've tried both the modbus cmd program and kp184 modbus program from interflexo.
But I get no answer from the load.. :-//
Here's the output when trying to run the modbus KP184.exe (I switched my baud rate to 9600 just in case) :
 
Verbose  17:47:19.664 port                :COM Port: com4
Verbose  17:47:19.675 baud                :BAUD rate: 9600
Verbose  17:47:19.676 delay               :Sleeping for 100ms
Verbose  17:47:19.786 address             :Device address: 1
Verbose  17:47:19.789 get_status          :Calling get_status from KP184
Verbose  17:47:19.795 open                :Opening serial port 'com4' at 9600 baud
Error    17:47:20.884 read                :Timeout reading from com4
Error    17:47:20.890 Main                :Checksum error, got 0x0000. expected 0x1B1B

I'm using a female DB9 connector with pins 2,3,5 being pins RX, TX, GND of my FTDI respectively.
« Last Edit: July 03, 2020, 03:03:51 pm by belzrebuth »
 

Offline HKJ

  • Super Contributor
  • ***
  • Posts: 2892
  • Country: dk
    • Tests
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #28 on: July 03, 2020, 04:26:22 pm »
Mine has a jumper for 3.3V or 5V operation.
I've set it for 5V and still nothing.
The adapter is working because I use it very often so maybe it's their combination that's somehow problematic.

Try measuring the voltage on the DB9 connector, if it is a RS232 output it is more than +/-9V and will not work directly with a TTL level adapter with 3.3V or 5V, both the voltage and polarity will be wrong.
 

Offline belzrebuth

  • Frequent Contributor
  • **
  • Posts: 482
  • Country: gr
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #29 on: July 03, 2020, 04:56:56 pm »
I'm getting 5V at pin 2 (with 5 being the negative) and 5V at pin 7.
That's on the Kunkin connector.
5V should be the TX pin (from the manual) and should go to the RX pin of the adapter and vice versa for the other RX and TX.
That's what I've done and it's not working.
I could try another USB to serial adapter I guess..but I suspect there might be a connection issue of some sort since this FTDI tool has worked with everything I've thrown at it and it has a FTDI chip which essentially what most of the working adapters reported here have as well.
I've ordered a couple of other adapters but they won't be here anytime soon so I will try to verify if there's a connection issue.
« Last Edit: July 03, 2020, 05:04:56 pm by belzrebuth »
 

Online coromonadalix

  • Super Contributor
  • ***
  • Posts: 5780
  • Country: ca
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #30 on: July 03, 2020, 06:09:00 pm »
If you are under windows, dont forget in the device manager  to set  higher baud rates for the usb rs232 adapter, it default to 9600 bauds, i always set them to 115200 bauds  ...  had a stupid problem in the past because of this  :palm:
« Last Edit: July 03, 2020, 06:11:32 pm by coromonadalix »
 

Offline belzrebuth

  • Frequent Contributor
  • **
  • Posts: 482
  • Country: gr
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #31 on: July 03, 2020, 06:47:34 pm »
Okay I'll try higher baud rate and report back!
 

Offline aristarchus

  • Regular Contributor
  • *
  • Posts: 107
  • Country: 00
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #32 on: July 07, 2020, 01:00:53 am »
Hi,

Just recently received my KP184 and tried to use the RS232 port.
Initially tried with a USB to UART simple little board but it was not working.
https://www.aliexpress.com/premium/FT232RL-USB-to-TTL-Serial-Adapter-Module.html
Then I understood that it is indeed a RS232 port on the KP184 and not a UART, thus I added a small MAX RS232 level converter
https://www.aliexpress.com/premium/MAX3232-Level-to-TTL-Level-Board.html
between the USB to UART board and the KP184 RS232 port and now it is working just fine up to the full 115200bps.

So if someone wants to have something that works and not endlessly searching for the proper adaptor, that is a working solution.
Tried it with modules having fake and original FTDI chips, its just the same, both work ok.


PS
Added a photo of level converter and USB to UART.
« Last Edit: July 07, 2020, 10:09:12 am by aristarchus »
 
The following users thanked this post: CyberWalker, mixiom

Offline aristarchus

  • Regular Contributor
  • *
  • Posts: 107
  • Country: 00
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #33 on: July 10, 2020, 07:28:18 pm »
Also tested the RS485 port on KP184.
Used two solutions, first adding a TTL/UART to RS485 board instead of the RS232
https://www.aliexpress.com/wholesale?catId=0&SearchText=ttl+to+RS485
which worked just fine.
Then tested a ready made USB to RS485 for less than 2 bucks
https://www.aliexpress.com/wholesale?SearchText=USB+FTDI+TTL%2FRS485
which again worked ok.
 
The following users thanked this post: CyberWalker, mixiom

Offline aristarchus

  • Regular Contributor
  • *
  • Posts: 107
  • Country: 00
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #34 on: July 21, 2020, 11:01:53 am »
Managed to find the KP184 modbus protocol specification.
I hope it can be of use and developers could add all functionality in their programs.
 
The following users thanked this post: CyberWalker, dariuskt

Offline interflexo

  • Regular Contributor
  • *
  • Posts: 131
  • Country: pt
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #35 on: November 24, 2020, 04:34:27 pm »
New KP184 Software Version 1.0.5.0:

Changes:

1. Fixed some data logging hiccups during application main window drag
2. Fixed graph y-label slightly clipped
3. Several support modules were updated in the Python ecosystem.
Setup KP184 Software V1.0.64.0
User_Manual

Just use the new .EXE file over your previous v1.0.4.0 installation to preserve your configuration.
« Last Edit: February 14, 2024, 08:17:49 pm by interflexo »
 
The following users thanked this post: tonyalbus

Offline interflexo

  • Regular Contributor
  • *
  • Posts: 131
  • Country: pt
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #36 on: January 15, 2021, 11:49:15 pm »
New KP184 Software Version 1.0.6.0:

Changes:

1. Added some thread locks around logged data handling
2. Several support modules were updated in the Python ecosystem.
Setup KP184 Software V1.0.64.0
User_Manual

A user reported some documented problems in logged time on a iMAC I5 from 2015 running Windows 10.

In spite of my best efforts I could not replicate the described problems using a Lenovo Thinkpad T520 I5 2,5Ghz 8Gb RAM running Windows 10 Pro 64 bits.

Nevertheless I examined the code and added some thread locks around logged data handling, compiled a new build (v1.0.6.0) and put it through a 2 hour hell burn in test - battery discharge test data log with continuous cycle of simultaneous write (from within application) of more than 200 csv files without any problems.

Any feedback would be much appreciated.
« Last Edit: February 14, 2024, 08:28:47 pm by interflexo »
 
The following users thanked this post: tonyalbus

Offline tonyalbus

  • Frequent Contributor
  • **
  • Posts: 927
  • Country: nl
  • To better understand, you need to open it ;-)
    • My Channel
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #37 on: January 16, 2021, 10:02:59 am »
Thanks again for your efforts and the share  :-+
Electronics enthusiast, TEA and Radio Amateur (PE1ONS)
Marconi  - TTi - Thandar - Thurmbly - HP - Fluke - Philips - Siglent - Owon - TEK - Anritsu - Keithley - AVO - BG7TBL
https://www.youtube.com/TonyAlbus
 

Offline interflexo

  • Regular Contributor
  • *
  • Posts: 131
  • Country: pt
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #38 on: January 21, 2021, 02:18:44 pm »
New KP184 Software Version 1.0.7.0:

Changes:

1. Added automatic PDF report creation from the battery discharge capacity test results.
2. Smoother data files (.csv; .png; .pdf) bulk writes during data acquisition.
3. User Manual updated for the new functionality description.
4. Several support modules were updated in the Python ecosystem.

Setup KP184 Software V1.0.64.0
User_Manual
Dummy New Test Report

Please note that this version as a new template file called "Report.html". If you are upgrading from the last versions please add this file, overwrite the new executable file and you are good to go. Your application custom configuration is stored in the "kp184.ini" file.

I thank all users for your suggestions and precious input.

There was a problem with the unregistered mode startup. Solved now.
« Last Edit: February 14, 2024, 08:29:15 pm by interflexo »
 

Offline interflexo

  • Regular Contributor
  • *
  • Posts: 131
  • Country: pt
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #39 on: January 24, 2021, 12:53:14 pm »
New KP184 Software Version 1.0.8.0:

Changes:

1. Added a software implemented end voltage condition test: go half current until next undervoltage during battery capacity discharge test.
2. User Manual updated for the new functionality description.

Setup KP184 Software V1.0.64.0
User_Manual

« Last Edit: February 14, 2024, 08:29:38 pm by interflexo »
 

Offline F64098

  • Regular Contributor
  • *
  • Posts: 53
  • Country: de
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #40 on: January 24, 2021, 02:00:56 pm »
Hello interflexo,

i get a permanent error on starting, even with version 1.0.8.0
Win10Pro 64 20H2, KP184.exe located on C:\

Best regards

Frank
 

Offline interflexo

  • Regular Contributor
  • *
  • Posts: 131
  • Country: pt
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #41 on: January 24, 2021, 02:55:22 pm »
Hi Frank,

Please double check the file version properties of the KP184.exe file you are using.

That error appeared on the unregistered run of version 1.0.7.0, I then corrected it on the same day and uploaded the fix under the same version number (bad practice). Browser cache plays some tricks here.

You should not install it on the root C: directory, that requires Administrator permissions, although I tried it on my Win10Pro 64 system and everything was fine.

You have an Install.txt information file on the installation directory.

Download the zip file to your system. Open the directory where the zip file is located. Double click on the zip file to open it. Double click on the KP184.exe file and select the "Extract All" button and select the installation directory (avoid root and other inconvenient OS system directories). Install Ds-Digital fonts as described on the Install.txt file. Create a shortcut if you want. You are good to go.
« Last Edit: January 24, 2021, 03:00:17 pm by interflexo »
 

Offline F64098

  • Regular Contributor
  • *
  • Posts: 53
  • Country: de
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #42 on: January 24, 2021, 07:29:41 pm »
Hello interflexo,

tried several times, also with an older version (1.0.5.0).
Same error on any variation.
Maybe an issue of the Windows Defender...

Best regards

Frank
 

Offline interflexo

  • Regular Contributor
  • *
  • Posts: 131
  • Country: pt
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #43 on: January 24, 2021, 08:12:16 pm »
Hi Frank,
Sent you a PM with a debug version to help you sort it out.
Please keep me posted.
 

Offline interflexo

  • Regular Contributor
  • *
  • Posts: 131
  • Country: pt
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #44 on: January 24, 2021, 11:11:36 pm »
Thanks to Frank I managed to identify, isolate and replicate the problem in a Windows Sandbox clean Windows 10 installation.

Debug info:

ImportError: DLL load failed while importing ft2font: The specified module could not be found.

The issue is explained here: StackOverflow Post

and is related to a Python matplotlib module version and msvc-runtime installation. I will probably have to downgrade matplotlib module to get rid of this. Still accessing the best course of action.

This should affect only a small undetermined number of systems but nevertheless has to be dealt with.
« Last Edit: January 24, 2021, 11:20:56 pm by interflexo »
 

Offline interflexo

  • Regular Contributor
  • *
  • Posts: 131
  • Country: pt
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #45 on: January 25, 2021, 12:47:43 am »
Traced the problem and the solution is: if the error "Failed to execute script Main" occurs please install:

Microsoft Visual C++ 2015 Redistributable (x86) - 14.0.24123

Select the English language. Select the "vc_redist.x86.exe" file 13.5Mb published on 6/2/2016. Install.

Please note: install the x86 version even if you have a 64bit system.

I will probably go with a "Chocolatey packages" installer to automate this process along with fonts installation, etc. Things start small then get pretty serious.
« Last Edit: January 25, 2021, 12:51:51 am by interflexo »
 

Offline interflexo

  • Regular Contributor
  • *
  • Posts: 131
  • Country: pt
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #46 on: January 25, 2021, 05:46:41 am »
KP184 Software Version 1.0.8.0 Windows Installer:

Setup KP184 Software V1.0.64.0

Documentation, fonts and Microsoft Visual C++ 2015 Redistributable (x86) are automatically installed if required.
« Last Edit: February 14, 2024, 08:30:07 pm by interflexo »
 
The following users thanked this post: tonyalbus

Offline interflexo

  • Regular Contributor
  • *
  • Posts: 131
  • Country: pt
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #47 on: January 25, 2021, 12:24:54 pm »
New KP184 Software Version 1.0.9.0:

Changes:

1. Added the new information to the automatic PDF report creation for the end voltage condition test: go half current until next undervoltage during battery capacity discharge test.
2. User Manual updated for the new setup description.

Setup KP184 Software V1.0.64.0
« Last Edit: February 14, 2024, 09:53:45 pm by interflexo »
 
The following users thanked this post: tonyalbus

Offline Penguin36

  • Contributor
  • Posts: 46
  • Country: 00
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #48 on: January 25, 2021, 10:40:09 pm »
Hi there, I cannot get the serial connection working on my brand new KP184. I‘m using the recommended Digitus RS232 adapter with SW 1.0.8.0
The SW tries to connect but doesn’t receive an answer from the load.
I used a scope to track the signal inside the KP184, and found the sent message on pin 3 of U23( Dual-Channel Digital Isolator) and on its output to the MC. I‘m sure that the reply message of the KP184 will be on pin 2 of the same IC. But there is no serial signal. Even on the TX pin of the MC there is no answer message. Seems like it is disabled.

Address is 1, baud is 9600. Is there a menu entry to  enable serial communication?
 

Offline interflexo

  • Regular Contributor
  • *
  • Posts: 131
  • Country: pt
Re: Serial to usb on Kunkin KP184 electronic load
« Reply #49 on: January 25, 2021, 11:36:15 pm »
That is unfortunate. It's the fourth unit that I know of that exhibits that same behavior.

The only parameter that could cause problems would be:

On Kunkin: Multi-machine online mode: Offline/Slave/Host -> Use Offline

The tests you made were thorough enough to me.

Nevertheless, two tests can be made:

During the connection process the software asks Kunkin KP184 for the content of the memory address 0x001 which holds the equipment model number (0x0730 = 1840), Kunkin response should be immediate, the software will wait for 5 seconds. This response is not being received, your logs should show the COM port is being closed after 5 seconds.

Loopback test (tests the PC serial adapter):

Please first debug if the 2 USB serial adapters are working properly. Check your USB to Serial Adapter operation with a loopback connection. Please shunt pins 2 and 3 on your DB9 serial port side and connect your adapter only to your PC USB port. Install some terminal software (Ex: CoolTerm) on Windows 10 (Hyperterminal is no longer part of Windows), run the program, configure to 9600,N81 no flow control, turn off echo, connect, press some test keys and check if you receive the characters back to the screen. This will prove to you that your adapter and drivers are at least working.

Once this works you should try the connection with Kunkin KP184.

Don't forget the DB9 serial cable (straight through cable) should NOT cross pins 2 and 3:

2 TXD -> 2

3 RXD -> 3

5 GND -> 5 GND

Baudrate: Start with a conservative 9600 to debug de serial connection, then you can use 115200 with a short cable for lower latency.

On Kunkin: Multi-machine online mode: Offline/Slave/Host -> Use Offline
« Last Edit: May 27, 2023, 11:29:22 am by interflexo »
 
The following users thanked this post: tonyalbus, wolzlu


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf