1) Create a property aPin as a single analog pin.
It a calculation box - aPin = 1
This gives a
error. (Note that the analog pins can be used as GPIO on Arduino platform - so should be possible to set them high or low using this?) This error occurs if the default value of An -1 or the pin is 'connected'cannot assign to non-variable on left of equals
Then change aPin to be a single digital pin. (edit the property)
In calculation aPin = 1
This gives the same error - until aPin is 'connected'. This seems to be because the pin value defaults to -1 after the change in type and not to 'unconnected' - changing the connection status to unconnected or a valid pin fixes this. (Unconnected should be the default rather than -1 which FC defaults to - whatever value the property was previously set to)
2) Unrelated - but occasionally FC gets confused about com ports. For example: an arduino program is compiled to an arduino on com7 - then attempting to compile to a different arduino - FC attempts to upload to the old com port (7 in this instance) - even though the correct com port(!=7) is selected in options.
If only one com port is available then It isn't possible to correct this by selecting and reselecting com ports. One workaround is to change target and then change back to required arduino.
This seems particularly troublesome if running two copies of FC and two arduinos. Unplugging one - leaving just one connected seems to cause trouble here. Seems to be connected to the 'auto select' programming com port not changing the programming port correctly?
I'm not sure if this is just my laptop - or if there is a 'deeper' problem here....