Overview
With the onset of increasing energy costs, Solar Panels are an obvious route to reducing these bills.
Even with a couple of Panels in one string (two in series), and a Grid Tie Current Limiting Inverter (such as the excellent SUN-1000GTIL2 and SUN-2000GTIL2 series), you can save a LOT of money - even in Winter! More on the various cost effective options and experiences, in a later article.
LMIC
The LMIC (Linear Motor IoT Controller), fitted to two DC Linear Motors, controlling a Solar Panel Tilt mechanism. This test setup is now controlled from my Tasmota.
History
Having been working with Solar Panels and Energy Monitoring for a few moons, which led to other projects such as the GTEM and GTIE, I decided to repurpose an old project which controlled Reclining Electric Chairs and Beds called WREN. This small plug in device was designed to safely control 24V DC linear motors and plug-n-play installation.
The idea of the the LMIC project, was to take my proven WREN design, update it and allow the board to control Linear Motors outside on my panels - complete with Solar Tracking. This requirements are:
Requirements
- Flexible DC Linear Motor Controller
- Wide Input Voltage Range 10V to 38 DC (Allowing for 12V, 24V-29V PSUs)
- Built in Electrical Safety Features such as over current and temperature
- Output Motor Voltage replicates Input Voltage
- Ai-Thinker ESP12S based (ESP8266)
- Embedded Firmware which could be OTA updated
- DC Supply Pass-Through
- Output Peak Current 5.6A DC
- Paralleled Operation (increased current to a single motor)
- 5.6A DC RMS channel
- Temperature Sensor
- Onboard Buck for Regulated 3V3 (Internal Use)
- UART Flashing Port. Wemos D1 Compatible.
The LMIC Board
Now that the revised specification was pinned down, the LMIC board was designed and tested.
Safety
Looking around on the market, I could see a range of Solar Panel Linear Motor Controllers but for me, the most important aspect when energising these Linear Motors, is safety. Relay control is not what I would consider safety controlling a Linear Motor!
Linear motors have an incredible torque and with the added extremes of weather, repurposing my old WREN project was the only route to go. The DC motor driver, which has proven to be very reliable is the ST L6205 DMOS dual full bridge driver IC.
Software protection, as the primary method, proved not to be the ideal in a range of testing I did a few year back, so a dedicated hardware safety circuit was included on the board which sets a flag to a GPIO, on an alert trip. From this alert signal you can then action as needed - ideally STOP!
Example Code relating to the Hardware Safety can be found at LMIC-1_Test_Code_Bring_Up_Hardware_Test
Principle Safety Requirements:
- Protection from over current, such as jamming
- Protection from over temperature, with Thermal Shutdown
- Protection from Cross Conduction
- Under Voltage Lockout
- Robust DC Driver(s)
OLED Display
A neat feature of the board is the OLED I2C header, so you an easily connect a display directly to the board.
Other requirements
In controlling Solar Panels, a nice to have feature is not only integration into the Home Automation system, but also to maximise the sunlight light and protect from high winds. This in in effect Solar Tracking.
1) With sunlight, one could obviously measure the panel outputs but in your have a number of panel strings, then this may not be totally reliable. A solution was to add a photo transistor or diode input, into the controller.
Solar tracking works OK with the single photo diode. It would be good to average more but how far does one go. Either way, a time period needs to be added in between (dwell), so that the panels do not constantly move back and forth - stressing the linear motors unnecessarily. Some hysteresis could ideally be included in the code. All part of experimenting.
2) Controlling the panels and safely lowering in high winds, at night or other scenarios, can be via the Home Automation system and coupled with a weather station anemometer, this ticks the box.
Design
The repurposed WREN has had a facelift in design and called the LMIC (Linear Motor IoT Controller).
The L6205 has been configured to be in full parallel bridge and output to three connections.
Some changes were made to the alpha board, these being OPTO input and additional button for user control - such as manual up down, force a known state etc.
The LMIC SDK has been designed to fit into a waterproof enclosure.
Testing
The LMIC beta was connected to a panel through two Linear Motors and the result works very well. It has been in service for around an month, with integration to Domoticz .and has proven to be reliable.
AvailabilityThe LMIC board is now available with SMT complete and ready for use. The board uses 0805 components.
Code
Example code and also a new Tasmota Integration page, can be found on the GitHub.
https://github.com/DitroniX/LMIC-Linear-Motor-IoT-Controller
https://github.com/DitroniX/LMIC-Linear-Motor-IoT-Controller/wiki/LMIC-Tasmota-Integration
This Tasmota integration will currently provide:
Configure the GPIOs
- Configure the WebUI Switches for Up and Down
- Controlling the Linear Motor Outputs
- Configure the Linear Motor Controller L6205 Enable Line, EN1
- Configure the WebUI Switches for a predetermined period (~60s)
- Set Automatic Timers
- Turn ON the Linear Motor(s) at 1300 and OFF at 1800
- Allow LMIC board to be self contained and unconnected to a broker/server, if required
Future
Inclusion of Safety Flag checking:
As I use two linear motors on some of my horizontal panels (one at each end), for safety, I also plan to include something like a MPU-6050 Gyroscope / Accelerometer, to give me a 'Digital Spirit Level' (via I2C). Then if a motor ceases/jams, for example, the panels will effectively start to tilt/twist slightly and the motors will immediately STOP! (saving my panels) - well that's the theory - just need to do the code and I only have 36 hour days..
Supporting STEM
Life is one long exciting learning curve, help others by setting the seed to knowledge.
Comments