Author Topic: Raspberry Pi & Classic 150-SL  (Read 401 times)

AxelSariel

  • Newby
  • *
  • Posts: 4
Raspberry Pi & Classic 150-SL
« on: August 12, 2021, 09:51:40 PM »
Hi! I'm new to the forum. We have two Classic 150-SL CC, and a Whizbang JR in our system. I want to access the Charge Controller's data with a Raspberry Pi for further processing. As far as I understand, SLs don't have Ethernet ports. How can I access the data in this case? I have seen other old posts talking about different methods such as Modbus but just wanted to ask in case there's any more reasonable solution at this time.

In case Modbus is the option, is there a trustable library or guide on using it? Have seen some old ones but again just in case there's any newer solutions.

Thanks!

schroew

  • Jr. Member
  • **
  • Posts: 69
Re: Raspberry Pi & Classic 150-SL
« Reply #1 on: August 12, 2021, 10:49:13 PM »
I use the Modbus to MQTT. Mosquito pulls that data down to a file for each controller and then I have logstash, elastic, Kibana. I can share configs but dashboards and stuff that I wrote won't work for you. You can certainly use the logstash config though. I haven't packaged anything but I can VPN in and SCP all the files for you.
There are a few developer people around the forum here working on this exact topic.


https://github.com/ClassicDIY/ClassicMQTT

ClassicCrazy

  • Hero Member
  • *****
  • Posts: 3010
Re: Raspberry Pi & Classic 150-SL
« Reply #2 on: August 13, 2021, 01:11:45 PM »
Hi! I'm new to the forum. We have two Classic 150-SL CC, and a Whizbang JR in our system. I want to access the Charge Controller's data with a Raspberry Pi for further processing. As far as I understand, SLs don't have Ethernet ports. How can I access the data in this case? I have seen other old posts talking about different methods such as Modbus but just wanted to ask in case there's any more reasonable solution at this time.

In case Modbus is the option, is there a trustable library or guide on using it? Have seen some old ones but again just in case there's any newer solutions.

Thanks!

You need the option on the Classic DIY  link above that uses the ESP32 to connect to Classic SL serial port and  makes it into a wireless modbus port.
https://github.com/ClassicDIY/ModbusAdapter
 Then you can use any software that uses modbus over IP like the Classic Monitoring App for android on above link, or the Midnite Local status app, or some of the others being developed in the forums here.
Here is the forum topic that talked about hooking up to Classic SL
http://midniteftp.com/forum/index.php?topic=4880.15

Larry
« Last Edit: August 13, 2021, 01:21:02 PM by ClassicCrazy »
system one
Classic 150 , 5s4p  Kyocera 135watt , 12s Soneil 2v 540amp lead crystal for 24v pack , Outback 3524 inverter
system two
Classic 150 ,5s 135 watt Kyocero , 16s Calb 100AH LiFePO4 , Outback VFX 3648 inverter
system three
Midnite KID MPPT 24 DC in to  12 volt AGM batterie

AxelSariel

  • Newby
  • *
  • Posts: 4
Re: Raspberry Pi & Classic 150-SL
« Reply #3 on: August 14, 2021, 10:27:56 PM »
Thanks so much to both! I'll check the code out and report back any progress!

ClassicCrazy

  • Hero Member
  • *****
  • Posts: 3010
Re: Raspberry Pi & Classic 150-SL
« Reply #4 on: August 14, 2021, 10:38:18 PM »
Thanks so much to both! I'll check the code out and report back any progress!

You will need to get an Esp32 and connect it to serial of your Classic SL - it is all documented on the classic diy page and in the post.

Larry
system one
Classic 150 , 5s4p  Kyocera 135watt , 12s Soneil 2v 540amp lead crystal for 24v pack , Outback 3524 inverter
system two
Classic 150 ,5s 135 watt Kyocero , 16s Calb 100AH LiFePO4 , Outback VFX 3648 inverter
system three
Midnite KID MPPT 24 DC in to  12 volt AGM batterie

AxelSariel

  • Newby
  • *
  • Posts: 4
Re: Raspberry Pi & Classic 150-SL
« Reply #5 on: August 16, 2021, 05:45:39 PM »
Thanks! I ordered all the components so hopefully next week I get it up and running.

