In SX Microcontrollers, SX/B Compiler and SX-Key Tool, bfranke wrote: I posted this earlier, but didn't get any response. Thought I would try again. Hi, I'm a newbie to Parallax and have been doing a crash course on the SX52. I downloaded Guenther Daubach's latest SXSim but that did not seem to help my problem. I'm not sure if it is a bug in the sim, or my programming. I tend to think the latter. Anyway, the problem I'm having is this: When I load port re with my final value, I then change the port direction back to input, but on the sim, re value doesn't change. It remembers the last value it had as an output. I would think that after SXSim sees the Data Direction Register turn to input, that it would immediately check the I/O panel values for that port and plug them into that port's register. Instead, what I am finding, is that port re has the output value still in it. I don't know though, if this is a bug in SXSim or the way I'm doing things. Has anyone else seen this problem? Here is the code I have. Start mov w,#$1F mov m,w mov !re,#%00000000 ; Set port D to output direction so I can directly store in the register mov re,#%10101010 mov !re,#%11111111 ; Set port D back to input direction Main jmp Main ; In SXSim, at this point, re will still have %10101010 even though the I/O panel has all %00000000 Thanks for any help. ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=115212 Need assistance? Send an email to the Forum Administrator at forumadmin@parallax.com The Parallax Forums are powered by dotNetBB Forums, copyright 2002-2006 (http://www.dotNetBB.com)