View Single Post
Old 16 March 2016, 18:54   #11
Sephnroth
Registered User
 
Join Date: Oct 2014
Location: England
Posts: 77
matthey and alkis - thankyou both very much My program now works!

I store INTERA in an int at the start of the program and then disable the system. I start my loop, poll the hardware for a mouse click and when detected I end the loop, restore the INTERA value and end the program. It sounds so feable but I'm genuinely super excited I got my own code including asm hardware access compiling and working XD

I've used a register for restoring INTERA atm but I may switch to the stack to try and make that a habbit for compiler independence.

Incidently the true cause of my hang/failing to restore was actually in the C code, the getchar() call. If you try to getchar() whilst the sytem is disabled you get stuck forever XD moving getchar() to under restoresystem(INTERA); brought everything to life

Now to see if I can take over the display and start doing something graphical full screen.. watch this space for more of me crying into my beer begging for help from someone who knows what they are doing :P
Sephnroth is offline  
 
Page generated in 0.04172 seconds with 11 queries