![]() |
Documentation
For Arduino users
|
#include <NexVariable.h>
Inherits NexTouch.
Public Member Functions | |
NexVariable (uint8_t pid, uint8_t cid, const char *name) | |
Constructor. More... | |
uint32_t | getText (char *buffer, uint32_t len) |
Get text attribute of component. More... | |
bool | setText (const char *buffer) |
Set text attribute of component. More... | |
uint32_t | getValue (uint32_t *number) |
Get val attribute of component. More... | |
bool | setValue (uint32_t number) |
Set val attribute of component. More... | |
![]() | |
NexTouch (uint8_t pid, uint8_t cid, const char *name) | |
Constructor. More... | |
void | attachPush (NexTouchEventCb push, void *ptr=NULL) |
Attach an callback function of push touch event. More... | |
void | detachPush (void) |
Detach an callback function. More... | |
void | attachPop (NexTouchEventCb pop, void *ptr=NULL) |
Attach an callback function of pop touch event. More... | |
void | detachPop (void) |
Detach an callback function. More... | |
![]() | |
NexObject (uint8_t pid, uint8_t cid, const char *name) | |
Constructor. More... | |
void | printObjInfo (void) |
Print current object'address, page id, component id and name. More... | |
NexButton component.
Commonly, you want to do something after push and pop it. It is recommanded that only call NexTouch::attachPop to satisfy your purpose.
Definition at line 35 of file NexVariable.h.
NexVariable::NexVariable | ( | uint8_t | pid, |
uint8_t | cid, | ||
const char * | name | ||
) |
Constructor.
pid | - page id. |
cid | - component id. |
name | - pointer to an unique name in range of all components. |
Definition at line 17 of file NexVariable.cpp.
uint32_t NexVariable::getText | ( | char * | buffer, |
uint32_t | len | ||
) |
Get text attribute of component.
buffer | - buffer storing text returned. |
len | - length of buffer. |
Definition at line 45 of file NexVariable.cpp.
uint32_t NexVariable::getValue | ( | uint32_t * | number | ) |
Get val attribute of component.
number | - buffer storing data retur |
Definition at line 22 of file NexVariable.cpp.
bool NexVariable::setText | ( | const char * | buffer | ) |
Set text attribute of component.
buffer | - text buffer terminated with '\0'. |
Definition at line 55 of file NexVariable.cpp.
bool NexVariable::setValue | ( | uint32_t | number | ) |
Set val attribute of component.
number | - To set up the data |
Definition at line 31 of file NexVariable.cpp.