single TCIP6C595 - can't get any of the 8 LEDs to come on

Like Arduino, SPI is new to me. I set up one TCIP6C595 on a breadboard with 8 LEDs and I can't get one to come on.

Checking my code (which I know needs work). I just could be me.

#include <SPI.h>


int CLOCK = 9;  // white - usually white wire on breadbaord (purple on schmatics)
int LATCH = 11; // latch - usally yellow wire on breadboard
int DATA = 12;  // data - usallly green wire on breadboard

void setup () {

  SPI.begin();

  int digitalDelay = 1000;

 
  SPI.transfer(LATCH, LOW);
  SPI.transfer(10101010);
  digitalWrite(LATCH, HIGH);    
  SPI.transfer(LATCH,HIGH); 
   
  delay(digitalDelay);

    
}

void (loop) () {
  
}

I've built the breadboard circuit 4 times. It must be the code.

SPI.transfer(LATCH, LOW);

I'm pretty sure that line isn't doing what you think it's doing.

You probably mean digitalWrite(LATCH, LOW);

The latch pin has nothing to do with SPI.transfer.

Pieter

It worked! The first LED I ever got to come on with the TOIC6C595. Been at this at least a week.

One LED came on. If I send the following, shouldn't all 8 LEDs come on?

#include <SPI.h>


int CLOCK = 9;  // white - usually white wire on breadbaord (purple on schmatics)
int LATCH = 11; // latch - usally yellow wire on breadboard
int DATA = 12;  // data - usallly green wire on breadboard

void setup () {

  SPI.begin();

  int digitalDelay = 1000;

 
  SPI.transfer(LATCH, LOW);
  SPI.transfer(0B11111111);
  digitalWrite(LATCH, HIGH);    
  digitalWrite(LATCH, LOW); 
   
  delay(digitalDelay);

    
}

void (loop) () {
  
}

Thank you for any help.

Tony

You still have one digitalWrite(LATCH, LOW) in there, replace it with digitalWrite as well. The second digitalWrite(LATCH, LOW) after writing it high is unnecessary.

  digitalWrite(LATCH, LOW);
  SPI.transfer(0b11111111);
  digitalWrite(LATCH, HIGH);

You don't have to reinvent the wheel, if you just want to control some outputs, there's many libraries that do that, for example:
https://tttapa.github.io/Arduino-Helpers/Doxygen/d9/d5f/1_8SPI-Blink_8ino-example.html
It allows you to use digitalWrite on the pins of the shift register.

I've got 4 LEDs on one side of the the IC and 4 on the other. I send B11111111, and I got six lit LEDs. Does that seem correct?

No, if you send 0b11111111, it should light all LEDs.