Asaak
Posts: 6
Joined: Mon Nov 02, 2015 4:02 pm

graphic user interface using web

Mon Apr 25, 2016 2:33 pm

Hi!

I am building a java app to control, among other things, GPIO using Pi4J. I have a gps sensor so I want to display my position in a map. I tried to use javaFX and a webview in which I used leaflet.js . Turns out javaFX is too slow so I decided maybe the way to go was using tomcat and a web as the GUI.
I am am able to start my tomcat server, and run my webpage that shows my leaflet map, and using javascript calculates a route and displays it. The problem is that I want to conect this web and the elements on it ( buttons, divs, labels ) so I am able to modify its values from java, according to my needs. Long story short, I want to use the web as a lightweight GUI, to interact with my app. I've tried tomcat and war, but problem is I don't know how to start all my logic and make the elements of my web accessible to the app.
Has someone done something similar? Any ideas?

Thanks!

Return to “Java”