Blynk and Webserver on same board

Hi…
Can I configura Blynk and a webserver on the same board?
I use Arduino DUE with ethernet shield.

Hello. In general - you can. But not on Arduino DUE.

Thanks for ask!
for some reason in particular?
Can I do in Mega?

best regards

Dmitriy, others, I have seen this topic. Would this work with an Arduino Mega + Ethernet shield? Do you guys have any sample code for running Blynk and a web server in parallel?

I would be extremely thankful for help, it would enable me to “upgrade” my existing projects with Blynk.

Thanks a ton,
Matthias

You need a board with linux and at least 100mb of RAM.

@mroggi if web server is the normal meaning of the term then Mega & Ethernet shield should work. If web server means “Blynk server” then take the answer from @Dmitriy.

A basic web server can be used with a decent ESP at the same time as running as a Blynk client.

Thanks Costas for the clarification. I indeed mean the web server in the normal sense. I have some existing interface I would like to keep active in parallel to Blynk.

Could you help me with the code to use and how to coordinate between the Ethernet server and the Blynk part? Any sample code would be super helpful.

Thanks a ton,
Matthias

@mroggi Matthias whenever the word server is used on this site the natural assumption is that the reference is to our life blood, the Blynk server, so I can understand the response from @Dmitriy :slight_smile:

Saying I know it can be done doesn’t mean I have sample code for you.

I believe there are a few examples in the Projects made with Blynk section.
Tip: enter some server libraries in the search tool.

There are some basic rules you need to follow, starting with KISS (keep it simple).
You are not going to be able to run a Facebook / YouTube server at the same time as running Blynk but you can do the basics.

Keep pages sizes small and basic etc.

Take a look at the regular Blynk examples and get them working without your web server. Then try to incorporate your existing sketch around it.

Perhaps post your sketch for others to review.

Thanks, will do some experiments on the weekend and will report back.

1 Like

Ok, that was easy. I just added blynk and it worked without problems.

void setup()
{
  pinMode(4, OUTPUT);
  digitalWrite(4, HIGH);

  Ethernet.begin(mac, ip);
  server.begin();
  Blynk.begin(auth);
}
1 Like