Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

MPLAB reset query - help needed

Status
Not open for further replies.

AlGeorge

Member level 1
Joined
Nov 17, 2009
Messages
39
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Location
Waihi Beach
Activity points
1,606
MPLAB reset query

Hi when I halt execution, then reset the MPLAB sim, variables remain the same unless the memory is cleared - thats OK. But it will never start as if the chip has just been turned on, eg PC at first line of main(), unless I make PC from here in right click menu. I can rebuild and sometimes it resets, but often just starts off from where I broke the last program execution. Seems the only way I can get simulator to start as fresh is to close MPLAB and reopen it. Any ideas pse?
 

Hi,

All you need do is Right Click in the File Registers window then select Fill Registers and simply Write the default 0x00 to all locations.
 

Thanks I should have figured that, but how to make it start by running the defines etc before starting in main. It always wants to start inside main and bypass the start code. The only way I found today is to switch the SIM off eg go to simulator, pick none, then pick SIM again.
Al.
 

Hi,

Think you are saying that when you Reset F6 within Sim instead of restarting at
ORG 000
goto START

it goes staight to

START movlw etc


If this is what you mean, well have just run Sim in various ways and it always goes back to the ORG line, however I feel sure I have previously seen it going straight to the START label instead - but cannot see any parameter that can control that - although expect there is something somewhere.

Either way I cannot see that it would not run all your set up code memory allocations etc.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top