Wifi bee MT7681 df robot mediatek

I am looking to connect to blynk using this wifibee from df robot which uses a mediatek MT 7681 chip. Here is a link to the device wifibee
I have it connected to my home network and it has an IP address. I connect the wifibee to an arduino uno using an xbee expansion shield. Is there a generic workflow for sending commands via the blynk app to this boards IP. The board seems to do the uart serial conversion much like an esp8266. I noticed there is a blynk example for the linkitone which is a similar device.

Near as I have tested… when not able to have Blynk handle the WiFi connection, and using whatever “custom” device, library, setup, that gets your Arduino connected to the internet… you should then be able to simply point Blynk.begin() to that UART and out to the defaulted Cloud Server.

e.g.

Assuming your WiFi device is connected to software serial ports 10 & 11, and preprogrammed (9600 BAUD, SSID, PASS, etc. to your WiFi AP), so that it can pass data to and from those pins, via your WiFibee <–> AP <–> Internet:

SoftwareSerial SwSerial(10, 11); // RX, TX

Then in your setup loop():

void setup()
{
  // Blynk will work through SoftwareSerial
  // Do not read or write this serial manually in your sketch
  SwSerial.begin(9600);
  Blynk.begin(SwSerial, auth);
}
1 Like

Thanks, I tried what you suggested. In the serial monitor the Blynk feedback just keeps repeating Connecting and Login Timeout. The arduino definitely has an IP address. What blynk library should I use for basic UART send/receive. I am currently trying BlynkSimpleStream.h but it doesn’t seem to connect.

Near as I can tell, that should work… as long as you have the correct hookup (and BAUD - 9600) for your software serial link to your WiFibee

Sorry just a few more questions. In the blynk app what connection type would I select. I have tried all options and still I can’t get a connection. Also do I need to use a local server to connect to the mt7681 uart. I am using a mega so I have the wifibee on Serial1. thanks, jason

I don’t think it really matters… e.g. I switched one of my projects from WiFi to USB just to test, and it didn’t make any difference in the App’s ability to connect, so it is possibly just for reference?

Your WiFibee configuration only needs to link to your local AP for network/internet connection… Are you currently running on the Cloud Server? If so, then the Blynk to Server connection is determined by something like: Blynk.begin(Serial1, auth);

But if you are using Local Server, then you probaly need this: Blynk.begin(Serial1, auth, "xxx.xxx.xxx.xxx", 8442); with all those xxx being your Local Servers IP.

.If you are using a MEGA, then take a look at this example sketch for library and setup:

When I try to insert the addition info I get no matching function for call to ‘BlynkStream::begin(HardwareSerial&, char [33], const char [13]), int’. "
Also is it best to run the device as in AP or STA. If I run as AP would I reference the devices IP or the server. Sorry for all the questions and I really appreciate your suggestions. Just to verify I know the blynk local server is working since I can use it with other devices and I know the mt7681 works as uart.

You want it as a Station (STA) so it can communicate with your WiFi Router, which is the AP.

Not sure what you mean by “it works as UART”… because if so, then it should work as you need in this case… as a WiFi to Serial adapter (between the Server, via your AP, and your MEGA’s Serial1 port)… at whatever BAUD rate they are both set for… you should be able to go as high as 115200 on the MEGA Serial1.

I had it as the STA but I just wanted to make sure so thanks for verifying that. I understand it should work since it works as uart in arduino and android app but one thing is the board defaults to port 1000 and this can’t be set in AT. Perhaps that is why I can speak to it via android app but not with Blynk. Should I change the blynk server hardware port to 1000. Also are you sure I should I be using the command you suggested - Blynk.begin(Serial1, auth, “xxx.xxx.xxx.xxx”, 8442) with BlynkSimpleStream.h library because it doesn’t seem to permit that argument. I tried many variations and it only seems to take (serial1, auth). Again thanks please hang in there I think I am close. I just got the local server working with some other boards today and I am excited to get this one working too.

Unfortunately I am completely unfamiliar with why a WiFi passthrough adapter wants to set it’s own port, or how it affects other port requirements of the data it passes… but the Blynk Server needs 8442.

I am unsure :confused:… I use a Mega with an ESP-01, so I use a different library for ESP. Perhaps just use the Cloud Server for the initial attempts to see if you can even get it to work via that WiFibee… then move onto Local Server redirection.