What to Expect from the mTouch Framework
When designing with the mTouch Framework, it's important to understand the system's overall behavior. Borrowing from the Wikipedia article on software frameworks, here are the distinguishing features of a framework over a library or normal application:
- Inversion of Control
In a framework, unlike in libraries or normal user applications, the overall program's flow of control is not dictated by the caller, but by the framework.
The mTouch Framework requires the TMR0 interrupt, ADC, and a significant portion of the overall processing time. Developers do, however, have full control over the main loop of their application.
(See also: Resource Requirements)
- Default Behavior
A framework has default behavior. This default behavior must actually be some useful behavior and not a series of no-ops.
The mTouch Framework's default behavior is to perform a differential CVD scan on the sensors, perform digital filtering on the acquired signal, and decode the signal's behavior into a Yes/No press state.
- Extensibility
A framework can be extended by the user usually by selective overriding or specialized by user code providing specific functionality.
The mTouch Framework comes with a predefined mTouch_Service() function which will perform all of the decoding necessary for normal mTouch capacitive buttons. For enhanced capabilities such as sliders, wheels, proximity sensors, level sensors, and other capacitive touch uses a custom service function may be required. This simple process is explained in detail in the quick start guide.
- Non-Modifiable Framework Code
The framework code, in general, is not allowed to be modified. Users can extend the framework, but not modify its code.
The mTouch Framework is provided as an open source solution, so it is possible to edit the core acquisition code of the framework. Doing this, however, is highly discouraged and could easily impact the noise immunity of your final solution. For this reason, we consider the mTouch ISR and all include/
files as essentially non-modifiable.
Developer Resource Guides
Quick Start Guides
Use these quick start guides to get you up and running with the mTouch Framework.