Shift Register output (e.g. 74HC595, TPIC6B595)
Moderators: grovkillen, Stuntteam, TD-er
Shift Register output (e.g. 74HC595, TPIC6B595)
Is it possible to implement support for shift registers e.g. 74HC595 or the Power Logic version TPIC6B595 or similar?
Or are there already other possibilities / tricks to connect them to ESP Easy (via rules)?
Or are there already other possibilities / tricks to connect them to ESP Easy (via rules)?
Re: Shift Register output (e.g. 74HC595, TPIC6B595)
Currently, those shift registers aren't supported in any plugin (AFAICS).
Using a lot of code, it will be possible to manipulate GPIOs in a way that the outputs go as you need, but as the rules do not have 'while' or 'for' support (yet), that is 'somewhat tricky', to say the least
Using a lot of code, it will be possible to manipulate GPIOs in a way that the outputs go as you need, but as the rules do not have 'while' or 'for' support (yet), that is 'somewhat tricky', to say the least

/Ton (PayPal.me)
Re: Shift Register output (e.g. 74HC595, TPIC6B595)
We do have the msec loop timer and you can keep track of the state in a variable.
Still "somewhat tricky" is a bit of an understatement.
Still "somewhat tricky" is a bit of an understatement.
Re: Shift Register output (e.g. 74HC595, TPIC6B595)
That's exactly why my question.Still "somewhat tricky" is a bit of an understatement.
There are solutions for everything, but the effort has to match.
ESP32 and output driver are of course also possible ...
Only for the small 8266 would the possibility of being able to use more outputs simply by means of a shift register without much effort, even with the corresponding switching capacity (6B595), enable further applications.
Re: Shift Register output (e.g. 74HC595, TPIC6B595)
Well if the max. nr. of gpio's is an issue, then an I2C port expander, like the MCP23017 (16 gpio's) or PCF8574 (8 gpio's), would be even better, as they only require 2 ESP gpio pins (SDA/SCL), where such shift register would best be controlled using 4 gpio's. And the PCF and MCP are already fully supported by ESPEasy, and multiple of these can be used, as they have easy changable addresses.
/Ton (PayPal.me)
Re: Shift Register output (e.g. 74HC595, TPIC6B595)
For cheap and simple, the PCF8574 also has disadvantages (initial state, max 20ma, ....).
I would like to switch a slightly larger number of relays and solenoid valves (100mA) with the least possible effort ...
I would like to switch a slightly larger number of relays and solenoid valves (100mA) with the least possible effort ...
Re: Shift Register output (e.g. 74HC595, TPIC6B595)
That are indeed valid arguments, I'll see if I can mock something up, but I only have evenings and weekends available for this hobby, so it may take some time.
/Ton (PayPal.me)
Re: Shift Register output (e.g. 74HC595, TPIC6B595)
You may need to check the datasheet, but most of those ICs can "sink" a lot more than they can "source".
What this means is that when it "sinks" a current, it only connects it to GND.
When it needs to "source" it, this means the IC must supply the current for the connected device, so the current for all attached to the outputs must be delivered by the Vcc pin of the IC.
Not sure what you need to switch.
If it is an AC current, you may also want to look at "SSR" or "Solid State Relay".
Then you essentially just turn on an LED on the low voltage side.
N.B. Most SSR's can only switch AC current, not DC, as they switch at the zero crossing.
Re: Shift Register output (e.g. 74HC595, TPIC6B595)
That is already clear to me, only PCF8574 is not enough for the reasons mentioned above.
I also have different test setups here, ESP32 + ULN driver, ESP8266 + PCF + inverter (because of initial state) + driver (discret and ULN), everything works.
Only ESP8266 + TPIC6B595 (+ I2C_sensor depending on the application) would be the simplest solution, but unfortunately it is not yet supported by ESP Easy.
For my intended application, I like ESP Easy best because of the flexible rules (after testing Tasmota and ESPHome), the only disadvantage is the lack of SPI function ....
I also have different test setups here, ESP32 + ULN driver, ESP8266 + PCF + inverter (because of initial state) + driver (discret and ULN), everything works.
Only ESP8266 + TPIC6B595 (+ I2C_sensor depending on the application) would be the simplest solution, but unfortunately it is not yet supported by ESP Easy.
For my intended application, I like ESP Easy best because of the flexible rules (after testing Tasmota and ESPHome), the only disadvantage is the lack of SPI function ....
Re: Shift Register output (e.g. 74HC595, TPIC6B595)
What is missing for SPI?
Re: Shift Register output (e.g. 74HC595, TPIC6B595)
as written above ... control x595 shift register via SPI ...What is missing for SPI?
Re: Shift Register output (e.g. 74HC595, TPIC6B595)
I have created PR #3917 adding support for 74HC595 (and compatible) chips to ESPEasy. Not using SPI, but the more commonly used serial-shift, as provided via the Simsso/ShiftRegister74HC595 library, that I modified to not use C++ template features, as that adds code for each count of daisy-chained chips.
Currently 'limited to 16 daisy-chained chips, but I will, probably soon, raise that to a higher count (64 or 256, not sure what would be useful).
Also want to add support for sending text to a set of 7-segment displays, similar to P073, but will need to find a diagram how these are usually connected.
Currently 'limited to 16 daisy-chained chips, but I will, probably soon, raise that to a higher count (64 or 256, not sure what would be useful).
Also want to add support for sending text to a set of 7-segment displays, similar to P073, but will need to find a diagram how these are usually connected.
/Ton (PayPal.me)
Re: Shift Register output (e.g. 74HC595, TPIC6B595)
An couple of updates have been made to the code, so a newer build is available from the Github actions run (should be completed in a couple of minutes after this post).
/Ton (PayPal.me)
Who is online
Users browsing this forum: No registered users and 14 guests