Hi,
I am writing a completely custom UI for the BCS using javascript.
One of the problems with using javascript is the restrictions around Same Origin Policy which basically means you can't access the BCS directly from javascript, you need to run a server-side proxy. This limits where the device can be run (needs a web server, which then implies internet access).
Would it be possible to add CORS headers to BCS so that we can directly access the device without the need for a proxy? That would make it easier to use the device without internet access or on mobile devices on a local network. It would be a matter of adding a single response header to each of the APIs allowing all (or a configurable address) direct access like this:
Access-Control-Allow-Origin: http://api.bob.com
Details here: http://www.html5rocks.com/en/tutorials/cors/
Feature Request - CORS headers
Re: Feature Request - CORS headers
If you're using Javascript, you might be interested in MooCS, which does most of the BCS raw interface heavy lifting for you.
http://www.embeddedcc.com/wiki/index.php?title=Partners
I'll investigate the CORS headers, but I can't promise a release date.
http://www.embeddedcc.com/wiki/index.php?title=Partners
I'll investigate the CORS headers, but I can't promise a release date.
Re: Feature Request - CORS headers
+1 to the Cors headers.
Unless I misunderstand how the MooCS works, it requires a server setup to run, making it impractical to write a website anyone can use with their BCS.
I'd love to hear from someone if I just don't understand enough yet.
Unless I misunderstand how the MooCS works, it requires a server setup to run, making it impractical to write a website anyone can use with their BCS.
I'd love to hear from someone if I just don't understand enough yet.
Move, copy, clear proc/states: http://manipulator.from-ca.com/
Perform coeff. mods: http://calculator.from-ca.com/
HMI latest ver: http://bbrally.altervista.org/guibeta/i ... r=01042020
Perform coeff. mods: http://calculator.from-ca.com/
HMI latest ver: http://bbrally.altervista.org/guibeta/i ... r=01042020
Re: Feature Request - CORS headers
Is this with the focus of controlling a brewing system? Is this something you would be willing to share with others? It would be great to see more details on this, as a simple, easier to program on the fly UI would be wonderful to have for the BCS.forkboy wrote: I am writing a completely custom UI for the BCS using javascript.
Re: Feature Request - CORS headers
Hi just got the notification of release 4.0
I could not see anything from a quick look, but did an option for CORS requests make it into the new API?
I could not see anything from a quick look, but did an option for CORS requests make it into the new API?
Re: Feature Request - CORS headers
You bet! The utilities that do backup/restore, 3.x config migration, recipe values, PID tuning, etc all rely on using CORS.
Re: Feature Request - CORS headers
that's awesome!... been waiting a long time for this.