AdvancedHMI Software
General Category => Tips & Tricks => Topic started by: Archie on February 28, 2015, 09:18:50 AM
-
Here is how to run an AdvancedHMI application on a Raspberry Pi
1) Download the Debian Wheezy image
http://www.raspberrypi.org/downloads/
2) Copy the image to the MicroSD card using Win32DiskImager
3) Install the card and boot up the Pi
4) When it gets to the configuration screen, set it to expand the image and also to boot to a Graphical User Interface
5) Select Finish in the configuration and Reboot
6) Once booted into the GUI, open a Command Prompt
7) Type these series of commands:
sudo su
apt-get update
apt-get install mono-complete
apt-get install mono-vbnc
8 ) Put in a memory stick with an AdvancedHMI application on it
9) In the command prompt, use the "cd" command to browse to the memory stick to the directory /bin/debug
10) mono AdvancedHMI.exe
In a few seconds the application should start.
There are a few things you may run into.
- You cannot use an OPC server because it is not a .NET application
- The MessageDisplayByValue may stop the application because it uses a speech library. There is a work around. Find System.Speech.DLL on your Windows PC and copy the file into the /bin/debug directory
-
I recently received the new Raspberry Pi and it is noticeably faster. The price is the same, it is faster, has more memory, and uses the same OS, so the above configuration works exactly the same.
I'll be releasing a new version of AdvancedHMI that has some modifications to make things work better on the Pi. The will be version 3.97g or later.
-
Holy moly, I had heard of mono, but didn't realize that this was possible. I have actually been tinkering with some python code that will read/write so that I could log some data from Linux. I have a Pi at home too, I'll have to give this a go.
-
Be sure to use version 3.98 or higher because it has some changes that allow the AB drivers to work.
-
Good to know, thanks.
I've was hunting around earlier for a panel mount display to pair with this. I'm going to try to find something that does not have touch for an inexpensive information display. I notice that anything panel mount is pretty much the cost of those IVC touch PC's. Some are more expensive for just a display!
-
I found the same thing over the years with the panel mount monitor being about the same price as a full panel mount PC. I've been gathering parts up to see what is the lowest cost I can get on a 48" TV with a Pi and everything needed for a working production display. I'm also in the process of getting a panel mount case designed for a 7" display and Pi. The goal is to be able to sell a unit in the $150-$200 range for the non-harsh environment uses.
-
Cool, I like that idea. I was kind of looking for the same thing.
I understand that these types of monitors are more specialized (and not in the same demand) than the run-of-the-mill monitors we typically but but I can pick up a 50" tv as a display for half the price of some of them!
-
Check out Chalkboard Electronics]http://www.chalk-elec.com/]Chalkboard Electronics (http://www.chalk-elec.com/). Maybe I'll pick a screen up from here one of these days. It's funny, the touch enabled screens are only a few dollars more.
-
Wow! Now this is some cool stuff! I've got my new Pi already, and I'll be getting one of those touchscreens as well. Thanks guys!!
-
Wow! Now this is some cool stuff! I've got my new Pi already, and I'll be getting one of those touchscreens as well. Thanks guys!!
if/when you do pick up one of those screens, I'll be curious on what your thoughts are. I had thought about it myself.
-
I'll definitely do that. But at the moment they are out of the big ones. I just sent them a message inquiring about when they expect to have it back in, we'll see what they have to say.
-
Well, I got my touchscreen in and it consists of the bare essentials. Meaning that the glass is not in a frame, and has no protection whatsoever. I'm not even going to attempt to wire it up until I come up with something to put it in.
-
Well, I got my touchscreen in and it consists of the bare essentials. Meaning that the glass is not in a frame, and has no protection whatsoever. I'm not even going to attempt to wire it up until I come up something to put it in.
With the Tontec screen, you can also buy a case for it:
http://www.itontec.com/product-detail/product-name-9/
-
Thanks, But it's kinda small for my needs, I bought the 15.6" one... :)
I'll getto it up for the time being (using plastic cardboard comes to mind), but it's going to have to have a more permanent home.
-
http://www.itontec.com/about-us/
I love this part:
About
Keep connecting, keep simple.Tontec are primarily focused on the wireless communication technology, we aims at providing electronic products of premium quality at fair price with great customer service. Nowadays our main products are Bluetooth remote shutter, powerbanks,Bluetooth speakers;In the long run we will provide more products depending on the consumer’s demand. We devote ourselves to to make your life much simpler and more wonderful.
:)
-
Sounds like a mission statement that I have heard in the past a time or two. I prefer to get my motivation from here:
http://www.despair.com/
-
Any hope of getting OPC support?
>>- You cannot use an OPC server because it is not a .NET application
-
What about running Windows 10 on the Pi? Would that work?
Thanks
>Any hope of getting OPC support?
>>>- You cannot use an OPC server because it is not a .NET application
-
Any hope of getting OPC support?
>>- You cannot use an OPC server because it is not a .NET application
OPC is ActiveX technology based on Windows only. It won't work easily on any other OS. I'm not sure how much Windows 10 continues to support ActiveX. It is still up in the air whether Windows 10 on the Pi will be able run AdvancedHMI. All of the visual controls are based on WinForms and it looks like Windows 10 will be focused on Universal Apps.
-
Hi Archie,
I am hoping to connect use AHMI on an RPi connected to a plc communicating via ModbusRTU. I have been using this perfectly from PC and i am fairly sure my issue lies with the com port setting in the RTU Driver within AHMI. I assumed it should be /dev/ttyUSB0 which my pi is showing as location of the usb-serial i am using. Also tried /dev/ttyAMAO with a GPIO-serial adapter with no luck. I am fairly sure my serial setting are all set correctly via minicom so i dont think there is an issue there. Any suggestions would be greatly appreciated.
Zip
-
Unfortunately I do not have any good advise. I have never setup the Pi with a serial port.
-
Would Vitor's experiment provide any help:
http://advancedhmi.com/forum/index.php?topic=899.0
-
No worries Archie. I will keep trying. My PLC is recieving data sent via serial from pi so i know my connection is good. 99% sure it is just identifying the com port of the Pi in the ModbusRTU driver. On my PC COM3 etc works a treat but Pis /dev/ttyAMAO or /dev/USB0 cant be opened by AHMI. I can find my way around Pis and PLC ok but my VB skills are non existant.
@Godra
I had read through this thread previously but cannot open the link inside of the downloaded files. Ethernet communication or modbusTCP via a gateway is the next route i will explore, just trying to keep it identical to how we connect via our pc's.
Thanks for your comments!
Great forum and fantastic product Archie
-
Hi,
I have corrected the link, it was missformated, sorry.
-
If mono is similar to wine then you might try to use the same logic as described here:
http://g8ogj.org/files/Using%20USB%20serial%20ports%20under%20wine%20howwto%20ipb.pdf
I am not currently familiar with mono but it does sound like wine.
Here is another link, with a sample code to test serial port in mono (intended for Archie to compare with the AHMI code):
http://www.mono-project.com/archived/howtosystemioports/
-
According to website, the SerialToIP command line version can run in Mono and list available COM ports:
http://sourceforge.net/projects/serialtoip/?source=directory
-
Awesome guys. Sounds promising. Thanks for taking the time. I will have a crack as soon as i get back. Will let you know how i get on.
-
Hi Guys,
Still Bashing head on desk with this one.
Is it possible that the ModbusRTU driver is not recognising /dev/ttyUSB0 for the Port Name? Does it need a COM address. May be due to declining options but I feel as though Godra's suggestion of 'Linking' a COM port with /dev/ttyUSB0 would be successful, unfortunately I cant get that to work in Mono on my Pi. I am unfamiliar with wine, but from what i have googled/hunted for in my pi there is no equivalent to DOSDevices in MONO. I tried a symlink but could not get that to associate with Mono (damn my limited linux knowledge).
PLC is receiving bits through minicom (RX flashing when I push keys) and everything seems to check out with /dev/ttyUSB0 in set serial etc.
FYI i am using a USB to Serial converter into com port 1 of my PLC which runs perfectly with AHMI on Windows (port name COM1)
Tried installing UBUNTU MATE today to see if there was any change but coming up with the same 'FAILED TO OPEN /DEV/TTYUSB0"
At the moment I am trying to install QT Creator to see if I can get Qmodbus-master communicating. Does not do what I require but may help me whittle down where my issue lies. Just thought I would put this out there in the meantime.
@Vitor. Thankyou for reposting link. Unfortunately mu PLC doesnt support TCP without a gateway (as far as I can gather)
-
I would suggest you read Vitor's pdf file again.
He is using Pi, USB-RS232 adapter, ser2net software whose configuration shows /dev/ttyUSB0:
192.168.1.5:4001:raw:300/dev/ttyUSB0:19200 8DATABITS NONE 1STOPBIT
and also com0com and Serial-Tcp software on PC side.
He even mentioned using ModbusRTU device.
-
One question... You want to run AdvHMI in Linux, using Mono and a serial port?
-
Thanks Godra. Re-read Vitors post and you are correct. I must have skimmed over that before. I probably saw the IP address and immediately associated it with TCP connection. Was sifting through so much material. On the plus side learnt alot of cool stuff along the way!
Vitor. Yes i am looking at connecting my pi directly to plc via usb - serial adaptor. Am confident your method will work (prpviding i can get ser2ser etc to run ok. Will let you know of i get stuck/how i go.
Thanks again guys.
-
Here is one more link for you which shows how to create a symbolic link in Debian Linux:
http://forums.debian.net/viewtopic.php?f=16&t=61943
If your Pi has a linux and it is any similar to Debian then these commands might just work for you (you would have to follow them exactly and see if you will be getting similar responses).
-
Sorry, also to clarify, not nessessarily concerned about working with mono. Only that is what is running AHMI on Pi.
So i figured was relevant. I have a touch screen attached to pi to display AHMI comminicating with PLC via RTU. Looking forward to trying out these new suggestions tonight. As frustrating as this can be is a hell of a lot of fun!
-
Here is a new thing to try.
I have attached a GetSerial.exe file which you should copy to your Pi and run under mono, the same way you run AHMI which should be:
mono GetSerial.exe
I can only suggest you copy it to the same folder where AHMI is (or if it is on a device like USB Flash Drive or some other).
It works on MONO installed in Windows (check the attached picture) but I am not sure if it will work on Pi.
-
Thanks Godra will try that soon.
Just read a few of Vitors projects again and there is bits and pieces in there that i think i cann use to point me in the right direction. The difference being i am trying to elominate the use of a PC. I only want to use my PC to design the AHMI interface then load that interface onto the pi so i have a standalone unit consisting of pi (with touchscreen) and PLC.
-
Please let us know how that goes. Serial port on Pi is something a lot of us would be interested in.
I wonder if DF1 communication could be possible this way? This would lead to ultra cheap HMIs for really low budget projects or hobbist projects.
-
That's exactly what im aiming for. Cheap full colour stand alone HMI.
Will let you knkw how i get on.
-
Until now i tried not only with Pi but with PC´s running Debian 7 and 8 with no success. But code writen in C seems to work where in V.Basic not.
For those who want to know if the serial adapter is working here is one usefull command that list all the serial ports:
dmesg | grep -i tty
-
Still no luck.
I have a feeling modbusRTU driver would work in wine with a link between COM1 and /dev/ttyUSB0 in DOSDevices folder as Godra suggested earlier. Unfortunately i cant test that as wine wont run on pi and i have no other linux machine. Might build a virtual on windows one of these days.
Last night tried Vitors experiment connecting to plc through pi via pc using Modbus TCP driver and Ser2net on pi to link IP to ttyUSB0. Connection works (although garbled as my plc is not compatable with TCP). RxTx flashing away nicely on plc port though as soon as AHMI opened on PC.
Considering a workaround using modbustcp-rtu software on the pi. Thoughts?
Godra i tried the linux distro instructions you suggested but ourputs were significantly different. Also could not get GetSerial exe. To run. It would open briefly then close. Both GUI and Command line files did the same. May i ask the intended pupose of the GetSeriak exe? Could find a whole lot on google except for getserial errors.
-
Zip, here are a few things I need to mention/explain:
1) In linux terminal you should always start with "sudo su", provide the password and then run "mono AdvancedHMI.exe" or "mono GetSerial.exe" or "mono SerialToIPGUI.exe" or any other program
2) GetSerial.exe is a program I created to fetch all available serial ports by their friendly names (currently it works in MONO for Windows and Ubuntu linux). It is equivalent to "ls -l /dev/tty*" command mentioned on Debian page posted previously. Vitor's command "dmesg | grep -i tty" should show currently active serial ports.
3) I just tried running SerialToIPGUI program in MONO on Ubuntu linux and this program runs as well and lists all available serial ports. Its advantage is that it has graphical user interface and runs as either a Server or a Client connecting serial port to ethernet.
If Archie could provide an option within any driver to tunnel its packets through 127.0.0.1 then, by using the SerialToIP program, the Pi could be used as standalone option for HMI (if there is no other solution of course).
@Sprungmonkey
When I use DF1 driver alone in AHMI project and start it in MONO on Ubuntu, the attached exceptions occur and the AHMI screen closes.
Don't get any of that if using ModbusRTU or EthernetIPforPLCSLCMicro drivers.
Didn't get it with older version of AHMI either (v3.84) with DF1 driver.
-
Last night tried Vitors experiment connecting to plc through pi via pc using Modbus TCP driver and Ser2net on pi to link IP to ttyUSB0. Connection works (although garbled as my plc is not compatable with TCP). RxTx flashing away nicely on plc port though as soon as AHMI opened on PC.
Considering a workaround using modbustcp-rtu software on the pi. Thoughts?
In the same topic for Vitor's experiment I posted the experiment with 2 PCs. That setup enabled usage of DF1 driver and should do the same for the ModbusRTU driver.
You would just have to use com0com and SerialToIP programs on the PC to be able to use ModbusRTU driver and leave the Pi configured as Vitor proposed.
-
Archie,
The SerialToIP software, when started with MONO on Ubuntu, doesn't have any issues with detecting and opening /dev/ttyUSB0 port. In the code, the author is not using anything special but SerialPort.GetPortNames() and SerialPort.Open() commands.
Is it possible that AHMI is specifically looking for string that starts with "COM" word?
-
I checked through the code and there is nothing restricting the name of the serial port. It defaults to COM1, but after it changes the property name, it pushes it directly to the serial port component:
SerialPort.PortName = m_PortName
-
I forgot to mention that the SerialToIPGUI version that I am running with MONO was actually converted to VB Net and compiled as exe program.
So this issue doesn't seem to have anything to do with VB Net itself or the mono-vbnc.
Could it be a part of AHMI dll that is causing this issue?
Which class is specifically opening the COM port for DF1 driver to send packet (currently I am testing DF1driver until I figure some other approach/driver)?
-
Here is the function that opens the COM port for the DF1 driver if you wanted to try to test it in a stand alone application:
'*********************************
'* Open Serial Port
'*********************************
Public Function OpenConnection() As Integer
'*****************************************
'* Open serial port if not already opened
'*****************************************
If Not SerialPort.IsOpen Then
If m_BaudRate > 0 Then
Try
SerialPort.PortName = m_ComPort
If m_BaudRate = 0 Then
DetectComSettings()
Else
SerialPort.BaudRate = m_BaudRate
SerialPort.Parity = m_Parity
End If
'* Calculate how long to wait based on baud rate
MaxWaitTicks = Convert.ToInt32(19200 * 100 / m_BaudRate)
SerialPort.ReceivedBytesThreshold = 1
SerialPort.Open()
Catch ex As Exception
If SerialPort.IsOpen Then CloseConnection()
Return -9
'Throw New MfgControl.AdvancedHMI.Drivers.PLCDriverException("Failed To Open " & SerialPort.PortName & ". " & ex.Message)
End Try
Else
Dim result As Integer = DetectComSettings()
If result <> 0 Then
'Throw New MfgControl.AdvancedHMI.Drivers.PLCDriverException("Could Not Auto Connect")
If SerialPort.IsOpen Then CloseConnection()
End If
Return result
End If
End If
Return 0
End Function
-
I used older AHMI v3.84 to test this, modified your code to this and placed the call inside WaitForResponse sub of the DF1Comm driver:
'*********************************
'* Open Serial Port
'*********************************
Public Function OpenConnection() As Integer
'*****************************************
'* Open serial port if not already opened
'*****************************************
Dim SerialPort As New IO.Ports.SerialPort
If Not SerialPort.IsOpen Then
If CDbl(m_BaudRate) > 0 Then
Try
SerialPort.PortName = m_ComPort
If CDbl(m_BaudRate) = 0 Then
DetectCommSettings()
Else
SerialPort.BaudRate = CInt(m_BaudRate)
SerialPort.Parity = m_Parity
End If
'* Calculate how long to wait based on baud rate
MaxTicks = Convert.ToInt32(19200 * 100 / CDbl(m_BaudRate))
SerialPort.ReceivedBytesThreshold = 1
SerialPort.Open()
MsgBox("Serial port opened")
Catch ex As Exception
If SerialPort.IsOpen Then SerialPort.Close()
Throw New MfgControl.AdvancedHMI.Drivers.Common.PLCDriverException("Failed To Open " & SerialPort.PortName & ". " & ex.Message)
Return -9
'Throw New MfgControl.AdvancedHMI.Drivers.PLCDriverException("Failed To Open " & SerialPort.PortName & ". " & ex.Message)
End Try
Else
Dim result As Integer = DetectCommSettings()
If result <> 0 Then
'Throw New MfgControl.AdvancedHMI.Drivers.PLCDriverException("Could Not Auto Connect")
If SerialPort.IsOpen Then SerialPort.Close()
End If
Return result
End If
End If
Return 0
End Function
When I run it on a Windows PC then I get this error (see the attached picture):
Comm Error -1.Failed To Open /dev/ttyUSB0. The given port name does not start with COM/com or does not resolve to a valid serial port. Parameter name: portName.
The same program run on Ubuntu PC gives this error (see the attached picture):
Comm Error -1.Failed To Open /dev/ttyUSB0. The requested feature is not implemented.
Another successful attempt was to place a ListBox on the form and place this code (the ports did open and close properly):
Private mySerial As New SerialPort
Private Sub MainForm_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
listBoxSerialPorts.Items.Clear()
Dim portnames As String() = SerialPort.GetPortNames()
If portnames.Length = 0 Then
Me.listBoxSerialPorts.Items.Add("error: none available!")
listBoxSerialPorts.ForeColor = Color.Red
Else
listBoxSerialPorts.ForeColor = Color.Black
For Each sPort As String In portnames
Me.listBoxSerialPorts.Items.Add(sPort)
Next
If listBoxSerialPorts.Items.Count >= 1 Then
listBoxSerialPorts.Sorted = True
End If
End If
End Sub
Private Sub listBoxSerialPorts_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles listBoxSerialPorts.SelectedIndexChanged
If mySerial.IsOpen Then
mySerial.Close()
MsgBox("Serial Port " & mySerial.PortName & " closed.")
End If
mySerial.PortName = Me.listBoxSerialPorts.SelectedItem
mySerial.BaudRate = 38400
mySerial.DataBits = 8
mySerial.Parity = Parity.None
mySerial.StopBits = 2
mySerial.Open()
If mySerial.IsOpen Then MsgBox("Serial Port " & mySerial.PortName & " opened.")
End Sub
Private Sub MainForm_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
If mySerial.IsOpen Then
mySerial.Close()
MsgBox("Serial Port " & mySerial.PortName & " closed.")
End If
End Sub
Since I used older AHMI version for these tests, I can only suggest that you check that parameter portName as the first error suggested (if it is applicable in the current version).
-
Archie,
I am using MONO 3.2.8 on Ubuntu and it doesn't seem to like the line: SerialPort.ReceivedBytesThreshold.
That feature doesn't seem to be implemented.
Could you possibly comment it out and post a patched dll?
What I did find out is that if I copy debug folder to Home directory and run "mono AdvancedHMI.exe" directly from there instead of USB drive then the program seems to be trying to do something with the port (some "Win32 IO returned 25" errors disappeared but the program might be stuck on the above mentioned unsupported feature).
-
That is the same error message that i have been getting.
-
Maybe a separate MONO edition of AHMI could be created that would eliminate those features not implemented.
It all depends on how much work it would create for Archie.
-
Hi Godra,
Please Excuse my lack of VB Coding Knowledge but I have been trying to find the sections of code where you modified the "Open Serial Port" commands and I cant find them anywhere in the Advanced HMI files. Am I missing something? Was hoping to replicate your successful attempt at getting the com port open. Could it be that the code is different in V3.98t to the v3.84 that you modified? Or am I looking in the wrong places? Browsed through all .vb files in the advanced HMI folder looking for "open serial port" and "WaitForResponse" but didnt come across anything. Apologies if this is a really basic Noob question.
zip
-
The code to open the serial port is actually a part of the dll file (which you cannot access).
Archie took it out and posted it in this topic so I could perform some testing.
I can only suggest to be patient and wait for Archie to possibly modify the code so it would work with serial ports on Pi.
-
Thanks Godra. I had a feeling that was the case. Thank you for confirming.
-
Are there any news about Ahmi on the Raspberry with USB to Serial Adapter and Modbus RTU?
-
Push
-
Are there any news about Ahmi on the Raspberry with USB to Serial Adapter and Modbus RTU?
Internally we do very little development and testing with the Pi since it has almost no commercial applications for us, so unfortunately it is a very low priority. You may have better response on this by posing the question to a Raspberry Pi or Linux specific forum.
My guess is that it has something to do with Mono address serial ports in Linux versus the common Windows style of COMx:
-
Quick update. Still no luck with modbus rtu but the brand of plc i use has just bought out an ethernet based model.
I was able to connect direct to the plc via ethernet port of raspberry pi for cheap standalone touchscreen hmi. Exactly what i needed! Thanks for all the help guys!
-
Hello,
I juste made a little interface (2 buttons and a login page) to test it with my raspberry Pi. The goal is to implement a full HMI working in modbus TCP with a PLC.
But then when I try to run it, after 2 secondes AvcancedHMI.exe crashes.
Here is the error I get in the console :
* Assertion at mini-codegen.c:807, condition `i == sel' not met
Stacktrace:
at <unknown> <0xffffffff>
at System.Windows.Forms.TextBoxBase.Draw (System.Drawing.Graphics,System.Drawing.Rectangle) <0x000ab>
at System.Windows.Forms.TextBoxBase.OnPaintInternal (System.Windows.Forms.PaintEventArgs) <0x00063>
at System.Windows.Forms.Control.WmPaint (System.Windows.Forms.Message&) <0x0017f>
at System.Windows.Forms.Control.WndProc (System.Windows.Forms.Message&) <0x00217>
at System.Windows.Forms.TextBoxBase.WndProc (System.Windows.Forms.Message&) <0x00313>
at System.Windows.Forms.TextBox.WndProc (System.Windows.Forms.Message&) <0x001d3>
at System.Windows.Forms.Control/ControlWindowTarget.OnMessage (System.Windows.Forms.Message&) <0x0002b>
at System.Windows.Forms.Control/ControlNativeWindow.WndProc (System.Windows.Forms.Message&) <0x0003b>
at System.Windows.Forms.NativeWindow.WndProc (intptr,System.Windows.Forms.Msg,intptr,intptr) <0x002b7>
at System.Windows.Forms.XplatUIX11.DispatchMessage (System.Windows.Forms.MSG&) <0x00023>
at System.Windows.Forms.XplatUI.DispatchMessage (System.Windows.Forms.MSG&) <0x0002b>
at System.Windows.Forms.Application.RunLoop (bool,System.Windows.Forms.ApplicationContext) <0x00ac7>
at System.Windows.Forms.Application.Run (System.Windows.Forms.ApplicationContext) <0x0005f>
at System.Windows.Forms.Application.Run (System.Windows.Forms.Form) <0x0002b>
at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.OnRun () <0x00083>
at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.Run (string[]) <0x00023>
at MfgControl.AdvancedHMI.My.MyApplication.Main (string[]) <0x0003f>
at (wrapper runtime-invoke) <Module>.runtime_invoke_void_object (object,intptr,intptr,intptr) <0xffffffff>
Native stacktrace:
Debug info from gdb:
[New LWP 11418]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
0x76e3bee8 in __libc_waitpid (Cannot access memory at address 0x3
pid=11419, stat_loc=0x7efa8d10, options=0) at ../sysdeps/unix/sysv/linux/waitpid.c:40
40 ../sysdeps/unix/sysv/linux/waitpid.c: No such file or directory.
Id Target Id Frame
2 Thread 0x75bff430 (LWP 11418) "mono" 0x76e39a40 in do_futex_wait (isem=isem@entry=0x3181a4) at ../nptl/sysdeps/unix/sysv/linux/sem_wait.c:48
* 1 Thread 0x76f4a000 (LWP 11417) "mono" 0x76e3bee8 in __libc_waitpid (Cannot access memory at address 0x3
pid=11419, stat_loc=0x7efa8d10, options=0) at ../sysdeps/unix/sysv/linux/waitpid.c:40
Thread 2 (Thread 0x75bff430 (LWP 11418)):
#0 0x76e39a40 in do_futex_wait (isem=isem@entry=0x3181a4) at ../nptl/sysdeps/unix/sysv/linux/sem_wait.c:48
#1 0x76e39af4 in __new_sem_wait (sem=0x3181a4) at ../nptl/sysdeps/unix/sysv/linux/sem_wait.c:69
#2 0x00219f98 in mono_sem_wait ()
#3 0x0019091c in ?? ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Thread 1 (Thread 0x76f4a000 (LWP 11417)):
Cannot access memory at address 0x3
#0 0x76e3bee8 in __libc_waitpid (pid=11419, stat_loc=0x7efa8d10, options=0) at ../sysdeps/unix/sysv/linux/waitpid.c:40
#1 0x000c0ba4 in ?? ()
Cannot access memory at address 0x3
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
=================================================================
Got a SIGABRT while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
=================================================================
Aborted
Any idea ?
If needed I can provide my project.
I put the 3 folders in my USBkey (AdvancedHMI, AdvancedHMIControls, AdvancedHMIDrivers) and the project file.
Then I run : sudo mono AdvancedHMI.exe from AdvancedHMI/bin/debug/.
My project includes the modbus TCP driver (but unused), a SQL database for the login page and... nothing else special.
-
Hello,
I juste made a little interface (2 buttons and a login page) to test it with my raspberry Pi. The goal is to implement a full HMI working in modbus TCP with a PLC.
But then when I try to run it, after 2 secondes AvcancedHMI.exe crashes.
Here is the error I get in the console :
* Assertion at mini-codegen.c:807, condition `i == sel' not met
Stacktrace:
at <unknown> <0xffffffff>
at System.Windows.Forms.TextBoxBase.Draw (System.Drawing.Graphics,System.Drawing.Rectangle) <0x000ab>
at System.Windows.Forms.TextBoxBase.OnPaintInternal (System.Windows.Forms.PaintEventArgs)
Any idea ?
This seems like a Mono/Winforms issue. Try creating a new Windows Form project in Visual Studio, add just a TextBox to the form, then see if you get the same problem.
-
Hello,
Yes I have the same issue. It looks like it's due to the text box... (it's the only thing that is not loaded before the application's crash)
Edit : after some researches I found some topics on the subject. There's an issue with versions under 3.10 of mono that could not handle textbox and its derivatives.
I'm having a hard time finding the tricks to update mono as apt-get gives me version 3.2...
-
Has anyone tried Windows 10 IoT on the Pi with AHMI?
-
Has anyone tried Windows 10 IoT on the Pi with AHMI?
Windows 10 IoT requires UWP applications which is a different UI and framework. I have been gradually modifying the drivers so the will also work in UWP apps, but they are not quite there yet.
-
Hello,
Just wanted to give the following link, that gives clues about the issue using Modbus RTU on a Raspberry Pi (or more generally on any no-windows device, through mono).
http://stackoverflow.com/questions/7393818/serialport-in-mono-in-linux-not-responding-to-datareceived-event (http://stackoverflow.com/questions/7393818/serialport-in-mono-in-linux-not-responding-to-datareceived-event)
The issue is that mono do not handle the data received events for SerialPort. This post explains 3 ways to "solve" that.
Also, here are the related state of mono about Serial communication :
http://www.mono-project.com/archived/howtosystemioports/ (http://www.mono-project.com/archived/howtosystemioports/)
Indeed the ReceivedBytesThreshold method is not implemented and might be implemented manualy I suppose...
-
Has anyone tried Windows 10 IoT on the Pi with AHMI?
Windows 10 IoT requires UWP applications which is a different UI and framework. I have been gradually modifying the drivers so the will also work in UWP apps, but they are not quite there yet.
How's that coming ? Dying to try AHMI on an R Pi 3 with their touchscreen and ModBus comms....................................
-
How's that coming ? Dying to try AHMI on an R Pi 3 with their touchscreen and ModBus comms....................................
The ControlLogix driver for Widows10 IOT is in the works. But you can still use all of the current existing with the standard Pi image (Image) by using Mono.
-
Looking to tap the infinite knowledge here...........
Have AHMI running on a R Pi 3 (running Raspian/Jessie).
Having a problem establishing comms between the Pi/AHMI app and the PLC via ModbusRTU. Modbus RTU driver wants "Com1, 2, 3", but Pi/Raspbian doesn't define USB ports that way.
Anyone have a solution to offer ?
-
@Archie
In the ModbusRTU definition, where the com port is declared, can ANY string be used there, or is it restricted to "COM1, COM2, etc." ?
-
@Archie
In the ModbusRTU definition, where the com port is declared, can ANY string be used there, or is it restricted to "COM1, COM2, etc." ?
The driver does not put any restrictions on the value, that value is passed directly to the SerialPort object:
https://msdn.microsoft.com/en-us/library/system.io.ports.serialport.portname(v=vs.110).aspx
According to this older Mono documentation, the SerialPort implementation is not complete which would cause the serial drivers to not work:
http://www.mono-project.com/archived/howtosystemioports/
-
Archie;
Is there a chance that Mono has developed any further since the referenced article (2011) ?
I found this from 2013, but it's mostly Greek to me...............
http://antanas.veiverys.com/mono-serialport-datareceived-event-workaround-using-a-derived-class/
Wayne
-
Is there a chance that Mono has developed any further since the referenced article (2011) ?
I found this from 2013, but it's mostly Greek to me...............
http://antanas.veiverys.com/mono-serialport-datareceived-event-workaround-using-a-derived-class/
I really don't keep up with the Mono framework, so I'm not sure if anything has been changed. Since Microsoft bought Xamarin, that may have brought on some changes.
-
I have created a Dataliner using Advanced HMI 3.99 and it works great on my windows computer but i want to get it running on Raspberry Pi 3. I ran through the steps from the beginning of this post but it doesn't want to work. The following is the response i get back from it:
root@raspberrypi:/home/pi/AdvancedHMI/bin/Debug# mono DataLiner.exe
Unhandled Exception:
System.InvalidOperationException: WinForms_SeeInnerException ---> System.InvalidProgramException: Method MfgControl.AdvancedHMI.MainForm:InitializeComponent () is too complex.
at MfgControl.AdvancedHMI.MainForm..ctor () [0x00000] in <filename unknown>:0
at (wrapper managed-to-native) System.Reflection.MonoCMethod:InternalInvoke (System.Reflection.MonoCMethod,object,object[],System.Exception&)
at System.Reflection.MonoCMethod.InternalInvoke (System.Object obj, System.Object[] parameters) [0x00000] in <filename unknown>:0
--- End of inner exception stack trace ---
at MfgControl.AdvancedHMI.My.MyProject+MyForms.Create__Instance__[MainForm] (MfgControl.AdvancedHMI.MainForm Instance) [0x00000] in <filename unknown>:0
at MfgControl.AdvancedHMI.My.MyProject+MyForms.get_MainForm () [0x00000] in <filename unknown>:0
at MfgControl.AdvancedHMI.My.MyApplication.OnCreateMainForm () [0x00000] in <filename unknown>:0
at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.OnRun () [0x00000] in <filename unknown>:0
at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.Run (System.String[] commandLine) [0x00000] in <filename unknown>:0
at MfgControl.AdvancedHMI.My.MyApplication.Main (System.String[] Args) [0x00000] in <filename unknown>:0
[ERROR] FATAL UNHANDLED EXCEPTION: System.InvalidOperationException: WinForms_SeeInnerException ---> System.InvalidProgramException: Method MfgControl.AdvancedHMI.MainForm:InitializeComponent () is too complex.
at MfgControl.AdvancedHMI.MainForm..ctor () [0x00000] in <filename unknown>:0
at (wrapper managed-to-native) System.Reflection.MonoCMethod:InternalInvoke (System.Reflection.MonoCMethod,object,object[],System.Exception&)
at System.Reflection.MonoCMethod.InternalInvoke (System.Object obj, System.Object[] parameters) [0x00000] in <filename unknown>:0
--- End of inner exception stack trace ---
at MfgControl.AdvancedHMI.My.MyProject+MyForms.Create__Instance__[MainForm] (MfgControl.AdvancedHMI.MainForm Instance) [0x00000] in <filename unknown>:0
at MfgControl.AdvancedHMI.My.MyProject+MyForms.get_MainForm () [0x00000] in <filename unknown>:0
at MfgControl.AdvancedHMI.My.MyApplication.OnCreateMainForm () [0x00000] in <filename unknown>:0
at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.OnRun () [0x00000] in <filename unknown>:0
at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.Run (System.String[] commandLine) [0x00000] in <filename unknown>:0
at MfgControl.AdvancedHMI.My.MyApplication.Main (System.String[] Args) [0x00000] in <filename unknown>:0
root@raspberrypi:/home/pi/AdvancedHMI/bin/Debug#[/color]
I would really appreciate it if anyone had any thoughts on what i could be doing wrong or if i need to change something to allow it to operate on raspberry pi.
Thanks
-
Check reply #46 to see if that might help remove any errors.
You should read all the posts in this topic since some might provide clues related to your setup.
-
Would a USB barcode scanner that act as a keyboard work on AAHMI-Pi ? TIA.
-
Hi All,
New here and I have a question. I am running a Ras Pi 3 w/ the official 7" touch screen. I have gotten OpenPlc and AHMI 3.99s running on it. I'm running AHMI under mono 3.2.8 and the latest Raspian Jesse. I see the same problem that you can see in the screenshot in the 1st post. The desktop bleeds through the background in the tank and pipe controls. I've tried all the variants of background images and fills on the main form and the individual components to no avail.
BTW, I don't see this behavior when running the solution on a Win7 machine. While I have an ugly workaround (make the main form a solid color and the desktop the same color with no icons) and can live with it if necessary, I was wondering if there might be a solution or if this is just a limitation of the way mono handles the transparency in the components.
Thanks,
Shawn
-
Since this "bleed through" is actually a problem with Mono and not AdvancedHMI, you may get better feedback from the Mono Winforms bug reporting:
http://www.mono-project.com/docs/gui/winforms/
-
Thanks Archie. That is what I thought. After searching the Mono Bugzilla, I didn't find a report that matched. I'm not going to do a bug report for an ancient Mono release. Since this is a hobby project, I'll go old school and not use any of your controls that have this issue. I can always draw something and use it as an image if I really need it.
As an aside, Mono is in the 4.xx series now, but mono-vbnc is broken against it. I really don't want to go through the change of life trying to build it against the new runtime. I think that I'll just concentrate on making OpenPlc talk to my external hardware and adding a Mqqt to Modbus-TCP gateway on the Pi.
AHMI and OpenPlc make a pretty cool and cheap stand alone controller. Thanks for releasing AHMI as a semi open source project.
-
Would a USB barcode scanner that act as a keyboard work on AAHMI-Pi ? TIA.
I tried it with a USB scanner, it works just fine!
-
tried using the original raspberry pi with the steps mentioned in the first post. Applications seems to load fine (first page has nothing but changeform buttons) but crashes after clicking the change form buttons going to the screens with the data displays.
-
Rookie 2017,
Even though there is no question in your post, here is what you might consider:
1) Try reading all the posts to see what issues other users have experienced and if anyone offered any solution
2) Mono environment has lots of limitations and some AHMI controls might not work properly
3) Your screens with data displays might be causing the crash and not necessarily the FormChangeButton itself (to test this you can just try opening another blank form with the click of this button).
-
Are there any updates on the ability to run AdvancedHMI on a Pi using Windows 10 IoT? I saw something about the ControlLogix drivers not being quite there yet, but I'm talking to a Do-More processor using MODBUS.
Thanks! :)
Chris
-
Are there any updates on the ability to run AdvancedHMI on a Pi using Windows 10 IoT? I saw something about the ControlLogix drivers not being quite there yet, but I'm talking to a Do-More processor using MODBUS.
The full AdvancedHMI package running on Windows 10 IOT will most like not happen because only UWP will run on that OS. UWP has no well refined drag and drop designers as does Winforms. The UI has to be put together using XAML which diverts from the philosophy of AdvancedHMI which is being extremely easy to get started with.
-
Hi. I'm trying to get AvancedHmi to run on a Raspberry pi 3. I installed Raspbain and managed to get mono installed (I think) but it still is not working. This is what I get when I try to run it.
The entry point method could not be loaded due to Could not load file or assembly 'Microsoft.VisualBasic, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. assembly:Microsoft.VisualBasic, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a type:<unknown type> member:(null) signature:<none>
Do you have an updated procedure to get this to work? Debian Wheezy is not listed for download anymore on the Pi website.
-
Hi. I'm trying to get AvancedHmi to run on a Raspberry pi 3. I installed Raspbain and managed to get mono installed (I think) but it still is not working. This is what I get when I try to run it.
The entry point method could not be loaded due to Could not load file or assembly 'Microsoft.VisualBasic, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. assembly:Microsoft.VisualBasic, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a type:<unknown type> member:(null) signature:<none>
Do you have an updated procedure to get this to work? Debian Wheezy is not listed for download anymore on the Pi website.
It sounds like you did not get the vb extension installed with this step:
apt-get install mono-vbnc
-
I would suggest that unless you have no other option, not to use a Raspberry and Mono.
Small Windows 10 PCs can be had for not much more money. Not to mention less pain.
Don’t get me wrong, AHMI will run fine on a RPi in Mono. However, Mono has its gotchas and you will be hard pressed to find support for a problem when you run into one.
The Mono community seems too caught up to release the next big update to help users with the current version. Especially if your problem is not “interestingâ€.
I have three RPis running Mono and AHMI. Out of all the issues, the one I deal with the most and have yet to solve is high cpu usage. It may not show up for a few weeks then one day the cpu will go to 100% and stay there until the app is restarted. This is only on the RPi.
Reminds me of that scene in Jurassic Park. “Nuh-uh-uuh! You didn’t say the magic word!â€
-
I started over and reinstalled everything and it is running now so I must have missed something the first time. Thanks.
-
Here is how to run an AdvancedHMI application on a Raspberry Pi
1) Download the Debian Wheezy image
http://www.raspberrypi.org/downloads/
Hi there,
Is it essential that the Wheezy image is installed and not a more up to date version?
Thanks in Advance.
-
Here is how to run an AdvancedHMI application on a Raspberry Pi
1) Download the Debian Wheezy image
http://www.raspberrypi.org/downloads/
Hi there,
Is it essential that the Wheezy image is installed and not a more up to date version?
Thanks in Advance.
I can only really offer the advice to try the other images and see if they work. As long as you can install Mono with WinForms, it should work.
-
Here is how to run an AdvancedHMI application on a Raspberry Pi
1) Download the Debian Wheezy image
http://www.raspberrypi.org/downloads/
Hi there,
Is it essential that the Wheezy image is installed and not a more up to date version?
Thanks in Advance.
I've tested this using NOOBS to install Raspbian. It works! Wheezy is not required. I released on .NET Framework 4.5 after reading a bit on mono. I have not tested other versions of .NET. Happy coding!
-
Here is how to run an AdvancedHMI application on a Raspberry Pi
1) Download the Debian Wheezy image
http://www.raspberrypi.org/downloads/
2) Copy the image to the MicroSD card using Win32DiskImager
3) Install the card and boot up the Pi
4) When it gets to the configuration screen, set it to expand the image and also to boot to a Graphical User Interface
5) Select Finish in the configuration and Reboot
6) Once booted into the GUI, open a Command Prompt
7) Type these series of commands:
sudo su
apt-get update
apt-get install mono-complete
apt-get install mono-vbnc
8 ) Put in a memory stick with an AdvancedHMI application on it
9) In the command prompt, use the "cd" command to browse to the memory stick to the directory /bin/debug
10) mono AdvancedHMI.exe
In a few seconds the application should start.
There are a few things you may run into.
- You cannot use an OPC server because it is not a .NET application
- The MessageDisplayByValue may stop the application because it uses a speech library. There is a work around. Find System.Speech.DLL on your Windows PC and copy the file into the /bin/debug directory
Archie, you should add in here just for the new people like myself the following: You have to set up raspberry pi for a static ip address:
sudo nano /etc/dhcpcd.conf.
Type in the following lines on the top of the file: interface eth0 static ip_address=192.168.1.XX/24 static routers=192.168.1.1 static domain_name_servers=192.168.1.1.
sudo reboot.
Then Make sure the PLC and the Pi have the same (subnet?) first two numbers on the ip..............
I came across this writeup first and thought i would be set. I was wrong and it took me quite a while to figure this out. It would just be super helpful to have all the info in one place to get the pi and AHMI communicating.
Just a thought. thanks
-
Archie, you should add in here just for the new people like myself the following: You have to set up raspberry pi for a static ip address:
Why do you say static? It has to be on the same subnet. This is typical for any HMI, not just pi. If you don't have DHCP server then you must setup manually.
-
There is a lesser known utility on the Pi, that makes it easier:
> sudo raspi-config
-
I'm new sorry. :D did not know about the addressing
-
Here is how to run an AdvancedHMI application on a Raspberry Pi
1) Download the Debian Wheezy image
http://www.raspberrypi.org/downloads/
2) Copy the image to the MicroSD card using Win32DiskImager
3) Install the card and boot up the Pi
4) When it gets to the configuration screen, set it to expand the image and also to boot to a Graphical User Interface
5) Select Finish in the configuration and Reboot
6) Once booted into the GUI, open a Command Prompt
7) Type these series of commands:
sudo su
apt-get update
apt-get install mono-complete
apt-get install mono-vbnc
8 ) Put in a memory stick with an AdvancedHMI application on it
9) In the command prompt, use the "cd" command to browse to the memory stick to the directory /bin/debug
10) mono AdvancedHMI.exe
In a few seconds the application should start.
There are a few things you may run into.
- You cannot use an OPC server because it is not a .NET application
- The MessageDisplayByValue may stop the application because it uses a speech library. There is a work around. Find System.Speech.DLL on your Windows PC and copy the file into the /bin/debug directory
Well hot dog, I got this working!
This is my first foray into Raspberry Pi and AHMI, - I have been mostly an Arduino guy.
(https://www.nealmastel.com/FS/2020AHMIonPi.jpg)
I do have a question however, is there a connector, or way to harvest data from MySQL or an AWS RDS into AHMI directly? I have the desire to have some direct device data, and some database data on AHMI.
Neal
-
Just search this forum for "MySQL" and you will see some topics that had discussed it, like these ones:
https://www.advancedhmi.com/forum/index.php?topic=1641.0
https://www.advancedhmi.com/forum/index.php?topic=2291.0
https://www.advancedhmi.com/forum/index.php?topic=2129.0
Google will probably provide a bunch more info on MySQL and .Net usage.
-
Hello folks!!! Newbie here....
I see that @NaturallyAspirated is still using and has success on Archie's 2015 post.
Is there an updated version where a detailed step instruction are provided for an absolute green newbie like me?
Would appreciate any link. Thanks in advance...
Here is how to run an AdvancedHMI application on a Raspberry Pi
1) Download the Debian Wheezy image
http://www.raspberrypi.org/downloads/
2) Copy the image to the MicroSD card using Win32DiskImager
3) Install the card and boot up the Pi
4) When it gets to the configuration screen, set it to expand the image and also to boot to a Graphical User Interface
5) Select Finish in the configuration and Reboot
6) Once booted into the GUI, open a Command Prompt
7) Type these series of commands:
sudo su
apt-get update
apt-get install mono-complete
apt-get install mono-vbnc
8 ) Put in a memory stick with an AdvancedHMI application on it
9) In the command prompt, use the "cd" command to browse to the memory stick to the directory /bin/debug
10) mono AdvancedHMI.exe
In a few seconds the application should start.
There are a few things you may run into.
- You cannot use an OPC server because it is not a .NET application
- The MessageDisplayByValue may stop the application because it uses a speech library. There is a work around. Find System.Speech.DLL on your Windows PC and copy the file into the /bin/debug directory
Well hot dog, I got this working!
This is my first foray into Raspberry Pi and AHMI, - I have been mostly an Arduino guy.
(https://www.nealmastel.com/FS/2020AHMIonPi.jpg)
I do have a question however, is there a connector, or way to harvest data from MySQL or an AWS RDS into AHMI directly? I have the desire to have some direct device data, and some database data on AHMI.
Neal
-
Hello folks!!! Newbie here....
I see that @NaturallyAspirated is still using and has success on Archie's 2015 post.
Is there an updated version where a detailed step instruction are provided for an absolute green newbie like me?
Would appreciate any link. Thanks in advance...
I can help you walk though it. It's pretty easy to do!
Neal
-
Dear Sirs
Could you help me to install AdvancedHMI application on my Raspberry pi 3+??
-
How to download AdvancedHMI.exe software to put it in RaspberryPi?
Kindly give me proper details with each and every step(How to go step by step)
So please reply ASAP.
-
The first and most important step is that you start reading.
You can choose to go from the very first post of this topic (which would be recommended) or just scroll up to the reply #93 and you will see the steps.
-
Where is an AdvacnedHMI.exe file or from where i can download it?
-
Where is an AdvacnedHMI.exe file or from where i can download it?
You don't download AdvancedHMI.exe , you use the base package to create your application
https://www.advancedhmi.com/index.php?main_page=product_info&cPath=2&products_id=20
-
How to start communication with Rpi from our Base Package and how can I check that rpi is responding?
-
How to start communication with Rpi from our Base Package and how can I check that rpi is responding?
Have you read the quick start guide?
-
Consider that RPi is just another computer.
You don't communicate with RPi at all, you only use it to load your finished application and run it from there.
You need to use the Base Package on a Windows based computer, create your application and, while creating it, can only test it with the direct connection to your PLC. Once you know it works, that is when you load it to the RPi and connect your PLC to the RPi as well.
-
Hi guys. I have got AHMI working on my Pi 4b 8Gb using Mono. The executable file loads fine and the HMI looks great so Mono definitely works well.
The issue I am having is with the Pi port labels. Unlike Windows which has easy "COM1" "COM2" etc it would seem that after a little bit of digging around the command lines on the Raspberry Pi my USB - RS485 cable seems to be attached to "ttyUSB0". However when I enter this port value into the properties box of the Modbus RTU driver and run it on the Pi it shows that "no such port address exists" ? . . . Any help would be most appreciated. Would love to get this to work on the Raspberry Pi.
-
Hi, sorry, what OS is the RPi working with?
Could you guide me how mono is installed in RPi
and what version
-
Afternoon. I have my Advanced HMI project working on my raspberry Pi using Mono, but I have a question. On my project, I have modbus data coming from an Arduino Mega 2560 to the to the raspberry Pi via a single USB cable and using the ModbusRTUCom library to pass the data (/dev/ttyACM0). I have two displays, but each has a different application on the screen and shares several registers from the modbus data. Can both programs use the same ModbusRTUCom library to use on the different displays?
-
I wanted to get this working on the Raspberry Debain 12 and had issues with mono-vbnc as it is deperciated and they said to use mono-vbc now, but i'm not sure of interaction between Mono/AdvanceHMI/Debain.
But I was able to get this working using the Raspberry Pi OS (32-Bit) version.
I'll add in the extra step I had to take using example below:
sudo su
ln -s /usr/share/keyrings/raspbian-archive-keyring.gpg /etc/apt/trusted.gpg.d/raspbian-archive-keyring.gpg
rm /etc/apt/trusted.gpg
apt-get update
apt-get install mono-complete
apt-get install mono-vbnc
The extra two steps allow using the mono-vbnc in Debain 12 - likely another way to do this but this got me working. I'm going to include the links I used to help be able to install this headless and reasoning for extra steps.
Please let me know if need additional information or I've done something completely wrong, please ;)
https://www.tomshardware.com/reviews/raspberry-pi-headless-setup-how-to,6028.html for headless example, they use different OS but the setup example starting at #9 is good.
https://github.com/RPi-Distro/repo/issues/348 This shows my reasoning and how they suggested to fix for using additional code.
The ML1000 example is in the Sample Programs here.
Thanks,
Bad Sector
Here is how to run an AdvancedHMI application on a Raspberry Pi
1) Download the Debian Wheezy image
http://www.raspberrypi.org/downloads/
2) Copy the image to the MicroSD card using Win32DiskImager
3) Install the card and boot up the Pi
4) When it gets to the configuration screen, set it to expand the image and also to boot to a Graphical User Interface
5) Select Finish in the configuration and Reboot
6) Once booted into the GUI, open a Command Prompt
7) Type these series of commands:
sudo su
apt-get update
apt-get install mono-complete
apt-get install mono-vbnc
8 ) Put in a memory stick with an AdvancedHMI application on it
9) In the command prompt, use the "cd" command to browse to the memory stick to the directory /bin/debug
10) mono AdvancedHMI.exe
In a few seconds the application should start.
There are a few things you may run into.
- You cannot use an OPC server because it is not a .NET application
- The MessageDisplayByValue may stop the application because it uses a speech library. There is a work around. Find System.Speech.DLL on your Windows PC and copy the file into the /bin/debug directory
-
Afternoon. I have my Advanced HMI project working on my raspberry Pi using Mono, but I have a question. On my project, I have modbus data coming from an Arduino Mega 2560 to the to the raspberry Pi via a single USB cable and using the ModbusRTUCom library to pass the data (/dev/ttyACM0). I have two displays, but each has a different application on the screen and shares several registers from the modbus data. Can both programs use the same ModbusRTUCom library to use on the different displays?
Try using this post to make it into E/IP Tunnel. I have a few apps i'm using Micro820 w/ Modbus to 8port I/O Master that I'll test this out over.
https://www.advancedhmi.com/forum/index.php?topic=899.msg19138#new
Bad Sector