Cannot view any readings on serial monitor

#include <ArduinoOTA.h>
#include <ESP8266WiFi.h>
#include "settingsPZEM.h"
#include <SimpleTimer.h>
#include <BlynkSimpleEsp8266.h>
#define BLYNK_PRINT Serial
#include <SoftwareSerial.h> // ( NODEMCU ESP8266 )
SoftwareSerial pzem(D5,D6); // (RX,TX) connect to TX,RX of PZEM for NodeMCU

#include <ModbusMaster.h>
ModbusMaster node;
SimpleTimer timer;

//WiFi data
char ssid[] = "DESKTOPDSTSEED"; //WiFi Credential
char pass[] = "India1234"; //WiFi Password
char server[] = "192.168.137.87"; //Blynk local server IP address
int port = 8080; //Blynk local port
#define USE_LOCAL_SERVER //Use local Blynk Server - comment-out if use Blynk hosted cloud service
#define AUTH "C6uozOKRO5k8XmEzDyiK4Ix_qtJTCCBp" //PZEM-004v3 Auth code for Blynk Local Server

int timerTask1;
double U_PR, I_PR, P_PR, PPR, PR_F, PR_PF, PR_alarm;
uint8_t result; uint16_t data[6];

void setup(){
Serial.begin(115200); Serial.println("Start serial"); pzem.begin(9600); Serial.println("Start PZEM serial");
node.begin(1, pzem); Serial.println("Start PZEM"); // 1 = ID MODBUS

WiFi.mode(WIFI_STA);
Serial.println(WiFi.localIP());
#if defined(USE_LOCAL_SERVER)
WiFi.begin(ssid, pass);
Blynk.config(AUTH, server, port);
#else
Blynk.begin(AUTH, ssid, pass);
#endif
while (Blynk.connect() == false) {}
ArduinoOTA.setHostname(OTA_HOSTNAME);
ArduinoOTA.begin();

timerTask1 = timer.setInterval(1000, updateBlynk);

}

void updateBlynk() {
Blynk.virtualWrite(vPIN_VOLTAGE, U_PR);
Blynk.virtualWrite(vPIN_CURRENT_USAGE, I_PR);
Blynk.virtualWrite(vPIN_ACTIVE_POWER, P_PR);
Blynk.virtualWrite(vPIN_ACTIVE_ENERGY, PPR);
Blynk.virtualWrite(vPIN_FREQUENCY, PR_F);
Blynk.virtualWrite(vPIN_POWER_FACTOR, PR_PF);
Blynk.virtualWrite(vPIN_OVER_POWER_ALARM, PR_alarm);
}

void loop(){
Blynk.run();
ArduinoOTA.handle();
timer.run();

result = node.readInputRegisters(0x0000, 10);
if (result == node.ku8MBSuccess) {
U_PR = (node.getResponseBuffer(0x00)/10.0f);
I_PR = (node.getResponseBuffer(0x01)/1000.000f);
P_PR = (node.getResponseBuffer(0x03)/10.0f);
PPR = (node.getResponseBuffer(0x05)/1000.0f);
PR_F = (node.getResponseBuffer(0x07)/10.0f);
PR_PF = (node.getResponseBuffer(0x08)/100.0f);
PR_alarm = (node.getResponseBuffer(0x09));
}

Serial.print("U_PR: "); Serial.println(U_PR); // V
Serial.print("I_PR: "); Serial.println(I_PR,3); // A
Serial.print("P_PR: "); Serial.println(P_PR); // W
Serial.print("PPR: "); Serial.println(PPR,3); // kWh
Serial.print("PR_F: "); Serial.println(PR_F); // Hz
Serial.print("PR_PF: "); Serial.println(PR_PF);
Serial.print("PR_alarm: "); Serial.println(PR_alarm,0);
Serial.println("====================================================");

updateBlynk();
delay(1000);
}

Is there a possibility to identify my local server ip before running the program instead of using wifi.localip()

Please edit your post and add triple backticks ( ``` ) before and after your whole sketch.

You’re using a wrong character.

Thanks for the response reposted with appropriate quotes

So are you saying that you don’t see anything in the serial monitor, or you don’t see readings from the PZEM in the serial monitor?

Is your device showing as online in the app/server, and if so are you seeing readings there?

Your void loop is a mess and you need to clean it up, and the delays have to go.

I don’t understand the question, can you elaborate?

Pete.

thanks for your response pete i have not utilized the local server ip so far
char server[] = " "; //Blynk local server IP address. in my projects
Please let me know how to identify the local server ip for my project to represent it in the code
Thanks in advance
vijay s

When you start your local server in the command window it should tell you it’s IP address.
Otherwise, scan your network using an IP scan tool to find its IP address, or check your router.

You will obviously need to make the IP address static, and do the necessary port forwarding in your router so that you can access the server via the app when outside your network.

Pete.

thanks for your response pete the
problem has been resovled