News:

To visit MidNite Solar click this link www.midnitesolar.com

Main Menu

PC Mode

Started by esol, March 04, 2016, 04:10:31 PM

Previous topic - Next topic

esol

Hello Everybody,

Does anybody have more details about what "PC Mode" is?  What it does? what it can be used for? I found this option in the menu on the Kid display under the menu Multiple Units? > Communicate Mode. I am trying to get the data from the kid through the master port using an rj11 to rs232 adapter.

jamesmc

I was wondering the same thing myself.

I have been working on trying to read the data as well (firmware v1811), unsuccessfully at this point, but others here have been able to get some joy.

The brochure for the KID claims: "RS232 openly published protocols", but as far as I can find so far, the only information is from a thread post by Mario in this forum (which seems more like a hint at a work in progress).

dgd

Yes, it definitely is a work in progress
I have had some limited success in reading data from the serial master port into an arduino BUT it is really intermittent as there are  multiple read fails. I suspect some timing problems, it seems repeated reads at 56k over the rs232 port are defeating the Kid's ability to respond and perhaps the serial port buffer is getting in a mess (just guessing!).
I have spent many hours playing with this BUT have mostly given up and await the next release of Kid firmware from Mario, hopefully with some more details on data available via serial port with some examples either flowcharts or code.

dgd
Classic 250, 150,  20 140w, 6 250w PVs, 2Kw turbine, MN ac Clipper, Epanel/MNdc, Trace SW3024E (1997), Century 1050Ah 24V FLA (1999). Arduino power monitoring and web server.  Off grid since 4/2000
West Auckland, New Zealand

esol

I have been able to read in data from an arduino nano using an rj11 female to rs232 adapter that I attached to a breadboard using the rx/tx cables.  Turns out that if you set the kid to sync mode instead of PC mode, it will start reading in data. 

Robin

I will get Mario involved. We need guys on the forum to create the comms for the KID.
Robin Gudgel

dgd

Haven't heard much from Mario this year, any updates yet on  the KID firmware with data comms improvements?
The last update was a long time ago. :-\

dgd
Classic 250, 150,  20 140w, 6 250w PVs, 2Kw turbine, MN ac Clipper, Epanel/MNdc, Trace SW3024E (1997), Century 1050Ah 24V FLA (1999). Arduino power monitoring and web server.  Off grid since 4/2000
West Auckland, New Zealand

Mario

I have added code that supports PC Comm.
Check out firmware 1820 tread.

Mario

lysningen

#7
which side should I go to in order to connect to Kies PC. learn about how to connect the kid to PC
what should I use to connect the kid to PC

jamesmc

Just to confirm pin out for serial connection to KID using master jack:

DB9                  RJ11 ( Master jack in Kid CC)
5_GND     <--------> 5_GND
2_RXD-IN  <--------> 3_TX-OUT
3_TXD-OUT <--------> 4_RX-IN


This is correct?

jamesmc

Quote from: jamesmc on August 26, 2016, 05:30:38 PM
Just to confirm pin out for serial connection to KID using master jack:

DB9                  RJ11 ( Master jack in Kid CC)
5_GND     <--------> 5_GND
2_RXD-IN  <--------> 3_TX-OUT
3_TXD-OUT <--------> 4_RX-IN


This is correct?
I finally have a new KID on the bench vs an old beta.

I think the correct pinout should be:
DB9                  RJ11 ( Master jack in Kid CC)
5_GND    <--------> 5_GND
3_TX-OUT <--------> 3_TX-OUT
2_RXD-IN <--------> 4_RX-IN


Now receiving some reasonable looking data while in PC mode.

It looks like this:

131,119,,,,-53<,1.9>>.6>>.131,120,,,,-530,1,10<.4<>.
131,128,,,,-530,1,10<,48>.
131,128,,,,-530,1,1<<.4<<.
131,119,,,,-53<,1,9<>.68>.131,128,,,,-530,1,1<<.48<.
131,119,,,,-538,1,18<.4<<,
131,128.,,,-538,1,1<<.4<>.
131,120,,,,-530,1,1<>.6<>.
131,128,,,,-530,1,18<.4<>,
131,128,,,,-530,1,1<<.4<<.
131,128-,,,-538,1,1<>,48<,
131,120,,,,-530,1,1<<.48>,
131,128,,,,-530,1,18<.48<.
131,128,,,,-530,1,1<<.4<<.131,119,,,,-530,1,1<>.4<<.
131,128,,,,-530,1,1<<,4<<,131,119,,,,-530,1,1<8.4<<.
131,128,,,,-530,1,18<.48<.
131,119,,,,-538,1,1>>.6<>.
131,120,,,,-530,1,18<,4<>.
131,128,,,,-530,1,1<<.4<<.
131,128,,,,-530,1,18<,48>,
131,119,,,,-538.1.1><,6<<,131,128.,,,-538,1,1<<.4<<.


Does this look correct?

jamesmc

#10
OK I finally connected the KID to a REAL serial port and not to a USB2Serial adapter (Prolific chipset). and am now receiving correct data.

Warning:  your mileage may vary using a prolific chipset USB2Serial adapter. 

Here is what the data stream looks like with included timestamp (records arrive approx every 500 milliseconds):

