VS Arduino | |
>> >> Digital and Analog pin Visualization improvement suggestion
https://www.visualmicro.com/forums/YaBB.pl?num=1600186626 Message started by Chris Molloy on Sep 15th, 2020 at 4:17pm |
Title: Digital and Analog pin Visualization improvement suggestion Post by Chris Molloy on Sep 15th, 2020 at 4:17pm
It would be extremely helpful if visualizations labeled the pins according to the pin definitions in the sketch.
I spend a lot of time looking to see which pin is which. Something like this #define BUTTON_PIN 0 #define OTHER_PIN 1 shows like this: |
Title: Re: Digital and Analog pin Visualization improvement suggestion Post by Visual Micro on Sep 15th, 2020 at 4:37pm
It's a nice idea but there isn't a correlation between the defines in your code and actual pins.
It just so happens you have created a define with a value of 1 and it just so happens at some place in your code you use that to read or write a digital pin. What might be an idea for us to consider if a local xml or json file where you can name your pins. Maybe there is some way to then make those definitions available to your code as #defines. That way the uncompiled and compiled sources would know the names/numbers of pins. My suggestion would be to create something like a pins.h which contains all your #defines for all pins (and no other code). Then it will be easy to read your code to find a pin number. Maybe if we can find a pins.h the debugger can read that simple code to find some names. Another idea is to use the @plot command instead of the digital pin viewer. Then you can plot only the pins you are working with using a breakpoint message with same syntax as the code: [code]@Plot.Pins.OtherPin.Red {digitalRead(#OTHER_PIN)}[/code] The @plot command shows On/Off in the charts quite clearly. |
Title: Re: Digital and Analog pin Visualization improvement suggestion Post by Chris Molloy on Sep 17th, 2020 at 3:08pm
Or make a @visualize.Pins.OtherPin {A_PIN)}
which would provide vm with the name to display for a pin number |
VS Arduino » Powered by YaBB 2.6.12! YaBB Forum Software © 2000-2024. All Rights Reserved. |