A shadow port is a RAM location that holds a copy of what the I/O port should be trying to drive the I/O lines to. Updates to the I/O ports should be made via the shadow port if there is a possiblity that a disasterous side effect on an I/O port can occure (an unintentional output value). The simulator knows about shadow ports and can be set to trap modifications to I/O ports that do not match the corresponding shadow port.e.g. ; this is valid BCF shadow_port_a,0 MOVFW shadow_port_a MOVWF PORTA ; this is not BCF PORTA,0