In SX Microcontrollers, SX/B Compiler and SX-Key Tool, VelocitąPaola wrote: Hi Peter, Thanks for your response. From what I can determine, the SX itself and the code check out. The only thing I cannot rule out for sure is the SX-Key. I do agree that it only takes a small mistake to render a whole chunk of code completely useless, though. The code snipet I posted above is taken directly from the original codebase, with only the middle sections removed to protect the content and highlight the main problem areas. As you can see, the pins were correctly declared as outputs. I do have older code versions, but they do not work either (they did in the past, however). So... I took your advice and wrote a very simple program to cycle through numbers one through nine on a button press (up or down). The result, sent via the bitXC pins, is then displayed on a seven segment LED display though the BCD encoder. The file is attached to this post... Please take note that it works flawlessly in simulation. Also, I did a little "manual datalogging" and copied the variable and pin states for various button action sequences. The down button is a little finicky because it's a cheap tactile switch and I haven't implemented any button debouncing in either the hardware or this version of the software. I attribute the jump from position 3 to 1 at the end of the log to this button. Also, I have no clue why 8 and 9 are displayed correctly. The BCD encoders have internal latches, so the correct signals must be output at some point, if only for the minimum amount of time to set the latches. Here's what I recorded: [code] Action Pos 1C 2C 3C 4C Disp X 1 1 0 0 0 1 U 2 0 0 0 0 0 U 3 1 0 0 0 1 U 4 0 0 0 0 0 U 5 1 0 0 0 1 U 6 0 0 0 0 0 U 7 1 0 0 0 1 U 8 0 0 0 0 8 U 9 1 0 0 0 9 U 9 1 0 0 0 9 D 8 0 0 0 0 8 D 7 1 0 0 0 1 D 6 0 0 0 0 0 D 5 1 0 0 0 1 D 4 0 0 0 0 0 D 3 1 0 0 0 1 D 1 1 0 0 0 1 [/code] These results are repeatable and they occur on the RB bank as well. ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=263350#m263414 Need assistance? Send an email to the Forum Administrator at forumadmin@parallax.com The Parallax Forums are powered by dotNetBB Forums, copyright 2002-2008 (http://www.dotNetBB.com)