Start a new topic

response time

I want to learn about response time after get n0.val command I m using nextion 4.3 inch and baud rate 9600

 Tank you for helping

1 Comment

Nextion return code 0x71 will return a numerical get in little endian order.

Including the 32 bit value and 3byte data terminator, this is eight bytes.

Over serial N81, this is 10 bit per byte for a total of eighty bits.

At 9600 baud, 80bits /9600 max bits ~ 8.334ms +/- a little for processing.

or approximately 1/120th of a second to reply with number.

Requesting that number get n0.valÿÿÿ uses 13 bytes or 130 bits

At 9600 baud, 130/9600 max bits ~ 13.542ms +/- a little for processing.

If command pass/fail is set with bkcmd this uses 4 bytes or 40 bits to issue

At 9600 baud, 40/9600 max bits ~ 4.116ms +/- a little for processing.

The Nextion Basic Series 4.3" runs at 48MHz, the Enhanced 4.3" at 108MHz

- but what user code runs on the Nextion is largely interpreted.

- so at 9600 baud, the bottle neck will mainly be communication over serial.

To learn about timings, one usually creates experiments to time.

- perhaps setting up a timed loop to process 100 or 1000 iterations

If you were to create an HMI project with n0 Number Component then

Creating MCU code to time the task.  Using Arduino as an example


#include <Arduino.h>
#include "Nextion.h"

void setup (void) {
  uint32_t timedA, timedB, total, number;
  NexNumber n0 = NexNumber(0,1,"n0");

  timedA = millis();
  for (k=0;k<100;k++) {
  timedB = millis();
  total = timedB - timedA;
  dbSerialPrint("100 get n0.val iterations in: ");

void loop(void) {


And in this manner of experiment and observations, you learn about timings

Login or Signup to post a comment