All pins from V1 to V6
I thought it will work with V2 only
Solved ?
No I thought it was off topic so I deleted it
It didnot solve
It was!
Good move!
Pete.
#include <HardWire.h> instead of #include <Wire.h>
let me try
thanx sir
it did not work
Did you install the HardWire.h library?
yes when i included the library it is showing an error
fatal error: avr/io.h: No such file or directory
That means you have not installed the library
when i searched for the avr/io library i could not find anything😟
i read it but i cannot understand what they are saying
I created a new topic for this problem we will disscus there
It’s not Blynk related, so this is the wrong place to discuss it.
Pete.
ok sir i will delete it
Sir is this receiver code
#define BLYNK_PRINT Serial
#include <WiFi.h>
#include <WiFiClient.h>
#include <BlynkSimpleEsp32.h>
#include <Servo.h>
Servo servo1;
Servo servo2;
Servo servo3;
Servo servo4;
// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
char auth[] = "ljF4YLcyFN9P6iVeze92GsffvGwSeb2J";
// Your WiFi credentials.
// Set password to "" for open networks.
char ssid[] = "nitinpa";
char pass[] = "nitinpa1";
BLYNK_WRITE(V1){
int pindata1 = param.asInt();
}
BLYNK_WRITE(V2){
int pindata2 = param.asInt();
}
BLYNK_WRITE(V3){
int pindata3 = param.asInt();
}
BLYNK_WRITE(V4){
int pindata4 = param.asInt();
}
BLYNK_WRITE(V5){
int pindata5 = param.asInt();
}
BLYNK_WRITE(V6){
int pindata6 = param.asInt();
}
void setup(){
int cc = (V1);
int dd = (V2);
int ee = (V3);
int ff = (V4);
int gg = map(cc, 0, 255, 1000, 2000);
int hh = map(dd, 0, 255, 1000, 2000);
int ii = map(ee, 0, 255, 1000, 2000);
int jj = map(ff, 0, 255, 1000, 2000);
servo1.write(gg);
servo2.write(hh);
servo3.write(ii);
servo4.write(jj);
// Debug console
Serial.begin(9600);
Blynk.begin(auth, ssid, pass);
servo1.attach(23);
servo2.attach(22);
servo3.attach(1);
servo4.attach(3);
}
void loop()
{
Blynk.run();
}
suitable for this transmitter code
#define BLYNK_PRINT Serial
#include <WiFi.h>
#include <WiFiClient.h>
#include <BlynkSimpleEsp32.h>
#include <Blynk.h>
// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
char auth[] = "qmppE8kZmNhF8zTuaQdi__QnmIL-Dw1u";
// Your WiFi credentials.
// Set password to "" for open networks.
char ssid[] = "nitinpa";
char pass[] = "nitinpa1";
char BridgeAuth2[] = "ljF4YLcyFN9P6iVeze92GsffvGwSeb2J";
BlynkTimer timer;
WidgetBridge bridge1(V1);
WidgetBridge bridge2(V2);
void setup() {
Blynk.begin(auth, ssid, pass);
while (Blynk.connect() == false) {
}
timer.setInterval(1000L, Reading);
}
void loop()
{
Blynk.run();
timer.run();
}
void Reading(){
int A36 = analogRead(36);
int A39 = analogRead(39);
int A34 = analogRead(34);
int A35 = analogRead(35);
int A32 = digitalRead(32);
int A33 = digitalRead(33);
bridge2.virtualWrite(V1, A36);
bridge2.virtualWrite(V2, A39);
bridge2.virtualWrite(V3, A34);
bridge2.virtualWrite(V4, A35);
bridge2.virtualWrite(V5, A32);
bridge2.virtualWrite(V6, A33);
}
BLYNK_CONNECTED() {
bridge2.setAuthToken("BridgeAuth2")```
Your receiver code doesn’t do anything with the received data.
Pete.