Makeblock-library-for-Arduino  V3.2.4
It's a library for arduino application developers
Public Member Functions | List of all members
MeTouchSensor Class Reference

Driver for Me touch sensor device. More...

#include <MeTouchSensor.h>

Inheritance diagram for MeTouchSensor:
MePort

Public Member Functions

 MeTouchSensor (void)
 
 MeTouchSensor (uint8_t port)
 
void setpin (uint8_t TogPin, uint8_t OutputPin)
 
bool touched (void)
 
void SetTogMode (uint8_t TogMode)
 
- Public Member Functions inherited from MePort
 MePort (void)
 
 MePort (uint8_t port)
 
 MePort (uint8_t port, uint8_t slot)
 
uint8_t getPort (void)
 
uint8_t getSlot (void)
 
bool dRead1 (uint8_t mode=INPUT)
 
bool dRead2 (uint8_t mode=INPUT)
 
bool dpRead1 (void)
 
bool dpRead2 (void)
 
void dWrite1 (bool value)
 
void dWrite2 (bool value)
 
int16_t aRead1 (void)
 
int16_t aRead2 (void)
 
void aWrite1 (int16_t value)
 
void aWrite2 (int16_t value)
 
void reset (uint8_t port)
 
void reset (uint8_t port, uint8_t slot)
 
uint8_t pin1 (void)
 
uint8_t pin2 (void)
 
uint8_t pin (void)
 
uint8_t pin (uint8_t port, uint8_t slot)
 

Additional Inherited Members

- Protected Attributes inherited from MePort
uint8_t s1
 
uint8_t s2
 
uint8_t _port
 
uint8_t _slot
 

Detailed Description

Driver for Me touch sensor device.

Class: MeTouchSensor

Description
Declaration of Class MeTouchSensor.
Copyright (C), 2012-2016, MakeBlock

Constructor & Destructor Documentation

MeTouchSensor::MeTouchSensor ( void  )

Alternate Constructor which can call your own function to map the touch Sensor to arduino port, no pins are used or initialized here.

Parameters
[in]None
MeTouchSensor::MeTouchSensor ( uint8_t  port)

Alternate Constructor which can call your own function to map the touch Sensor to arduino port

Parameters
[in]port- RJ25 port from PORT_1 to M2

Member Function Documentation

void MeTouchSensor::setpin ( uint8_t  TogPin,
uint8_t  OutputPin 
)
Function
setpin
Description
Reset the touch Sensor available PIN by its arduino port.
Parameters
[in]TogPin- arduino port for output type option pin(should digital pin)
[in]OutputPin- arduino port for output pin(should digital pin)
Output
None
Returns
None
Others
None
void MeTouchSensor::SetTogMode ( uint8_t  TogMode)
Function
SetTogMode
Description
Set the output type.
Parameters
[in]TogMode- 1=> Toggle mode; 0(default)=>Direct mode
Output
None
Returns
None
Others
None
bool MeTouchSensor::touched ( void  )
Function
touched
Description
Read and return the output signal.
Output
None
Returns
The output signal of touch sensor
Others
None

The documentation for this class was generated from the following files: