Sparkette Posted September 10, 2014 Report Share Posted September 10, 2014 (edited) I'm looking at the XNodes included in the FPGA toolkit, for instance vi.lib\eio\EIONode\EIONode.xnode, and I notice there's only a few abilities, and many important ones are missing. Like the GetImage ability. How are these XNodes drawing graphics, etc. without these abilities? I do see some VI's in the same folder that would draw the image, but they don't seem to be referenced by the XNode. So how does this work? Similarly, the "function block" XNodes in the RT module respond to a "CONFIG" message to open the properties dialog. However, if I create my own XNode with a Message ability, it doesn't even receive those messages. Why is that? (Topic mentions both FPGA and XNodes; no telling who will post here! ) Edited September 10, 2014 by flarn2006 Quote Link to comment
shoneill Posted September 10, 2014 Report Share Posted September 10, 2014 They are "abstract" Xnodes which are overridden by the distinct implementation depending ont he hardware target actually being used. Nah, just kidding, I have no idea whatsoever. I've never actually looked at XNodes, but I welcome the discussion. Quote Link to comment
hooovahh Posted September 10, 2014 Report Share Posted September 10, 2014 Nah, just kidding, I have no idea whatsoever. I've never actually looked at XNodes, but I welcome the discussion. I almost believed you for a bit because FPGA code does do some weird things. I don't know if this is the case still or not, but at one point there were express VIs that you could open the block diagram of. If you kept drilling down into the VI you eventually found a subVI with no G code, only a single comment on the block diagram, and no objects on the front panel. The comment was a string of characters referencing the already compiled VHDL code to insert. I'm guessing the code just couldn't be easily represented in LabVIEW and NI just inserted some already compiled code to do the work. As for the XNode, add a breakpoint to one of the subVIs you think is drawing the icon, and save it. If that code does draw the node it should call it and break. Now why it gets called is a different question. Quote Link to comment
shoneill Posted September 10, 2014 Report Share Posted September 10, 2014 (edited) Well let's just call it an educated guess. With a lot more "guess" then "educated". But I DO know that each target has specific impelmentations of most FPGA nodes so I could well imagine something like this being handled in the background. Perhaps the XNodes are themselves created by other XNodes depending on the target being chosen. Again, I have NO data leading me to think this, it's just intuition. And guessing, did I mention that already? Edited September 10, 2014 by shoneill Quote Link to comment
Darren Posted September 10, 2014 Report Share Posted September 10, 2014 Those are probably Hybrid XNodes. It's a special kind of XNode that uses C code instead of G code to implement some of the more common abilities. P.S. - I've never written a Hybrid XNode, and I have no idea how to create them. I just know they exist, and I'm fairly certain they were used for Function Blocks. 1 Quote Link to comment
hooovahh Posted September 10, 2014 Report Share Posted September 10, 2014 Those are probably Hybrid XNodes. It's a special kind of XNode that uses C code instead of G code to implement some of the more common abilities. A new technology developed by NI that has never been mentioned before? How many levels of management at NI did your post have to go through? Quote Link to comment
Darren Posted September 10, 2014 Report Share Posted September 10, 2014 How many levels of management at NI did your post have to go through? Zero. And now you have an explanation if my post suddenly disappears. 2 Quote Link to comment
lordexod Posted September 11, 2014 Report Share Posted September 11, 2014 FPGA component consists of two parts. 1. Normal XNode, ExternalNode, VI. 2. Module Generator "ModGen", config file: *.mgn, ModGen SDK: vi.lib\rvi\ClientSDK\Core\ModuleGeneration. Quote Link to comment
danielb Posted November 24, 2015 Report Share Posted November 24, 2015 Okay, I so there is some interesting information here, but it doesn't really help me solve the thing I want to do right now. I have a cRIO + FPGA Interface project, the targets (and all c-Series modules) have already been discovered and added to the Project. [some preprocessing not related to this topic but any pointers would still be appreciated, haven't got this one running yet either] I also have a table of mappings from hardware resources to channel name, e.g. "Mod6/AI9" -> "p_stat_oil_01". Now I would like to automatically rename these hardware ressources with VI Scripting to achieve something like this: [end of the off-topic part] Next step would be to select specific channels (defined as a list of channel names) and bundle them. Should look something like this: All the wiring is already scripted and works reasonably well, but I can't figure out a way to expand the EIONode (on the left) and select the appropriate channels. Is this possible? This will be a task I have to do repeatedly and I'd really like to automate it, because it is both prone to errors and very very tedious. 1 Quote Link to comment
hooovahh Posted November 24, 2015 Report Share Posted November 24, 2015 [end of the off-topic part] Are you sure? Because nothing in your reply has anything to do with XNodes, Hybrid XNodes, abilities, or anything this thread is about. If you have a question not related to the topic, then please don't reply to that topic. Make your own thread on LAVA, or on the dark side (forums.ni.com) in the appropriate subforum. As for your specific question, I've never done that in scripting but I always assumed it was possible. Quote Link to comment
danielb Posted November 24, 2015 Report Share Posted November 24, 2015 To be honest, my understanding of XNodes is very very limited at this point. From the little information I found, the EIONode seemed to be a Hybrid XNode. It is entirely possible that I misinterpreted the information I found, but for the life of me I wasn't able to find other Information on those EIONodes. I have found out that they don't live in the normal class hierarchy (no child of GObject, at least not documented), but can be cast to "Node". I wasn't able to completely access the nodes functionality though, and IIRC Darren mentioned in another topic that this is somehow related to them being hybrid XNodes. So in my mind this question was at least somewhat fitting for this topic. If you are positive that the two topics are unrelated I will create a new thread. Quote Link to comment
hooovahh Posted November 24, 2015 Report Share Posted November 24, 2015 If you are positive that the two topics are unrelated I will create a new thread. Nope I'm not. I didn't make the connection that you were attempting to use scripting to change XNodes, sorry. Quote Link to comment
Darren Posted November 24, 2015 Report Share Posted November 24, 2015 There are undocumented, unsupported scripting APIs for the FPGA nodes located here: vi.lib\rvi\ClientSDK\Core\Script I have talked about this API a few times on the NI forums, as have others. You can google that vi.lib path to find some of the posts related to this topic. 1 Quote Link to comment
danielb Posted November 26, 2015 Report Share Posted November 26, 2015 Ah fantastic, I'll look into it, thank you. My Google-Fu wasn't strong enough, it's sort of hard when you don't really know the name of the thing you want to know more about. So thanks for that Quote Link to comment
infinitenothing Posted April 6, 2022 Report Share Posted April 6, 2022 @Darren As far as I could tell, none of those nodes deal with the hardware io nodes I did find a couple nodes in the LabVIEW 2020\resource\Framework\Providers\lveio\ and vi.lib\eio\ folders that sort of seemed to work I still couldn't get grow to work. Here's the closest I could get fpga script.zip Quote Link to comment
ensegre Posted October 3, 2022 Report Share Posted October 3, 2022 @infinitenothing, I think I can do what you & danield were looking for, by using first EIOPlaceDownEIONode.vi with an empty State, and then iteratively adding channels with EIONode_ScriptAddChannel.vi, simply providing the channel name. Using LV2014 (for legacy FPGA support), the VIs are in C:\Program Files (x86)\National Instruments\LabVIEW 2014\vi.lib\eio\EIONode. At first was that I was trying to call only EIOPlaceDownEIONode with a populated State array, but that has too many fields to fill in which I wasn't able to guess nor to retrieve from a working example; only passing 'alias' is not sufficient to link with the right resource. So yes, this is actually OT because it is not about Hybrid Xnodes or whatever... 1 Quote Link to comment
Rolf Kalbermatter Posted November 11, 2022 Report Share Posted November 11, 2022 On 10/3/2022 at 6:51 PM, ensegre said: So yes, this is actually OT because it is not about Hybrid Xnodes or whatever... Are you sure the Elemental IO nodes are not actually Hybrid XNodes under the hood? There used to be a Toolkit that you could get after signing an NDA, swearing on your mothers health to never talk about it to anyone and making a secret voodoo dance, about how to create Elemental IO Nodes. It was required for anyone designing their own C modules to be put into a cRIO chassis when wanting to provide an API to access that module. With the current state of green NI, it may be however pretty impossible to get that anymore. Quote Link to comment
ensegre Posted November 11, 2022 Report Share Posted November 11, 2022 48 minutes ago, Rolf Kalbermatter said: Are you sure the Elemental IO nodes are not actually Hybrid XNodes under the hood? 🤷♂️ I came up with this without swearing, though. In truth I still have to test it for real (meaning, that it really compiles smoothly on a target, not just no broken arrow). My goal was to get the job done, not to learn the theory of Xnodes.... 1 Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.