Hi
Would you please attach a chart showing the issue?
Regards
Can't get switches to work in the simulator
-
chipfryer27
- Valued Contributor
- Posts: 1813
- http://meble-kuchenne.info.pl
- Joined: Thu Dec 03, 2020 10:57 am
- Has thanked: 404 times
- Been thanked: 622 times
-
chipfryer27
- Valued Contributor
- Posts: 1813
- Joined: Thu Dec 03, 2020 10:57 am
- Has thanked: 404 times
- Been thanked: 622 times
Re: Can't get switches to work in the simulator
Hi
Attached is a very basic chart which uses an interupt to change the status of an LED.
It loops doing nothing more than displaying the status of a variable called "Flag"
Prior to the loop we set an Interrupt On Change (IOC) connected to a push button, Upon each press (rising edge) we branch to User Macro ISR and swap the state of variable "Flag"
When you press the button during simulation, you will see the status on the switch change from "Off" to "On". Releasing sets it back to "Off". When pressed the button changes colour to blue.
This is using a PIC16F1939.
If you can show a similar chart with your issue I'm sure we can assist further.
Regards
Attached is a very basic chart which uses an interupt to change the status of an LED.
It loops doing nothing more than displaying the status of a variable called "Flag"
Prior to the loop we set an Interrupt On Change (IOC) connected to a push button, Upon each press (rising edge) we branch to User Macro ISR and swap the state of variable "Flag"
When you press the button during simulation, you will see the status on the switch change from "Off" to "On". Releasing sets it back to "Off". When pressed the button changes colour to blue.
This is using a PIC16F1939.
If you can show a similar chart with your issue I'm sure we can assist further.
Regards