UE4Duino - Arduino to UE4 plugin Release!

I tried the same Blueprint and the same UE4 version which is the 4.7.6 on a different Pc with Windows 10 and it works correctly. It’s a lot weird…
This morning I will do other test! Thanks for support :slight_smile:

Hello,

Thank you **** for great plugin! Everything works for me in Engine ver. 4.7.6.

I’ve tested it with sending one variable all the time.
I have a question - and it is - how do you make Unreal Blueprint to read just part of serial string and use it as variable? Let’s say - I have a string like this: A102B45C000 and I would like to filter it to have three variables of 102, 45 and 000 in value. That’s why I use 3 letters to separate the data.
I hope I’ve explained my issue so it is understandable :slight_smile:

Thank you in advance for your time,

Thank you , eagerly waiting for the 4.8 solution.

Was wondering if anyone else had this problem - if I plug my Arduino into another USB port on the computer UE4 stops picking it up. I’m getting data in the serial port window of the arduino, it’s still picking it up on the same port…COM9, but in unreal…nothing. If i put the usb back in the original socket, unreal picks it back up again no problem. This makes me nervous for when I take this project outside of the studio and onto other computers…is it going to be hard to get the unreal program to pick up the arduino? anyone have experience with this? thanks again for such an amazing and much needed plugin.

Thank you for putting out this awesome plugin!

I’ve gotten it to work well on my end. I did have a question about using the write serial node. I’m trying to feed a string that updates with an event tick to the write serial node. It seems to push out a stream of data to my arduino as expected but after a few seconds or so, Unreal crashes. If I add a delay to to the stream, it lasts longer but still crashes. I tried opening and closing the serial port per tick and Unreal stabilized but performance is rough from the constant resetting of the serial port.

Do you have any tips on how to pass a constantly changing stream of data out of Unreal to my Arduino? Could it be some kind of buffer being overloaded?

Thanks in advance!

Hey all!

I apologize for it taking me so long, but I just updated the plugin and it now works in the latest engine release (4.8.2).

Just go to the first post and re-download the zip.

Let me know if anyone runs into anymore problems!

Thanks! :slight_smile:

Tested out for Android and it doesn’t work–it can’t compile an Android compatible version, I would also wonder which COM port to put since it would be connecting over Bluetooth

Just to know…
Works perfectly on Windows 7 and Unreal Engine 4.8.2 :smiley:

Good Job! Thanks :wink:

Ooops…another issue on building / exporting phase. It seems that the UE can not find the plugin. Am I the only one with this problem?
Thanks again

1bde46c4c9fd32ca3ec32068d3c77aa758816148.jpeg

Make sure it’s in a Plugins folder in your project folder and that your project type is C++

Hi, and thank you for this incredible plugin. Managed to get it running without any difficulties and its great fun.

I had one quick question and perhaps i am being stupid, but how can i control more than one variable from my arduino, ie read more than one value from the serial port or serial println command in ue4?

I would really like more than 1 button/ potentiometer controlling multiple variables inside my blueprint.

Has anybody managed to do this and have an example blueprint/arduino code they could share or point me in the right direction.

Thanks kindly
k

这个插件实在是太棒了,谢谢作者在这里的分享。不过我在使用 Read Serial的时候发现,会重复读取。
比如:
在 arduino中:我的程序
void loop() {
if(i%2==0)
{
Serial.println(“AAAAA”);
}
else
{
Serial.println(“BBBBB”);
}
i++;
delay(2000);
}
但是在UE4中 读到的数据是:
LogBlueprintUserMessages: BBBBB
LogBlueprintUserMessages: BBBBB
LogBlueprintUserMessages: BBBBB
LogBlueprintUserMessages: BBBBB
LogBlueprintUserMessages: BBBBB
LogBlueprintUserMessages: BBBBB
LogBlueprintUserMessages: BBBBB
LogBlueprintUserMessages: AAAAA
LogBlueprintUserMessages: AAAAA
LogBlueprintUserMessages: AAAAA
LogBlueprintUserMessages: AAAAA
LogBlueprintUserMessages: AAAAA
LogBlueprintUserMessages: AAAAA
LogBlueprintUserMessages: AAAAA
LogBlueprintUserMessages: AAAAA
LogBlueprintUserMessages: AAAAA

请问这个插件中,有没有处理这个问题的函数呢?

thanks i think , if i understood the code correctly this alternates between outputting one line or the other? In my example i want to use 2 or more potentionometers or switches to control different variables in arduino, eg light brightness or on or off.

How can blueprint distinguish between the different serial println commands?

Should i write a Byte from serial.write instead and interpret it in blueprint for the array value to be broken into 2 or more packets to do different things?

sorry i may be talking **** but i am very new to arduino and programming.

kindest
k

kkroosi - I’m no expert but I’m pretty sure you would just put all your readings on one line, that turns into a string in unreal and just parse the string into an array and you can use index 0 to be pot1 and index 1 to be pot2…etc. ://docs.unrealengine.com/latest/INT/BlueprintAPI/Utilities/String/ParseIntoArray/index.html

thank you so much :slight_smile:

My dad is a headmaster in a High School. He has Lego Mindstorms and Arduino for class in Robotics. I showed him this and now he wants to add Unreal Engine as a part of it XD

Great work.

I tried to convert the project into C ++, nothing to do :confused:

Lastest version seems to not be working with UE4 4.8.3
I set it to poen the port on Event BeginPlay as I did in 4.8.2 but it just doesn’t work
Nothing of significant is shown in the output log or in the blueprint editor
How much before we have a update, expecially with 4.9 coming soon?

Mine works fine in 4.8.3 although if i switch USB ports it does not work. I always have to have the arduino in the exact same USB port as when I first used it.

Also I am not able to build…I get a UE4Duino could not be found when I open the exe. Anyone able to do a successful build?

Hi, I just wanted to say how excited I was to get things up and running so quickly. It’s not perfect yet, but things are functioning. I have had success with the latest build of the plugin and Unreal 4.8.3, I’ve noticed a few other in this thread having issues.
Anyhow, everything was fairly easy to get running, but I’m experiencing about a 2 second lag between a light I turn on in engine and the LED connected to Digital Pin 1 on my Audrino. I’m pretty new to all this, so it’s more than possible I’m going about this the wrong way. As there are a few videos in this thread with good response time.

Here is the Blueprint I’m using. The setup, for testing is simple. A volume to act as the trigger, a light in game that is turned on/off and writing a serial event to the Aurdino that turns a physical LED on and off.

Here is the simple sketch I have for my Audrino board,

String input;

void setup()
{
pinMode(1,OUTPUT);
digitalWrite(1,LOW);
Serial.begin (9600);
}

void loop()
{
input = Serial.readString();
if (input == “ON”)
{
digitalWrite(1, HIGH); // turn the LED on (HIGH is the voltage level)
}
else if (input == “OFF”)
{
digitalWrite(1, LOW); // turn the LED off by making the voltage LOW
}

}