Shop OBEX P1 Docs P2 Docs Learn Events
Shift out with 74HC595 — Parallax Forums

Shift out with 74HC595

SabaiSabai Posts: 27
edited 2009-10-12 02:33 in BASIC Stamp
I need help, I cannot get a simple thing to work.

This is my sub to shift out.

Out_595:
DEBUG CRSRXY, 10, 2, BIN8 pattern
SHIFTOUT SerData, ClockB, MSBFIRST, [noparse][[/noparse]pattern] ' send pattern to '595
PULSOUT Latch, 5
INPUT SerData ' latch outputs
RETURN

I call the sub with this.
pattern = %00000001
GOSUB Out_595

Nothing is happening what do I do wrong here???

B

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2009-10-11 18:11
    Remember that you have to initialize "Latch" with a "LOW Latch".

    What you've posted looks like it should work. Check your connections
  • SabaiSabai Posts: 27
    edited 2009-10-11 18:18
    I change to this and it still not work.

    LOW Latch
    pattern = %00000001
    GOSUB Out_595

    If I run example 25 is it working so I guess all conections are correct.

    B
  • Mike GreenMike Green Posts: 23,101
    edited 2009-10-12 02:33
    Example 25 is for a combination of a 74HC165 for input and a 74HC595 for output. Is that what you're referring to?

    What do you mean by "working" or "not work"?

    Like I said, what you've shown looks like it should work. There must be something else you're not showing us that's not working.
Sign In or Register to comment.