In SX Microcontrollers, SX/B Compiler and SX-Key Tool, tdg8934 wrote: Thanks Zoot. I see what you did (change the 65 to a 128) and move the "Low ChipSel" and "Pause 1" statements outside of the loop. I think I tried this and I got a ghosting effect on both displays. I will try this again tonight. On another note, to get the ascii characters to be read in from a data statement, JonnyMac has written a routine for the RoboGames badge for scrolling 5x7 characters (not in my case 8x8). But I would still be happy to use 5x7 characters but the display needs to see 64 bytes shifted in not 35 bytes. So I modified it a little and will also try this out tonight: [code] scrollSpd = 100 ' slow SCROLL_LF "<- Left " ' scroll text [/code] [code] ' Use: SCROLL_LF [ String | Label ] ' -- scrolls ASCII message; embedded string or z-string at "Label" ' -- strings in DATA statements may contain non-printing chars (bell, cls) SUB SCROLL_LF tmpW2 = __WPARAM12 ' start of string Get_Next_Char: READINC tmpW2, tmpB1 ' get character IF tmpB1 = 0 THEN Scroll_Lf_Exit ' exit if at end of string ' handle non-printable ' IF tmpB1 < $20 THEN ' non-printable? IF tmpB1 = Bell THEN 'beepTmr = BellTm ' beeper on GOTO Get_Next_Char ' get next char ELSEIF tmpB1 = FormFeed THEN CLS GOTO Get_Next_Char ELSE tmpB1 = " " ENDIF ENDIF ' convert non-ASCII chars to space ' IF tmpB1 > 127 THEN tmpB1 = " " ENDIF ' read character map into char buffer ' tmpB1 = tmpB1 - $20 ' zero adjust tmpW3 = tmpB1 * 5 ' calc character offset FOR tmpB2 = 0 TO 4 READINC ASCII_Set + tmpW3, charBuf(tmpB2) ' read character map NEXT charBuf(5) = %00000000 ' space pad ' push character into display from right ' tmpB5 = 0 LOW ChipSel PAUSE 1 DO WHILE tmpB5 < 65 FOR tmpB2 = 0 TO 5 ' char columns + space dispBuf(8) = charBuf(tmpB2) ' get one colum from char FOR tmpB3 = 0 TO 7 ' loop through display tmpB4 = tmpB3 + 1 dispBuf(tmpB3) = dispBuf(tmpB4) ' shift display left tmpB5 = tmpB5 * color INC tmpB5 SHIFTOUT DataIn, Clock, MSBFIRST, dispBuf(tmpB3) NEXT DELAY_MS scrollSpd NEXT LOOP PAUSE 1 HIGH ChipSel GOTO Get_Next_Char ' get another character Scroll_Lf_Exit: ENDSUB [code] ' ------------------------------------------------------------------------- ' Letters, Numbers, and Symbols ' ------------------------------------------------------------------------- ASCII_Set: DATA %00000000 ' space (ASCII 32) DATA %00000000 DATA %00000000 DATA %00000000 DATA %00000000 DATA %00000000 ' ! DATA %00000000 DATA %01001111 DATA %00000000 DATA %00000000 DATA %00000000 ' " DATA %00000111 DATA %00000000 DATA %00000111 DATA %00000000 DATA %00010100 ' # DATA %01111111 DATA %00010100 DATA %01111111 DATA %00010100 DATA %00100100 ' $ DATA %00101010 DATA %01111111 DATA %00101010 DATA %00010010 DATA %00100011 ' % DATA %00010011 DATA %00001000 DATA %01100100 DATA %01100010 DATA %00110110 ' & DATA %01001001 DATA %01010101 DATA %00100010 DATA %01010000 DATA %00000000 ' ' DATA %00000101 DATA %00000011 DATA %00000000 DATA %00000000 DATA %00000000 ' ( DATA %00011100 DATA %00100010 DATA %01000001 DATA %00000000 DATA %00000000 ' ) DATA %01000001 DATA %00100010 DATA %00011100 DATA %00000000 DATA %00010100 ' * DATA %00001000 DATA %00111110 DATA %00001000 DATA %00010100 DATA %00001000 ' + DATA %00001000 DATA %00111110 DATA %00001000 DATA %00001000 DATA %00000000 ' , DATA %01010000 DATA %00110000 DATA %00000000 DATA %00000000 DATA %00001000 ' - DATA %00001000 DATA %00001000 DATA %00001000 DATA %00001000 DATA %00000000 ' . DATA %01100000 DATA %01100000 DATA %00000000 DATA %00000000 DATA %00100000 ' / DATA %00010000 DATA %00001000 DATA %00000100 DATA %00000010 DATA %00111110 ' 0 DATA %01010001 DATA %01001001 DATA %01000101 DATA %00111110 DATA %00000000 ' 1 DATA %01000010 DATA %01111111 DATA %01000000 DATA %00000000 DATA %01000010 ' 2 DATA %01100001 DATA %01010001 DATA %01001001 DATA %01000110 DATA %00100001 ' 3 DATA %01000001 DATA %01000101 DATA %01001011 DATA %00110001 DATA %00011000 ' 4 DATA %00010100 DATA %00010010 DATA %01111111 DATA %00010000 DATA %00100111 ' 5 DATA %01000101 DATA %01000101 DATA %01000101 DATA %00111001 DATA %00111100 ' 6 DATA %01001010 DATA %01001001 DATA %01001001 DATA %00110000 DATA %00000001 ' 7 DATA %01110001 DATA %00001001 DATA %00000101 DATA %00000011 DATA %00110110 ' 8 DATA %01001001 DATA %01001001 DATA %01001001 DATA %00110110 DATA %00000110 ' 9 DATA %01001001 DATA %01001001 DATA %00101001 DATA %00011110 DATA %00000000 ' : DATA %00110110 DATA %00110110 DATA %00000000 DATA %00000000 DATA %00000000 ' ; DATA %01010110 DATA %00110110 DATA %00000000 DATA %00000000 DATA %00000000 ' < DATA %00001000 DATA %00010100 DATA %00100010 DATA %01000001 DATA %00010100 ' = DATA %00010100 DATA %00010100 DATA %00010100 DATA %00010100 DATA %00000000 ' > DATA %01000001 DATA %00100010 DATA %00010100 DATA %00001000 DATA %00000010 ' ? DATA %00000001 DATA %01010001 DATA %00001001 DATA %00000110 DATA %00110010 ' @ DATA %01001001 DATA %01111001 DATA %01000001 DATA %00111110 DATA %01111110 ' A DATA %00010001 DATA %00010001 DATA %00010001 DATA %01111110 DATA %01111111 ' B DATA %01001001 DATA %01001001 DATA %01001001 DATA %00110110 DATA %00111110 ' C DATA %01000001 DATA %01000001 DATA %01000001 DATA %00100010 DATA %01111111 ' D DATA %01000001 DATA %01000001 DATA %01000001 DATA %00111110 DATA %01111111 ' E DATA %01001001 DATA %01001001 DATA %01001001 DATA %01000001 DATA %01111111 ' F DATA %00001001 DATA %00001001 DATA %00001001 DATA %00000001 DATA %00111110 ' G DATA %01000001 DATA %01001001 DATA %01001001 DATA %01111010 DATA %01111111 ' H DATA %00001000 DATA %00001000 DATA %00001000 DATA %01111111 DATA %00000000 ' I DATA %01000001 DATA %01111111 DATA %01000001 DATA %00000000 DATA %00100000 ' J DATA %01000000 DATA %01000001 DATA %00111111 DATA %00000001 DATA %01111111 ' K DATA %00001000 DATA %00010100 DATA %00100010 DATA %01000001 DATA %01111111 ' L DATA %01000000 DATA %01000000 DATA %01000000 DATA %01000000 DATA %01111111 ' M DATA %00000010 DATA %00001100 DATA %00000010 DATA %01111111 DATA %01111111 ' N DATA %00000100 DATA %00001000 DATA %00010000 DATA %01111111 DATA %00111110 ' O DATA %01000001 DATA %01000001 DATA %01000001 DATA %00111110 DATA %01111111 ' P DATA %00001001 DATA %00001001 DATA %00001001 DATA %00000110 DATA %00111110 ' Q DATA %01000001 DATA %01010001 DATA %00100001 DATA %01011110 DATA %01111111 ' R DATA %00001001 DATA %00011001 DATA %00101001 DATA %01000110 DATA %00100110 ' S DATA %01001001 DATA %01001001 DATA %01001001 DATA %00110010 DATA %00000001 ' T DATA %00000001 DATA %01111111 DATA %00000001 DATA %00000001 DATA %00111111 ' U DATA %01000000 DATA %01000000 DATA %01000000 DATA %00111111 DATA %00011111 ' V DATA %00100000 DATA %01000000 DATA %00100000 DATA %00011111 DATA %00111111 ' W DATA %01000000 DATA %00111000 DATA %01000000 DATA %00111111 DATA %01100011 ' X DATA %00010100 DATA %00001000 DATA %00010100 DATA %01100011 DATA %00000111 ' Y DATA %00001000 DATA %01110000 DATA %00001000 DATA %00000111 DATA %01100001 ' Z DATA %01010001 DATA %01001001 DATA %01000101 DATA %01000011 DATA %00000000 ' [ DATA %01111111 DATA %01000001 DATA %01000001 DATA %00000000 DATA %00000010 ' \ DATA %00000100 DATA %00001000 DATA %00010000 DATA %00100000 DATA %00000000 ' ] DATA %01000001 DATA %01000001 DATA %01111111 DATA %00000000 DATA %00000100 ' ^ DATA %00000010 DATA %00000001 DATA %00000010 DATA %00000100 DATA %01000000 ' _ (underscore) DATA %01000000 DATA %01000000 DATA %01000000 DATA %01000000 DATA %00000000 ' ` DATA %00000001 DATA %00000010 DATA %00000100 DATA %00000000 DATA %00100000 ' a DATA %01010100 DATA %01010100 DATA %01010100 DATA %01111000 DATA %01111111 ' b DATA %01001000 DATA %01000100 DATA %01000100 DATA %00111000 DATA %00111000 ' c DATA %01000100 DATA %01000100 DATA %01000100 DATA %00100000 DATA %00111000 ' d DATA %01000100 DATA %01000100 DATA %01001000 DATA %01111111 DATA %00111000 ' e DATA %01010100 DATA %01010100 DATA %01010100 DATA %00011000 DATA %00001000 ' f DATA %01111110 DATA %00001001 DATA %00000001 DATA %00000010 DATA %00001100 ' g DATA %01010010 DATA %01010010 DATA %01010010 DATA %00111110 DATA %01111111 ' h DATA %00001000 DATA %00000100 DATA %00000100 DATA %01111000 DATA %00000000 ' i DATA %01000100 DATA %01111101 DATA %01000000 DATA %00000000 DATA %00100000 ' j DATA %01000000 DATA %01000100 DATA %00111101 DATA %00000000 DATA %01111111 ' k DATA %00010000 DATA %00101000 DATA %01000100 DATA %00000000 DATA %00000000 ' l DATA %01000001 DATA %01111111 DATA %01000000 DATA %00000000 DATA %01111100 ' m DATA %00000100 DATA %00011000 DATA %00000100 DATA %01111000 DATA %01111100 ' n DATA %00001000 DATA %00000100 DATA %00000100 DATA %01111000 DATA %00111000 ' o DATA %01000100 DATA %01000100 DATA %01000100 DATA %00111000 DATA %01111100 ' p DATA %00010100 DATA %00010100 DATA %00010100 DATA %00001000 DATA %00001000 ' q DATA %00010100 DATA %00010100 DATA %00011000 DATA %01111100 DATA %01111100 ' r DATA %00001000 DATA %00000100 DATA %00000100 DATA %00001000 DATA %01001000 ' s DATA %01010100 DATA %01010100 DATA %01010100 DATA %00100000 DATA %00000100 ' t DATA %00111111 DATA %01000100 DATA %01000000 DATA %00100000 DATA %00111100 ' u DATA %01000000 DATA %01000000 DATA %00100000 DATA %01111100 DATA %00011100 ' v DATA %00100000 DATA %01000000 DATA %00100000 DATA %00011100 DATA %00111100 ' w DATA %01000000 DATA %00110000 DATA %01000000 DATA %00111100 DATA %01000100 ' x DATA %00101000 DATA %00010000 DATA %00101000 DATA %01000100 DATA %00001100 ' y DATA %01010000 DATA %01010000 DATA %01010000 DATA %00111100 DATA %01000100 ' z DATA %01100100 DATA %01010100 DATA %01001100 DATA %01000100 DATA %00000000 ' { DATA %00001000 DATA %00110110 DATA %01000001 DATA %00000000 DATA %00000000 ' | DATA %00000000 DATA %01111111 DATA %00000000 DATA %00000000 DATA %00000000 ' } DATA %01000001 DATA %00110110 DATA %00001000 DATA %00000000 DATA %00000100 ' ~ DATA %00000010 DATA %00000100 DATA %00000010 DATA %00000000 DATA %00001000 ' <- (non ASCII) DATA %00011100 DATA %00101010 DATA %00001000 DATA %00001000 [/code][/code] This way it continues loading in 5x7 ascii characters until it reaches 64 bytes and then it dumps it to the display. I don't know if this will work or not but it makes sense at the moment. I will let you all know. If it does work then I should be able to simply change the 65 to a 128 (if your original method for 2 displays works for me as well). Thanks! ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=225777#m226338 Need assistance? Send an email to the Forum Administrator at forumadmin@parallax.com The Parallax Forums are powered by dotNetBB Forums, copyright 2002-2007 (http://www.dotNetBB.com)