Foward data from Logo Siemens 8 to Web page - plc

I'm looking for a way to transfer data from my logo plc to my webpage, does anyone know a way to do it?
For example, I would like to know if my logo it's turned on or not.
Thanks for your help

To transfer PLC data to your webpage access the Logo's built in webserver. Your webpage could display the Logo's running status in a frame, or whatever methods suits your needs best.

You can either use the input output network function from the built in library of the logo plc.Furthermore you can use the VM mapping function to send or receive signals .

Related

Flex mobile project for IOS, server side proxy

I am trying to write an iphone app that loads a video from an inbuilt web server running off a camera (connect to iphone via wifi).
I am using flash builder / flex mobile project - not particularly familiar but finding it easier to understand than xcode !!
The files from the camera have the wrong file extension so will not play on the ios video app, can I set up a server side proxy in flex mobile and use this to alter the file extension and then pass this link to the ios video app ?
If so any help anybody could give me ( examples etc) would be really grateful received , I have been trying to get round this problem for a couple of weeks .
Cheers
Toby
I can explain, conceptually, what a server side proxy would do in this case. Let's say you are retrieving a URL, like this:
http://myserver.com/somethingSomething/DarkSide/
to retrieve a video stream from the server. You say it won't be played because there is no file extension; so you have to, in essence, use a different URL with the extension. Set up 'search engine friendly' URLs on the server. And do something like this:
http://myserver.com/myProxy.cfm/streamURL/somethingSomething%5CDarkSide/Name/myProxyVid.mp4
Here is some information on how to deal with Search Engine Friendly URLs in ColdFusion. Here is some information on how to deal with Search Engine Friendly URls in PHP. I'm sure Other technologies will come up in a Google Search.
In the URL above; this is what you have:
http://myserver.com/: This is your server
myProxy.cfm: This is your server side file; that is a proxy
streamURL/somethingSomething%5CDarkSide/Name/myProxyVid.mp4: This is the query string. It consists of two name value pairs. The first is the streamURL. This is the URL you want to retrieve with your proxy. The second is just random; but as long as it ends with the file extension .mp4 the URL should be seen as an 'mp4 file'
The code behind your myProxy.cfm should be something like this, in psuedo-code:
Parse URL Query String
Retrieve Stream.
Set mimeType on return value.
Return stream data
I used a similar approach on TheFlexShow.com to track the number of people who watch our screencast on-line vs downloading it first. I also used the same approach to keep track of impressions of advertiser's banner ads. For example, the browser can't tell that this is not a JPG image:
http://www.theflexshow.com/blog/mediaDisplay.cfm?mediaid=51
Based on this, and one of your previous questions; I am not convinced this is the best solution, though. I make a lot of assumptions here. I assume that the problem with playing the file does relate to the extension and not the file data. I assume that you are not actually streaming video with an open connection on both client and server to send data back and forth.

Send link to update DB with Data

In our iPhone app , we offer email templates populated with DB. also user can create their own templates.
Say for example , i have my own templates created over 500 entries to use
here i need to know the possibility on the below things since my client asks me.
If i want to to send my templates stored into my DB to myfriend who uses the same application.( So my friend does not have to create the templets on his own , he can use mine)
Can that user be able to load those template details ( DB information ) into his app? (like posting the db contents to server and the same content can be loaded into his app using link)
I think it cant be done but i would like to know opinions and views to convey this to my superior.
Thanks a lot
This could help: How do I associate file types with an iPhone application?
Okay, well.. It's possible to do what you are trying to do.
You would need to
Serialize the data that's stored in the DB
Figure out a way to send this data to the server/as an attachment in an email over to your friend.
So from that point of view,
Doing the first is pretty simple. If its all just string content, you can serialize it into an XML/JSON. There are a lot of ways out there that converts objects into strings or bytes to send them over the network anywhere you please.
The second needs support from the server. You would need a server that can identify the applications from one another. ie. yours from that of your friend's. It should then be made to handle the serialized content you are planning to send over and then figure out a way to send it to the friend. maybe a push notification? You could possibly look at Urban Airship or some such offering for doing this incase you dont have an existing server.
Or, you can cut yourself all the work and see if your workflow can fit into this
http://www.raywenderlich.com/1980/how-to-import-and-export-app-data-via-email-in-your-ios-app

Amazon S3 - direct upload, hide action URL that user can't see it

We use Amazon S3 for storing large files, so we use direct upload from user's browser as described here: http://aws.amazon.com/articles/1434
My question is:
could I somehow hide form's action URL so user won't be able to find out where the file is being uploaded? Would it be 100% hiden or could I just at least make it harder for experienced users to find it?
Thanks.
Well, you need to give the information to the user so that they can use it to upload to S3... the only way to hide it would be to have them POST to your server, where you then re-POST it to S3, but that defeats the purpose doesn't it?
What's the concern, exactly? The document you linked shows that you have to sign everything so they know that only you could've made that form... so it's not like anybody can get at your data, anyway.
You can't hide it since the whole point is going from their computer directly to s3, the fastest way possible. Even if you removed it from the code and had your form submit button request a url to use, then hide, it will just be in console.log's network activity. If you have to use s3, you maybe should install a faster uploader(or write one in c? haha) than node if you want to run it through your server. which begs the question, what language/framework can upload to s3 the fastest?

How to mirror an iPhone map in a web page

Basically I want to send gps coordinates (displayed on a map in the iPhone) from the iPhone to a webserver that store the values in a database. You should then be able to retrieve these coordinates and display them on a web page.
I am thinking of a set up like this:
I want the browser to request and receive the coordinates in real time (every 10 seconds or so) and I'm wondering if this is a good way to mirror the map in a browser or should I use a different approach? Finally, can you see any obvious flaw/flaws in this design (i.e. performance issues)?
your setup makes sense. The question is, what will you use to keep the map in the browser up to date? I would suggest you check out http://socket.io, I think it will do exactly what you need.
Cheers,
Johannes

Best method to make a Distributed Service (Mobile Client - Server)?

i'm working in a little project.
The idea is send information from mobile device to a server, then the sever performs some calculations and return a response to de device.
I know how to do this using Sockets (directly), ut I was wondering if there were any other method (better) for this communication.
Something to improve performance and not develop directly with socket add SSL for safety communication process.
Greetings and thanks for reading
I think a web service would be appropriate here. If you want a more detailed answer perhaps you can provide more information about exactly how much data would be transferred, how often the requests would be, etc.
I like to make PHP Pages for the server side, and simply call the PHP pages with the required data in the url. If you allow your mobile app to read the source of webpages, you can read the source of, for example:
http://www.yoursite.com/doSomething.php?id=5
doSomething.php might look something like this
<?php
//Multipy the passed value of 'id' by 3
echo (int)$_REQUEST['id'] * 3;
?>
So your webbrowser would see the source of that page as
15
Essentially what this demonstrated is passing info to a web service, processing the data, and returning data. The returned data can be anything from HTML, to Text, to XML meant to be used for parsing.