hello folks.. old fashioned Arduino UNO DIP chip .. Atmel 328P ... I tried to setup the INTERRUPTS ... using IOC PORT ...pin assignments..
but it does not work...
INTO and INT1 - seem to work... but I want other pins to be IOC selection... and when I try to set this kind of INTERRUPT - it does not work...!!
So please... can someone who knows how to fix this problem... please do it..???
It is very frustrating - when you trying to demonstrate how smart Flowcode is.. and you have a room full of engineers - who watch you trying to make stuff work... and then you have to show them... OH HELL - LOOK it does not work...!!\
OH HELL.. there goes a sale.. out the window - for matrix or flowcode.co.uk... or whomever...
Please fix it... guys... you get to the INTERRUPT setup.. you select IOC PORT ... and then try to select the pin... sothat it either interrupts - going high... / going low / or both... the little flags ... do not flip.!!! like they should to show the type of INTERRUPT .. to be set..!!
Thanks guys...
regards Lanbra .. (spencer in SA)..
arduino INTERRUPTS - IOC PORTD... do not select..
-
- Posts: 11
- http://meble-kuchenne.info.pl
- Joined: Thu Nov 24, 2022 11:55 pm
- Been thanked: 1 time
-
- Valued Contributor
- Posts: 1528
- Joined: Thu Dec 03, 2020 10:57 am
- Has thanked: 353 times
- Been thanked: 549 times
Re: arduino INTERRUPTS - IOC PORTD... do not select..
Hi
I'm not an expert on UNO.
Int0 and Int1 can be selected to trigger on various "edges" as documented in the interrupt properties.
IOC on the remaining ports do set a flag (green) which indicates a trigger on both edges (Interrupt On Change). If you set pins, close and reopen the window you will see the mask has changed to accommodate your selection.
On other chips and I suspect Uno could be the same, upon an IOC triggering you would check in your ISR for whatever action you desired (pin and level) and act accordingly.
Regards
I'm not an expert on UNO.
Int0 and Int1 can be selected to trigger on various "edges" as documented in the interrupt properties.
IOC on the remaining ports do set a flag (green) which indicates a trigger on both edges (Interrupt On Change). If you set pins, close and reopen the window you will see the mask has changed to accommodate your selection.
On other chips and I suspect Uno could be the same, upon an IOC triggering you would check in your ISR for whatever action you desired (pin and level) and act accordingly.
Regards
Re: arduino INTERRUPTS - IOC PORTD... do not select..
hello chipfryer...
Okay so I do NOT ...get the BLUE flag or the RED flag to set..!!
I consider this to be a bug.... which I bave tracked back to the days of V5 flowcode..
I wonder why flowcode..co.uk .. guys will not fix this bug...
if you know of any other way to FIX this BUG... please let me know...
Maybe MArtin knows how to fix the FCD file... or whatever..
I bet you the bug is also in FLOWCODE 10...!!!
Okay so I do NOT ...get the BLUE flag or the RED flag to set..!!
I consider this to be a bug.... which I bave tracked back to the days of V5 flowcode..
I wonder why flowcode..co.uk .. guys will not fix this bug...
if you know of any other way to FIX this BUG... please let me know...
Maybe MArtin knows how to fix the FCD file... or whatever..
I bet you the bug is also in FLOWCODE 10...!!!
-
- Valued Contributor
- Posts: 1528
- Joined: Thu Dec 03, 2020 10:57 am
- Has thanked: 353 times
- Been thanked: 549 times
Re: arduino INTERRUPTS - IOC PORTD... do not select..
Hi
My view is it is Interrupt on Change, any change, therefore it is up to you how you handle the response.
Does the datasheet specifically state that you can mask IOC to suit your specific needs? I'm not an expert on that chip but I do remember Int0/1 can be masked.
Hope this helps.
Regards
My view is it is Interrupt on Change, any change, therefore it is up to you how you handle the response.
Does the datasheet specifically state that you can mask IOC to suit your specific needs? I'm not an expert on that chip but I do remember Int0/1 can be masked.
Hope this helps.
Regards
-
- Valued Contributor
- Posts: 192
- Joined: Wed Dec 02, 2020 7:28 pm
- Has thanked: 77 times
- Been thanked: 64 times
Re: arduino INTERRUPTS - IOC PORTD... do not select…
Could you please describe exactly what you are trying to do and how you go about it? Do not assume we know what you are doing as we do not own crystal balls and having to guess what someone is doing is very frustrating.but I want other pins to be IOC selection... and when I try to set this kind of INTERRUPT - it does not work...!!
So please... can someone who knows how to fix this problem... please do it..???
It is very frustrating - when you trying to demonstrate how smart Flowcode is..
BTW, flowcode is very smart but there is no way it can implement every detail of every supported controller. So keep in mind you might need C code icons for some functions.
-
- Matrix Staff
- Posts: 1913
- Joined: Wed Dec 02, 2020 11:07 pm
- Has thanked: 619 times
- Been thanked: 644 times
Re: arduino INTERRUPTS - IOC PORTD... do not select..
Hi Lambra
I have just testing IOC on the Arduino Uno & there is nothing to fix!
Port IOC works for ports B,C and D.
You won't have a choice unless you choose a different platform
I have just testing IOC on the Arduino Uno & there is nothing to fix!
Port IOC works for ports B,C and D.
No, not a bug since with AVR it must be on both rising and falling edges or nothing, so it will be either green or off!
You won't have a choice unless you choose a different platform
We can't fix a bug that does not exist!
No, there is no bug for AVR IOC (e.g Uno) as its works as expected in FLOWCODE 10 as well!
Martin
-
- Matrix Staff
- Posts: 1465
- Joined: Sat Dec 05, 2020 10:32 am
- Has thanked: 204 times
- Been thanked: 347 times
Re: arduino INTERRUPTS - IOC PORTD... do not select..
(edit: Martin got there before me, but I will leave this reply anyway)
In Flowcode, the red and blue colours denote rising and falling edges, and the green colour denotes both. You will find that Flowcode only allows this green colour for the Arduino IOC interrupt. And, as I just stated, this is because this is the only option available on the AVR.
So we do not consider this a bug as it is not a feature of the chip itself.
However, if you wish to react to only rising (or falling) edges for this chip, then it is fairly straight-forward. Simply read the pin state within the interrupt handler code and then only process the code if the current pin state is high (or low).
IIRC, the IOC on AVRs (and therefore the Arduino Uno) works differently than on PICs. On PICs, you can select which edge (rising, falling or both) to react to. For AVRs, this option is not available and the interrupt will fire whenever the state of the pin changes (i.e. only the "both" setting is available).
In Flowcode, the red and blue colours denote rising and falling edges, and the green colour denotes both. You will find that Flowcode only allows this green colour for the Arduino IOC interrupt. And, as I just stated, this is because this is the only option available on the AVR.
So we do not consider this a bug as it is not a feature of the chip itself.
However, if you wish to react to only rising (or falling) edges for this chip, then it is fairly straight-forward. Simply read the pin state within the interrupt handler code and then only process the code if the current pin state is high (or low).