ClassicCrazy

  • Hero Member
  • *****
  • Posts: 3010
Re: Raspberry Pi & Classic 150-SL
« Reply #6 on: August 16, 2021, 08:49:24 PM »
Let us know how it goes.

Larry
system one
Classic 150 , 5s4p  Kyocera 135watt , 12s Soneil 2v 540amp lead crystal for 24v pack , Outback 3524 inverter
system two
Classic 150 ,5s 135 watt Kyocero , 16s Calb 100AH LiFePO4 , Outback VFX 3648 inverter
system three
Midnite KID MPPT 24 DC in to  12 volt AGM batterie

AxelSariel

  • Newby
  • *
  • Posts: 4
Re: Raspberry Pi & Classic 150-SL
« Reply #7 on: August 25, 2021, 09:53:08 PM »
Reporting back progress; I got everything wired up with the rs232 ports on the controllers. I managed to flash the firmware onto the esp32 and the Midnite app connects to it. However, I’m not getting any data displayed. I get all the dials on zero, and empty settings.

Changed the Midnite USB Mode but nothing.

I checked all the wiring and it seems correct, what could it be? I tried loading the code with platformIO to debug the issue but didn’t succeed, some problem with the library linking in VS Code.

Thanks!

ClassicCrazy

  • Hero Member
  • *****
  • Posts: 3010
Re: Raspberry Pi & Classic 150-SL
« Reply #8 on: August 25, 2021, 10:17:08 PM »
I was having some of same issues - if you go back to one of those links above -  Graham had me try all kinds of things using different methods and some other softwares to debug it.
I never got mine going but the other guy who asked the question and Graham it has worked for.  Since I was trying it out on a 20 or 30 foot piece of cat5 cable to the classic I thought maybe that might have been my problem . I don't have a Classic SL so didn't really need it anyway and it was winter and cold in my shed where the Classic was so I never got back to it . I also had my Classics in Follow Me and wasn't sure if that messed with it.
What kind of rs232 to ttl converter are you using ?
You could also try hooking it up to a different jack in the Classic - oh not sure how many jacks you have on Classic SL - my regular Classic has three jacks and I think one is wired a bit different than the others.
Yeah you don't want to use the usb mode.
Look in the other post - there is are some debugging tools Graham talked about . http://midniteftp.com/forum/index.php?topic=4880.0
Larry
« Last Edit: August 25, 2021, 10:20:05 PM by ClassicCrazy »
system one
Classic 150 , 5s4p  Kyocera 135watt , 12s Soneil 2v 540amp lead crystal for 24v pack , Outback 3524 inverter
system two
Classic 150 ,5s 135 watt Kyocero , 16s Calb 100AH LiFePO4 , Outback VFX 3648 inverter
system three
Midnite KID MPPT 24 DC in to  12 volt AGM batterie

Graham

  • Sr. Member
  • ****
  • Posts: 295
    • ClassicDiy
Re: Raspberry Pi & Classic 150-SL
« Reply #9 on: August 29, 2021, 10:50:29 AM »

I checked all the wiring and it seems correct, what could it be? I tried loading the code with platformIO to debug the issue but didn’t succeed, some problem with the library linking in VS Code.

Thanks!

I noticed that one of the dependent libraries has been upgraded with breaking changes (IOTWebConf), I push an update to Platformio.ini to force it to use the original 2.3.1 version.

During my development of the adapter, I used an FTDI USB to TTL Serial Adapter  https://www.ebay.ca/itm/171907548227?hash=item28067d0443:g:puUAAOSwNSxVMjUU along with the coolterm serial port terminal https://coolterm.en.lo4d.com/windows to probe the serial data from/to the RS232 Interface Module.
I found some of the cheap RS232 Interface Modules from ebay did not work reliably, the esp would send a request but the classic would not reply...

hope this helps

Graham
Off-Grid Island cottage, Lac Simon QC Canada
370 Ahrs @ 24V (4 8L16 batteries)
4 x 250watt panels on dual axis trackers http://tinyurl.com/hfpkgr5
Classic 150, Whizbang Jr.
Android Monitor: http://tinyurl.com/lomzq3s