An important part of the process of software development is debugging.With respect to applications, it is performed by means of operating in a user mode, and often integrated into the IDE.But in order to be able to debug, such as the driver, you must run the debugger core .
- - Administrator rights on the target machine.
Start shell cmd.Click on the "Start" button in the taskbar.Click on the item "Run ..." pop-up menu.In the text input box "Run", type cmd, and string, click OK.
Make a backup copy of the file boot.ini.Learn the way the current copy of Windows installation using the command: echo% SystemRoot% Go to the drive where Windows is installed by entering the letters from the device followed by a colon.Go to the root directory by using the cd.Remove the attributes "system", "read-only" and "hidden" from the boot.ini file with the command attrib, create a backup copy team and set the attributes: attrib -h -s -r boot.inicopy boot.ini boot.ini.oldattrib
+ h + s + r boot.ini
Output current list of boot options.Use the command: bootcfg / queryProsmotrite list items and find the one on which will create a new configuration with the ability to debug kernel mode .Remember the boot entry.
Create a new boot record, performing bootcfg command with the parameter / copy.Use the / id to specify the record ID to be copied.With the parameter / d set the display name of the recording.For example: bootcfg / copy / id 1 / d "Win XP (Debug)" reissue the list of boot options to the parameter of the bootcfg / query to find the ID-added record.
Include option to run the debugger and kernel boot record created in the previous step.If debugging is performed on the target machine, just add the option / debug.For example: bootcfg / debug on / id 2If planned remote debugging connecting the target machine to the host machine via the com-port additionally use the option / port / baud to specify the port number and baud rate respectively: bootcfg / debug on / port COM2 / baud9600 / id 2If remote debugging is performed with a connection through the IEEE 1394 interface (cable FireWire), use the option / dbg1394 to enable the appropriate mode and the option / ch to indicate the channel number, for example: bootcfg / dbg1394 on / ch 42 / id 2Prosmotrite boot recordsThe bootcfg command with the parameter / query and verify that the changes were made.Close the shell by typing exit.
Change, if necessary, the parameters of the operating system.Open the Control Panel, using the appropriate section of the "Setup" menu "Start".Double-click "System".In the dialog "System Properties", go to the "Advanced" tab.Click on the button "Settings", located in the "Startup and Recovery."In the displayed dialog "Startup and Recovery" activate the option "Display list of operating systems."Click the OK button in the last two open dialogue.
Restart the computer.Select the option to boot from the debugger th.Log in and work on the target machine, or start the remote debugging session.Use tools such as WinDbg and KD.
Tip 2: How to run a debugger
Object Rsl Debugger is a utility with a graphical interface.It greatly simplifies the process of creating and debugging applications Rsl-through having a set of different functions.
to activate the debugger Rsl, for this you need to make sure that the application is in debug mode macro file.If the user is working with ABS RS-Bank, it is necessary to use debug mode.To enter this mode, use the following methods.
Start a text editor, and then press F11.This will start the program execution and cause the debugger to work with the first team from the program.At the same time activates the debugger window.First given in the program guide will be for him the current instruction.
Run to perform, using the keyboard shortcut Alt + F10, at the time of execution of the program and press Ctrl + Break.This activates the debugger window.To him will be applied is the guide, which is the next after the last executed.
Insert directly in the program code command DebugBreak, then follow the launch of the program to perform with the keys Alt + F10.The program will stop execution and debugger window as the active instruction will use the action following the Debug.Also, you can call the debugger, if there are run-time errors.At this point, a dialog window containing information about the error and will be prompted to run the debugger.
Reply to this proposal positively.Current will guide, which has caused the error.In the debugger window, remove the cause of the error, and then continue with the team.This window will display the text of the program of the module, which was to activate the debugger.The module name is in the title bar, and it is current.Note that the red highlighted the current instruction.Activate a window by using Alt + O, to go in and turn on the input mode.
Install Microsoft® Windows® checked build for comfortable debugging in kernel mode.
- Adding Boot Entries