Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 06/23/2016 in all areas

  1. Okay I've come back with more, sorry about the wall of text. Attached is a new version with most of the core code unchanged but with several new features. Webpages and VIs that are the pages can have spaces in their name Webpage names come from the VI title if there is one Rectangle decorations now work properly Position and size can be updated periodically by using the config Decorations Can Change or using the Force Update (more on that later) Floating text decorations now work using the Text class Position and text can be updated periodically by using the config Decorations Can Change or using the Force Update, size and boldness are sent only on start at the moment Default Refresh Rate can be set with the config Show Border which is the size of the FP can be set with the config, no way of updating this at the moment but I think it should be able to be Synchronous Requests enable the web page to only request new data, once it has received a reply from the last request With this enabled the refresh rate can be set to 1ms without pilling up requests With this enabled if no request comes in once every 5s a reply is automatically sent, this is in case a request is lost and no reply sent, this is per connection Reduce Sent Data can be set with the config This will look at what data was sent for each object and not send it if the data hasn't changed. The code still has to get all the values and attributes but can help in places where there isn't much changing often. There is a separate list of objects, and what is sent, for each unique session. The first request from the web page is for full data in case things have changed since the time the HTML page was made All controls/indicators on the UI support being shown as an image. Controls that don't belong to a specific class will be defaulted to this mode A control that is an image cannot be interacted with in the web page, except for boolean controls When shown as an image, position, size, and visibility are also sent with each request along with the new image value New Value Only mode for all supported control types This will send just the value of the control for each supported type, position visibility and other properties will only be sent using the Force Update New Force Update function This is a VI that can be called from the main VI that will force objects whos references are passed in (or optionally all objects). This means controls can be sent as a Value Only mode in most situations, but then if a property does change on an object, it can be forced to send its new attributes. The example has been updated to have a button which shows and hides controls, and then an Update button that uses this Force Update function All controls support Visibility size and Position attributes which are sent on Force Update, or if the control is not Value Only This also will update any captions or labels on corresponding controls for visibility, position, and value Progress Bar now supports ranges that are negative, and that don't start at 0 Ranges can be updated if the control is not Value Only, or if Force Update is used Ring controls now can have the items in the drop down updated These are not updated if sent as Value Only, unless Force Update is used Picture Ring now supported On start each unique picture that the picture ring can be is stored as a variable in the JS file, and then the value is sent for which to display Code exists to try to detect duplicate Picture Rings, and only create one variable for each unique set of images, this also makes scanning faster Graphs now support up to two scales properly, but there is some kind of bug with multiple graphs not sure what it is yet String class now supports justification, background color including transparent, font color, font size, and boldness as attributes Captions, and Labels should work on controls now with some support for size External IP address can be set on Publish This is necessary if you want the web page to be accessible from somewhere other than localhost Default Control Behavior is available on Publish Here you can specify an array of control names that should default to Image Only, Value Only, or Value and Position This supports control names that start with a common string too Show Config Dialog on Publish If this is true, or if not all controls have been configured, then the dialog pops up to configure the page settings Config location moved into www directory Reorganization and cleanup Things I'd like to see some day, but I don't intend on working on this any time soon More native control support, things like path controls, tables, trees, listboxes, dials, scrollbars, picture boxes, and Combo boxes Support more graph tools like zooming, setting ranges, and changing other graph settings Support for tabs Support for right click menus if possible RT Support I think this one is possible, if the original static page is generated on the host, and the Value Only is used Multiple windows? Maybe by opening new windows with new URLs. Independent pages for each client Right now all clients share the same view of the same VI, it would be nice to be able to use a clone VI and have it generate new URLs and pages for each connection Better dynamic dispatch for creating the objects Right now adding a new control type is a bit of a pain because dynamic dispatch isn’t used for selecting the class type for a GObject. Doing this would mean just making a new class, and having it inherit from the control class Most VIs with no documentation, and some with the default icons, basically more documentation is needed VIPM Package could be made exposing just the 3 VIs needed, Publish, Force Update, and Cleanup FP Publisher Hooovahh Edit 2.zip
    1 point
  2. I don't think I will need to implement any custom logic in FPGA. Having worked with FPGA I only really want to use it if there is something I HAVE to do in it that I can't implement on real time side with a scan-engine synchronized loop. multi-kilohertz control loop rates, signal generation or digital logic. Motion control will be handled far better than what I can implement by purpose built, EtherCAT third party servo controllers. My experience implementing custom FPGA logic on the etherCAT slave is not really worth unless you really need it. That is, it's worth it if you have a physically distributed network and you need FPGA logic AT that physical etherCAT node. Otherwise, for master and slave colocated in same cabinet, I prefer to stick any FPGA code on the master, which can have big FPGA, and just use the slaves as expansion chassis for scanned IO. Thank you for pointing that out the CPU issue. I believe I will get a high performance cRIO then. It's good to know it can be done with multiple third party slaves. I am going to have to analyze what happens during resets, thank your for bringing that KB to my attention. Behavior during reset can be odd for certain device-- the NI 9401 DIO module outputs go HIGH during reset for example. Oh yes, I have the compatibility chart KB bookmarked http://www.ni.com/product-documentation/8136/en/ It's funny you mention UDVs because that is exactly what generated a nearly showstopping bug for me a year ago- CAR was issued http://forums.ni.com/t5/Real-Time-Measurement-and/cRIO-application-works-in-interactive-mode-but-broken-VIs/td-p/3095135 I wonder what the UDV limitation comes from? Perhaps NI will do a refresh on the cRIO EtherCAT chassis soon and put a bigger FPGA on it.
    1 point
  3. Plotting over a flattened pixmap (rather than incrementally adding to the picture new plot data, that's the trick) can be fast, and has the same cost no matter the previous image content. Like this: I guess that periodically replotting the whole lot of curves would become too expensive even this way. In a case like this perhaps one should manipulate directly the pixmap, like erasing the pixels of the oldest curve first with an xor operation, and then overplotting the newest. Unfortunately the internals of the picture functions, for attempting something like that, are not well documented, IIRC. I think that, much time ago, I ran into some contribution which cleverly worked them out. Maybe some other member is able to fill in?
    1 point
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.