Pulling data
Thorleifur
Posts: 58
A client called and asked if I could program something that could pull data from devices, connected to their AMX system, into a file. ( Projector lamp hours, fans, serial numbers, firmware version and such) I have not done it before, but string/variable_to_xml don´t seem that complicated.
I have started to program it, but then I started to wonder if that was the "correct" way to go and if someone had programmed something it before. And thus could give some insight into if there was a better/simpler way to go.
Does anybody have some insight on the topic?
Backstory of the project:
16 NI controllers of different types. There are bout 13 of them connected to something I have to pull data from. About 200 LAN devices on the network, and I will need to pull at least firmware version out of most of them. So I really don´t what to start to build a big house when I only need a *insert something meaningful* . They will need it seperated by Hall/Boardroom/Meeting room. I will need to return it as Excel at the end I am guessing... Accountants like Excel.. right?
I have started to program it, but then I started to wonder if that was the "correct" way to go and if someone had programmed something it before. And thus could give some insight into if there was a better/simpler way to go.
Does anybody have some insight on the topic?
Backstory of the project:
16 NI controllers of different types. There are bout 13 of them connected to something I have to pull data from. About 200 LAN devices on the network, and I will need to pull at least firmware version out of most of them. So I really don´t what to start to build a big house when I only need a *insert something meaningful* . They will need it seperated by Hall/Boardroom/Meeting room. I will need to return it as Excel at the end I am guessing... Accountants like Excel.. right?
0
Comments
If you're just wanting to write some data out to a file as a once off though a nice approach would be to grab what you need from the devices then have a look at 'File Operations Example: Writing to a File' within the NetLinx Keywords Help in NetLinx Studio. It's super simple.
This will enable you to write to either a csv or even just a plain txt file in the /user directory on the onboard CF card. You can then either FTP this from there or use the SMTP support in the v4 firmware to email it. If you're emailing though just ensure that you give it a .txt extension otherwise it won't allow you to send.
Yeah, I tried to sell them RMS, but they don´t think they have the budget for it. Our SLA states that I have to spend some time on new code every year, and they think that is enough. Some people just don´t learn.
Thanks for the .txt extention tip.
vining:
I have the DevTermLogger from Good Guy Dave, good piece of code there, can´t belive I forgot about it. I will take a look at it and see if I can tweak it my way.
I did some basic structure thingy yesterday, with writing to XML and it works fine for the one hall I have tried it on. XML opened in Excel was ok also, even though the xml data is written into a single line, which is strange.