| bool NexGpio::analog_write |
( |
uint32_t |
port, |
|
|
uint32_t |
value |
|
) |
| |
writes an analog value (PWM wave) to a pin
- Parameters
-
| port | - the gpio port number |
| value | - the duty cycle: between 0 (always off) and 100 (always on). |
- Returns
- true if success, false for failure
| uint32_t NexGpio::digital_read |
( |
uint32_t |
port | ) |
|
read a high or a LOW value to a digital pin
- Parameters
-
| port | - the gpio port number |
- Returns
- the value from a specified digital pin, either high or low
| bool NexGpio::digital_write |
( |
uint32_t |
port, |
|
|
uint32_t |
value |
|
) |
| |
write a high or a LOW value to a digital pin
- Parameters
-
| port | - the gpio port number |
| mode | - the gpio port number |
- Returns
- true if success, false for failure
| uint32_t NexGpio::get_pwmfreq |
( |
uint32_t * |
number | ) |
|
read pwm output frequency
- Parameters
-
- Returns
- true if success, false for failure
| bool NexGpio::pin_mode |
( |
uint32_t |
port, |
|
|
uint32_t |
mode, |
|
|
uint32_t |
control_id |
|
) |
| |
Set gpio mode
- Parameters
-
| port | - the gpio port number |
| mode | - set gpio port mode(0–Pull on the input 1–the control input binding 2–Push-pull output 3–pwm output 4–open mode leakage) |
| control_id | - nextion controls id ,when the modeel is 1 to be valid |
- Returns
- true if success, false for failure
| bool NexGpio::set_pwmfreq |
( |
uint32_t |
value | ) |
|
writes pwm output frequency
- Parameters
-
| value | - the frequency: between 1 and 65535 |
- Returns
- true if success, false for failure
The documentation for this class was generated from the following files: