1 post tagged “php”
Yes, it's been a looong time since I posted here. I've been engrossed for the last 1/2 year or so with a project at the Boys & Girls Club of Hawaii Nanakuli Youth Education Town. What I have out there is a 1.2 kW photovoltaic system with DC lighting for a few offices, a conference room and a workroom. The most exciting thing for me is the development of a data acquisition system with a web-based dashboard to view the data.
Hardware
Web-based Dashboard
Here's the fun part. When I started out I started to shop around for ready-made dashboard systems. They tend to be expensive and proprietary - anything custom cost extra $. So I started to research on how to build one from scratch. The usual reaction I'd get when I started this was, "Are you nuts?!?" This just added fuel to my
curiosity. I settled on a cheap (free) apache web-server through xampp. Xampp also comes with a free (open source, as they put it) mysql database system and a free php scripting engine. There are other server-side applications that come with xampp but the most important were mysql and php. I also settled on a nice flash graphics package from AnyChart. In a nutshell, I download the Acquisuite and other I/O modules and import the data into a mysql database. PHP scripts are used to format the data into xml that AnyChart can use to build the graph. HTML code is used to link the xml to the Adobe flash graphic. I also use some javascripts to extract "real-time" xml from the modbus modules. These scripts create other xml files that are used with flash gage graphics. Bare in mind I started out knowing ziltch about mysql and php. Google is a great friend in situations such as these - you'd be surprised how much information is out there on php and mysql.
Moving Forward
For now, I've created a simple website that contains these dashboard charts and gages. This proof of concept was done on a LAN connection to the Acquisuite. Now I need to find a real remote host for all of this. This has been real hard work but I rather enjoy it. The final product will be something that the kids can use to learn about and perhaps promote awareness of renewable energy and sustainability. It is indeed a labor of love!