R 14:56:27.24  131,119,,,,-530,1,100,400,
R 14:56:27.74  131,119,,,,-530,1,100,400,
R 14:56:28.23  131,120,,,,-530,1,100,400,
R 14:56:28.73  131,119,,,,-530,1,100,400,
R 14:56:29.23  131,120,,,,-530,1,100,400,
R 14:56:29.72  131,120,,,,-530,1,100,400,
R 14:56:30.22  131,120,,,,-530,1,100,400,
R 14:56:30.71  131,120,,,,-530,1,100,400,
R 14:56:31.21  131,120,,,,-530,1,100,400,
R 14:56:31.70  131,120,,,,-530,1,100,400,
R 14:56:32.20  131,119,,,,-530,1,100,400,
R 14:56:32.70  131,120,,,,-530,1,100,400,
R 14:56:33.19  131,120,,,,-530,1,100,400,
R 14:56:33.69  131,120,,,,-530,1,100,400,
R 14:56:34.18  131,120,,,,-530,1,100,400,

Westbranch

KID FW1811 560W >C&D 24V 900Ah AGM
CL150 29032 FW V.2126-NW2097-GP2133 175A E-Panel WBjr, 3Px4s 140W > 24V 900Ah AGM,
2 Cisco WRT54GL i/c DD-WRT Rtr, NetGr DS104Hub
Cotek ST1500 Inv  want a 24V  ROSIE Inverter
OmniCharge3024  Eu1/2/3000iGens
West Chilcotin 1680+W to come

headgeek

Quote from: jamesmc on September 09, 2016, 03:57:55 PM
OK I finally connected the KID to a REAL serial port and not to a USB2Serial adapter (Prolific chipset). and am now receiving correct data.

Warning:  your mileage may vary using a prolific chipset USB2Serial adapter. 

Here is what the data stream looks like with included timestamp (records arrive approx every 500 milliseconds):

R 14:56:27.24  131,119,,,,-530,1,100,400,
R 14:56:27.74  131,119,,,,-530,1,100,400,
R 14:56:28.23  131,120,,,,-530,1,100,400,
R 14:56:28.73  131,119,,,,-530,1,100,400,
R 14:56:29.23  131,120,,,,-530,1,100,400,
R 14:56:29.72  131,120,,,,-530,1,100,400,
R 14:56:30.22  131,120,,,,-530,1,100,400,
R 14:56:30.71  131,120,,,,-530,1,100,400,
R 14:56:31.21  131,120,,,,-530,1,100,400,
R 14:56:31.70  131,120,,,,-530,1,100,400,
R 14:56:32.20  131,119,,,,-530,1,100,400,
R 14:56:32.70  131,120,,,,-530,1,100,400,
R 14:56:33.19  131,120,,,,-530,1,100,400,
R 14:56:33.69  131,120,,,,-530,1,100,400,
R 14:56:34.18  131,120,,,,-530,1,100,400,


So - voltage to battery and voltage from panel are the second and third columns I think. Would 131 and 120 be milliamps in/out? And any guesses as to what -530,1,100,400 refers to? It should be easy to use awk and sqlite the data I just need to know what the columns are.

jamesmc

Quote from: Westbranch on September 09, 2016, 07:25:15 PM
was it the one mentioned in post #9?    http://kb1uas.com/mnsforum/index.php?topic=2794.0

It may have been, but its one that I use for all sorts of other serial devices without incident.  I should also add that my Dell XFR has a built in prolific chipset based serial port that didnt work either.  I would be surprised if it was a counterfeit one.  Anyways, I have heard that not all USB2Serial cables are created equal, and now I have learned it first hand.  Mind you I did not dig too deeply into whether different OS drivers would have made a difference. 

jamesmc

#14
Quote from: headgeek on September 10, 2016, 10:49:38 AM
Quote from: jamesmc on September 09, 2016, 03:57:55 PM
OK I finally connected the KID to a REAL serial port and not to a USB2Serial adapter (Prolific chipset). and am now receiving correct data.

Warning:  your mileage may vary using a prolific chipset USB2Serial adapter. 

Here is what the data stream looks like with included timestamp (records arrive approx every 500 milliseconds):

R 14:56:27.24  131,119,,,,-530,1,100,400,
R 14:56:27.74  131,119,,,,-530,1,100,400,
R 14:56:28.23  131,120,,,,-530,1,100,400,
R 14:56:28.73  131,119,,,,-530,1,100,400,
R 14:56:29.23  131,120,,,,-530,1,100,400,
R 14:56:29.72  131,120,,,,-530,1,100,400,
R 14:56:30.22  131,120,,,,-530,1,100,400,
R 14:56:30.71  131,120,,,,-530,1,100,400,
R 14:56:31.21  131,120,,,,-530,1,100,400,
R 14:56:31.70  131,120,,,,-530,1,100,400,
R 14:56:32.20  131,119,,,,-530,1,100,400,
R 14:56:32.70  131,120,,,,-530,1,100,400,
R 14:56:33.19  131,120,,,,-530,1,100,400,
R 14:56:33.69  131,120,,,,-530,1,100,400,
R 14:56:34.18  131,120,,,,-530,1,100,400,


So - voltage to battery and voltage from panel are the second and third columns I think. Would 131 and 120 be milliamps in/out? And any guesses as to what -530,1,100,400 refers to? It should be easy to use awk and sqlite the data I just need to know what the columns are.

The data columns are outlined in Mario's post about firmware 1820 beta:
Quote
List of what it sends in order:
   * Displayed battery voltage
   * Displayed PV Voltage
   * Displayed output watts
   * KWH
   * Amp Hours
   * Battery Temperature
   * WBJR Current
   * Battery SOC
   * WBJR Amp Hr Remaining

In the capture data I posted, the timestamp was added by me.  131 = 13.1V battery voltage, 120 = 12.0 displayed PV voltage, etc