Seafoxc
Today I finished making a guide for running Fuxa with OpenPLC (on Arduino). 
Fuxa is a free web-based SCAD/HMI platform and I found it easier to use and set up as ScadaBR. 
I used a traffic light as an example (it has become my "Hello world" program for OpenPLC). 
The language I use is SFC. If you start changing the program please note the Arduino Uno 8kb RAM memory is a limitation. 

https://youtu.be/OQA5eVge0l8


Scheùatic.jpg 

I attached the program if you want to give FUXA a try. There is also an HTML that you can import to Fuxa. A big thanks @thiagoralves for the suggestion of using Fuxa. 
The next thing to edit is a Cocktailmaker I programmed using OpenPLC (on Windows) and Fuxa. 

I wish you all a cool and pleasant day (today is one of the hottest days in Belgium). 




I have no Idea what I'm doing...
Reply 7 0
thiagoralves
Awesome tutorial my friend! Small correction: Arduino Uno has 2KB of memory, not 8KB... Yeah, it is hard to believe it can even run OpenPLC Runtime in just T-W-O Kilobytes 😂
Reply 1 0
Seafoxc
Awesome tutorial my friend! Small correction: Arduino Uno has 2KB of memory, not 8KB... ðŸ˜‚
So little RAM. It would definitely not run Chrome. 
I have no Idea what I'm doing...
Reply 0 0
thiagoralves
Seafoxc wrote:
So little RAM. It would definitely not run Chrome. 

😂😂😂😂😂😂😂
Reply 0 0
boblasure
Can you tell me how to read Holding Registers in Fuxa. I am trying to read address %QW0
Reply 0 0
Seafoxc
@boblasure I'm at the moment on a holiday with no access to OpenPLC. When I get back I will look into it. If you try figure it ould yourself: you can find the Modbus addresses on the OpenPLC website. 
I have no Idea what I'm doing...
Reply 1 0
boblasure
Thanks, I am enjoying your youtube vids!
Reply 1 0
Seafoxc
I made a quick Video Tutorial on how you access Fuxa from any device that is connected to the same network and has a web browser (like a smartphone). 
This will make it possible to interact with your OpenPLC projects.  

https://youtu.be/0_s7jtbo_b4
I have no Idea what I'm doing...
Reply 1 0
Seafoxc
boblasure wrote:
Can you tell me how to read Holding Registers in Fuxa. I am trying to read address %QW0


@boblasure 

I made this small program that will increase the voltage to an LED and then decrease it with one button (Arduino Uno Pin2 %IX0.0).
OpenPLC.jpg 
So O_LEDDimming will first increase by 3276 (1/10 of the maximum value) and when you press the button the 11th time you will have an overflow to the value -29.492 but it will transform to a positive integer by the ABS function block so it will decrease until 0 (the program does not really matter here). 
I wired an LED pin to pin 9 of my Arduino Uno set-up and it works like intended. 

How to read QW0 in FUXA

Add Tag Fuxa.jpg 

Now you can see the value in Fuxa. I also added a bar chart to visualise it in a dashboard:
Editor.jpg 


I have no Idea what I'm doing...
Reply 1 0
Lamia
Is Fuxa used in production environment anywhere? I am using Ignition at the moment but it is pricey to use in production environment.

I cannot find a thorough comparison between both. Any good URL out there?
Reply 0 0
Seafoxc
I just looked at the discussion page on the Github project page.
https://github.com/frangoteam/FUXA/discussions/390

I'm pretty sure you have a lot more options using Ignition like for example Profinet and customer support hence the price tag. 
If you don't need the extra features I see no issues using it for small machines. 
Another disadvantage for a customer is the fact Ignition is used in many applications and there are many programmers that can work with it. This would make it easy to make changes in the future. 

I'm not used to working with Ignition (only experience with Sattline and Siemens PLC's) so I can not give more info on that front.


I have no Idea what I'm doing...
Reply 0 0
ygm
 
Great Tutorial,
I tried to mimic your tutorial with FUXA but I am stuck at COM port communication setting.
Where can I configure COM port parameters(Baudrate, databit, stopbit, parity) in OpenPLC.
 
I am using the same serial(USB<->Serial) between PC and MCU(PLC) to fetch modbus data.
 
[203128%2F8129370%2Fmceclip0]
 
FUXA
[203128%2F8129379%2Fmceclip0]
 
The indicator is green and yellow (taking turns) but no value display
 
[203128%2F8129381%2Fmceclip0]
 
 
Reply 0 0
thiagoralves
Configuration seems correct. OpenPLC uses 8N1 by default over Serial. If you’re using an ESP32, why not connect over WiFi?
Reply 0 0
ygm
Configuration seems correct. OpenPLC uses 8N1 by default over Serial. If you’re using an ESP32, why not connect over WiFi?
My bad.
I changed Tx pin from -1(seems default) to 1(I thought gpio1 of esp32 for serial transmit).
Now I revert setting to default and works as it should.
I will try modbus-tcp later.
 
[203128%2F8130731%2Fmceclip0]
 
 
Reply 0 0
thiagoralves
Yes, the Tx Pin is used only to control RS485 bus transmit pin. If you're not using RS485, then you must leave that at -1, which means "disabled"
Reply 2 0
Reply