Here, Oshonsoft PIC18 IDE is used. This software has a lot of peripheral that developers can use to simulate their system under Tools.

Oshonsoft to simulate PIC18 circuits Figure 1: Oshonsoft PIC18 IDE interface

The settings
1. Set the clock frequency by: double clicking on the 20MHz. Then, Figure 2 will be shown. Here, input your desired frequency and click ok.

Oshonsoft to simulate PIC18 circuits Figure 2: Setting of clock frequency of PIC18F

2. Next, set the PIC18F series to be simulated by clicking on the PIC18F series after microcontroller.

Oshonsoft to simulate PIC18 circuits Figure 3: Selecting PIC18F model

3. Before loading the program for simulation, set the speed of simulation : Rate -> Ultimate (for fastest simulation) .
4. To load the program, File -> Load Program

Oshonsoft to simulate PIC18 load programFigure 4: Simulating with different speed

5. In tools, you can bring out the peripherals you need that are in your system to simulate it virtually.

Oshonsoft to simulate PIC18 load programFigure 5: Peripheral tools and instruments that are provided

6. Options allow you to tweak the peripherals, IDE layout, and the microcontroller to meet the specification of the hardware parts that will be used.

Oshonsoft to simulate PIC18 load programFigure 6: Changing the settings for peripherals, IDE and other schemes

Example
Using PIC18F Oshonsoft IDE Simulator, a program to light up an LED at PORTD,0 when a logic 1 is detected at PORTE,1 .

Oshonsoft to simulate PIC18 load program

Figure 7: Example to detect a logic 1

 

=================================================


About

Engineering Student

Leave a Reply

Your email address will not be published. Required fields are marked *