In SX Microcontrollers, SX/B Compiler and SX-Key Tool, johncouture wrote: Using a MAX7219 with SHIFTOUT ============================= Definition: A MAX7219 is a chip that enables you to control up to eight 7 segement digits using just three pins on your mcu. (Datasheet attached). Problem: Just trying to setup a simple test where I control the 7 seg digits on the Prof Dev Board using a MAX7219. (source code attached) Setup: SX28 Prof Dev Board (PDB) MAX7219 Connections: (pin connections pg 1) RB.0 is DQ (pin 01 on 7219) RB.1 is LOAD (pin 12) RB.2 is Clk (pin 13) 7 seg displays connected (seg A-G) digit control connected (dig 0-4) power (19), ground (4,9) pull-high resistor, 10k, (18) DOUT (24) connected to an LED0 on PDB Experiment: 1) Timing Diagram (pg 6) says to set LOAD to LOW during data send and then toggle HIGH once done sending 16 bits. 2) 7219 expects 16 bit packet (see pg 6), the MSB 8 are control, LSB 8 are data. 3) Using SX/B command: SHIFTOUT DQ,Clk,MSBFirst,$03 ' to indicate Digit 3 SHIFTOUT DQ,Clk,MSBFirst,$04 ' to display a 4 Observation: 1) I observed that LED0 briefly blinks each cycle indicating that SOMETHING is coming OUT of the 7219 implying that SOMETHING must be going INTO the 7219 (I know, wishful thinking). Goal: To write a program that will read the DS1307 on the PDB and display the time on the 7 seg displays also on the PDB. SX/B has sample code for doing something similar but it runs the LEDs directly and uses many pins. The MAX7219 will only use three pins. ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=440702 Need assistance? Send an email to the Forum Administrator at forumadmin@parallax.com The Parallax Forums are powered by dotNetBB Forums, copyright 2002-2010 (http://www.dotNetBB.com)