Click Relay example for Hexiwear featuring Display, Touch buttons and Haptic feedback

Dependencies:   Hexi_KW40Z Hexi_OLED_SSD1351

Fork of Hexi_Click_Relay-v3_Example by Hexiwear

This project demonstrates the use of the Mikroelektronika Click Relay module with hexiwear featuring the OLED display, the Touch buttons and Haptic feedback

Plug Hexiwear into the Docking Station and the RELAY Click to the Click Socket 1
Connect the USB cable to your computer and to the micro-USB port of the Docking Station

Compile the project and copy the binary "Hexi_Click_Relay-v3_Example_HEXIWEAR.bin" in the DAP-LINK drive from your computer file explorer
Press the K64F-RESET button on the docking station to start the program on your board

The OLED screen will display two switch graphics with both relays in position OFF
Touch the left or right electrodes/buttons located below the screen to control the relay 1 or 2
Screen will update the graphics to reflect the status of the each relay either ON or OFF
Haptic motor will vibrate to acknowledge that a touch command has been received
RGB LED will briefly turn orange for Relay 1 and red for Relay 2 position change.

Committer:
GregC
Date:
Tue Sep 20 21:51:57 2016 +0000
Revision:
0:ac93d26bbdb5
Child:
1:420b0ad324f8
Click Relay example for Hexiwear featuring Display, Touch buttons and Haptic feedback

Who changed what in which revision?

UserRevisionLine numberNew contents of line
GregC 0:ac93d26bbdb5 1 /* Hexiwear NXP Bitmap Images
GregC 0:ac93d26bbdb5 2 * This file contains the bitmaps for the full screen (96 by 96 pixels) NXP logo
GregC 0:ac93d26bbdb5 3 * and a smaller 96 by 32 pixels NXP logo.
GregC 0:ac93d26bbdb5 4 *
GregC 0:ac93d26bbdb5 5 * Redistribution and use in source and binary forms, with or without modification,
GregC 0:ac93d26bbdb5 6 * are permitted provided that the following conditions are met:
GregC 0:ac93d26bbdb5 7 *
GregC 0:ac93d26bbdb5 8 * Redistributions of source code must retain the above copyright notice, this list
GregC 0:ac93d26bbdb5 9 * of conditions and the following disclaimer.
GregC 0:ac93d26bbdb5 10 *
GregC 0:ac93d26bbdb5 11 * Redistributions in binary form must reproduce the above copyright notice, this
GregC 0:ac93d26bbdb5 12 * list of conditions and the following disclaimer in the documentation and/or
GregC 0:ac93d26bbdb5 13 * other materials provided with the distribution.
GregC 0:ac93d26bbdb5 14 *
GregC 0:ac93d26bbdb5 15 * Neither the name of NXP, nor the names of its
GregC 0:ac93d26bbdb5 16 * contributors may be used to endorse or promote products derived from this
GregC 0:ac93d26bbdb5 17 * software without specific prior written permission.
GregC 0:ac93d26bbdb5 18 *
GregC 0:ac93d26bbdb5 19 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
GregC 0:ac93d26bbdb5 20 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
GregC 0:ac93d26bbdb5 21 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
GregC 0:ac93d26bbdb5 22 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
GregC 0:ac93d26bbdb5 23 * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
GregC 0:ac93d26bbdb5 24 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
GregC 0:ac93d26bbdb5 25 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
GregC 0:ac93d26bbdb5 26 * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
GregC 0:ac93d26bbdb5 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
GregC 0:ac93d26bbdb5 28 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
GregC 0:ac93d26bbdb5 29 *
GregC 0:ac93d26bbdb5 30 * visit: http://www.mikroe.com and http://www.nxp.com
GregC 0:ac93d26bbdb5 31 *
GregC 0:ac93d26bbdb5 32 * get support at: http://www.mikroe.com/forum and https://community.nxp.com
GregC 0:ac93d26bbdb5 33 *
GregC 0:ac93d26bbdb5 34 * Project HEXIWEAR, 2015
GregC 0:ac93d26bbdb5 35 */
GregC 0:ac93d26bbdb5 36
GregC 0:ac93d26bbdb5 37
GregC 0:ac93d26bbdb5 38 #include "stdint.h"
GregC 0:ac93d26bbdb5 39
GregC 0:ac93d26bbdb5 40 extern const uint8_t Relay_FF[];
GregC 0:ac93d26bbdb5 41 extern const uint8_t Relay_NN[];
GregC 0:ac93d26bbdb5 42 extern const uint8_t Relay_FN[];
GregC 0:ac93d26bbdb5 43 extern const uint8_t Relay_NF[];