We strongly encourage users to use Package manager for sharing their code on Libstock website, because it boosts your efficiency and leaves the end user with no room for error. [more info]
Rating:
Author: MIKROE
Last Updated: 2018-03-09
Package Version: 1.0.0.1
mikroSDK Library: 1.0.0.0
Category: Relay
Downloaded: 10281 times
Followed by: 1 user
License: MIT license
Relay click is a dual relay Click board, which can be operated by the host MCU. This Click board offers an elegant and easy solution for controlling a wide range of high power applications.
Do you want to subscribe in order to receive notifications regarding "Relay click" changes.
Do you want to unsubscribe in order to stop receiving notifications regarding "Relay click" changes.
Do you want to report abuse regarding "Relay click".
Library Description
The library offers an option to control the state of relays.
Key functions:
void relay_relay2Control( uint8_t pinState ) - Controls the Relay 2 pin.
void relay_relay1Control( uint8_t pinState ) - Controls the Relay 1 pin.
Examples Description:
The application is composed of three sections:
void applicationTask() { relay_relay2Control ( 1 ); relay_relay1Control( 1 ); mikrobus_logWrite("Relays turned on", _LOG_LINE); Delay_ms(1000); relay_relay2Control ( 0 ); relay_relay1Control( 0 ); mikrobus_logWrite("Relays turned off", _LOG_LINE); Delay_ms(1000); }
Other mikroE Libraries used in the example:
Additional notes and information
Depending on the development board you are using, you may need USB UART click, USB UART 2 click or RS232 click to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.