Hi Pete!
Generally, GetVal() returns the value of GPIO data register, which is kind of interface between chip’s data bus and pin. This means that this method depends on port/pin data direction: in case of input direction it returns current state of the pin, but in case of output it returns last value written to the data register, not current state of the pin (which might be for example affected by external pull-up).
However, some MCUs supports raw data registers which contains current state of the port/pin (this value is independent from the direction). If it is supported by MCU you use then by using GetRawVal() you can even read the value of the pin which is not used in GPIO function.
Component documentation can be found on Processor Expert help pages – fastest way how to get there is through right-click on component choosing Help on Component in the pop-up menu.
Regarding the grayed off GetVal() method – I guess this is because you have set the Direction property in the BitIO component as ‘Input’ – in such case the method is always generated. You can set the Direction to ‘Input/Output’ to get full control over the method generation.
The GPIO_LDD is more general component which covers whole port and its functionality whereas BitIO_LDD is simpler and focused on single pin and its usage. BitsIO component is available to support migration from projects created before LDD component were introduced. Main difference between previous high-level components (such as BitIO) and LDD ones is that LDD components are OS aware and are designed to make their integration into OS very easy.
Hope this will be helpful.
Lukas