VHDL What does this error mean, Net, "Name", which fans out to "*name*", cannot be assigned more than one value - vhdl

Part of my project is to design a 16bit Multiplier with an arrayMultiplier structure. In this array Multiplier instead of using 1 bit adders, I made a 16bit Adder (which is working, I've done simulations). I'm using it as a component in the multiplier.
Note I have attach my last name to every variable according to the professor, please ignore that
I have to put it into a pastebin cause it's too long for posting. Please ignore the comments that say like +16, FA, -1. This is for me to just follow a diagram for proper indexing.
This is an example diagram
https://d2vlcm61l7u1fs.cloudfront.net/media%2F27b%2F27b41d2f-aa6c-4a81-bdc0-16ff1c681fc7%2FphpQ0V3VI.png
**REDACTED **
Third is the error itself
Code Redacted
https://pastebin.com/tZ6ptLYp
I'm not sure what the error is saying so I can't solve the issue. Been working on this for hours so maybe I'm just tired and am not seeing it. Thanks

The problem is that you bind multiple wires to the same output wire.
For example :
Line 57 : ... Arena_16bitOUT_Cout_fa => Arena_Cout_vec(0) ...
Line 61 : ... Arena_16bitOUT_Cout_fa => Arena_Cout_vec(0));
I guess it is just copy/paste errors. I did not read all the logic but if it is not the case, you will need some multiplexing logic.

Related

To build a flow using Power Automate to download linked csv report in gmail

I'm trying to create a flow using Power Automate (which I'm quite new to) that can get the link/URL in an email I receive daily, then download the .csv file that normally a click to the link would do, and then save the file to a given local folder.
An example of the email I get:
Screenshot of the email I get daily
I searched in Power Automate Community and found this insightful LINK post & answer almost solved it. However, after following the steps and built the flow, it kept failing at the Compose step.
Screenshot of the Flow & Error Message
The flow
Error message
Expression used:
substring(body('Html_to_text'),add(indexOf(body('Html_to_text'),'here'),5),sub(indexOf(body('Html_to_text'),'Name'),5))
Seems the expression couldn't really get the URL/Link? I'm not sure and searched but couldn't find any more posts that can help.
Please kindly share all insights on approaches or workarounds that you think may help me solve the problem and truly thanks!
PPPPPPPPisces
We need to breakdown the bits of the function here which needs 3 bits of info
substring(1 text to search, 2 starting position of the text you want, 3 length of text)
For example, if you were trying to return an unknown number from the text dog 4567 bird
Our function would have 3 parts.
body('Html_to_text'), this bit gets the text we are searching for
add(indexOf(body('Html_to_text'),'dog'),4), this bit finds the position in the text 4 characters after the start of the word dog (3 letters for dog + the space)
sub(sub(indexOf(body('Html_to_text'),'bird'),2)),add(indexOf(body('Html_to_text'),'dog'),4)), I've changed the structure of your code here because this part needs to return the length of the URL, not the ending position. So here, we take the position of the end of the URL (position of the word bird minus two spaces) and subtract it from the position of the start of the URL (position of the word dog + 4 spaces) to get the length.
In your HTML to text output, you need to check what the HTML looks like, and search for a word before the URL starts, and a word after the URL starts, and count the exact amount of spaces to reach the URL. You can then put those words and counts into your code.
More generally, when you have a complicated problem that you need to troubleshoot, you can break it down into steps. For example. Rather than putting that big mess of code into a single block, you can make each chunk of the code in its own compose, and then one final compose to bring them all together - that way when you run it you can see what information each bit is giving out, or where it is failing, and experiment from there to discover what is wrong.

Change the way an object is displayed in debugger/inspector variable-value table

I would like to know if there is a message I can override in Pharo so that my custom classes display more descriptive information in the inspector/debuger much like simple variable types do, like Integers or Strings. For instance:
Instead of that, I would like it to show a more custom and informative description consisting of its internal variales so as to have a tighter/tidier view of the variables instead of having to click on it and open another chart (therefore losing sight of the information on the previous chart). I know you can increase the amount of charts shown below, but that is not the point of the question. I would like to achieve something like this:
I have browsed the pharo forums and found nothing, I have also tried overriding over 30 methods hoping that one of them changed the output. Only the class message seemed to change the output, but I could only return an instance of Metaclass and besides messing with this message would break a lot of stuff. Finally I tried to reverse engineer the debugger and then the inspector to see at which point is the table constructed and what values are used or which messages are sent to build said values, but it was just too much for me, the callstack kept growing and I couldn't even scratch the surface.
Luckily, doing this in any Smalltalk is very easy. Types inherited from Object are expected to answer to the message printString, and ultimately printOn: aStream. Those messages are expected to give a description of the object. So, you should just override printOn: in your class (printString uses printOn:) and all the browsers and inspectors will automatically use it. There other possibilities in Pharo, if you want to provide more complex information in different tabs, but I think printOn: will suffice for you.
An example would be:
MyPoint>>printOn: aStream
aStream nextPut: ${.
x printOn: aStream.
aStream nextPutAll: ', '
y printOn: aStream.
aStream nextPut: $}
In Smalltalk, every time you observe something you don't like or understand, you ask the question: Which message is doing this?
In your case, the question would be: Which message creates the string a MyPoint that I see everywhere?
Next, to answer your question you need to find a good place for inserting a halt and then debug from there until you find the culprit. To do this just find the simplest expression that would reproduce the issue and debug it. In your case the right-click command in the Playground will do. So,
Write and select (MyPoint on: 14 and: -5) halt in a Playground.
Right-click and issue the Print it command (I'm assuming you already checked that this command produces the string 'a MyPoint').
Debug
Go over the evaluation of #DoIt, which answers the result
Continue this way alternating between Into and Over to make sure you follow the result to where it's being taken
Eventually you will reach the implementation of Object >> #printString. Bingo!
Now you can open a System Browser and take a look at this method, study how it's been implemented in different classes, etc. Your investigation should show you that the most basic message for printing is #printOn:. You may also want to take a look at other implementors so to better understand what people usually do. (Bear in mind that writing good #printOn:s is a minimalist art)
Overriding printOn: will work for simple cases where you want to just change description.
Pharo allows a lot more than that!
Due the extensible (moldable) nature of our inspector, you do not need to override a method to get your own visualisation of the object.
For example, look this array visualisation:
This is obtained adding this method to Collection:
gtInspectorItemsIn: composite
<gtInspectorPresentationOrder: 0>
^ composite fastList
title: 'Items';
display: [ self asOrderedCollection ];
beMultiple;
format: [ :each | GTObjectPrinter asTruncatedTextFrom: each ];
send: [ :result |
result
ifNil: [ nil ]
ifNotNil: [ result size = 1
ifTrue: [ result anyOne ]
ifFalse: [ self species withAll: result ]
]
]
if you browse for senders of gtInspectorPresentationOrder: you will see there are already a lot of special visualisations in the image.
You can take those as an example on how to create your own, adapted exactly to what you need :)

How to put 7 events in one eventset in PAPI

In PAPI Im trying to put 7 events in one eventset so I can read 7 results in one operation but I always get return -1 ,can anyone help me?my code like this:
int events1[] = {
PAPI_L1_TCM,
PAPI_L2_TCM,
PAPI_L3_TCM,
PAPI_MEM_WCY,
PAPI_RES_STL,
PAPI_TLB_DM,
PAPI_TLB_IM};
PAPI_library_init(PAPI_VER_CURRENT);
i = PAPI_start_counters(events1,7);
where i appears to be -1 which means PAPI_EINVAL.
I tried change the value PAPI_NUM_TLS but it didn't work.
I have the same problem now. But as I have found, the trouble comes from 5th and 6th counters. Here: https://icl.cs.utk.edu/projects/papi/wiki/PAPI3:PAPI_add_event.3
at IBM POWER6 NOTES there is mentioned that these two counters are specific and as I understand should count concrete events. I have not found the solution yet. For 5th one, I added PAPI_TOT_INS and seems to work but for 6th one PAPI_TOT_CYC gives PAPI_ECNFLCT error as they say.

VBScript - RANDOMIZE (Cbyte(Left(Right(Time(),5),2))) throws 500 for ES locales

Using a standard VBScript Randomize statement (below) which works fine -- most of the time.
...RANDOMIZE (Cbyte(Left(Right(Time(),5),2)))
RANDOMIZE...
It took a bit, but in digging thru log files, I've noticed that it throws this 500 error:
Type mismatch: 'Cbyte'
when the users' languages are non-English.
I tried changing the Session.LCID (I'm using Classic ASP) in a test page but no effect.
Any suggestions for fixing or a work-around? Thank you...
It appears you're trying to randomise based on the seconds-within-the-minute value:
12:34:56 AM
|---|
56 AM (right(5))
||
56 (left(2))
Now I have no idea of the top of my head what Time() would return in a Spanish locale, but it may well be something like 12:34:56 de la mañana.
What I do know is that relying on a specific presentation format in a globalised world is a bad idea. In your case, it may involve trying to convert left(right("12:34:56 de la mañana",5),2), or "añ", into a numeric value, something it's not going to be happy with.
If you want a true root cause analysis, I'd suggest catching the conversion error and actually logging what Time() is presenting itself as when it errors.
If you just want to fix it, find a way to get the seconds that doesn't depend on locale, for example:
secs = Second(Time())
As an aside, I'm not sure why you think this is even needed. The documentation for the VBScript Randomise function states that, if an argument is not given, the value returned by the system timer is used as the new seed value. Hence it's already based on the current time.

Prolog syntax error operator expected

It says there's an error operator expected. I know this syntax error is in line 5 but I can't figure it out. I have highlighted that line with ** thx.
action(X : Y,0 : Y):-X>0.
action(X : Y,X : 0):-Y>0.
action(X : Y,4:Y):-X<4.
action(X : Y,X : 3):-Y<3.
**action(X : Y,4 : Z):- X<4, Z is Y−(4−X), Z>=0.**
Path(X):-
path(0 : 0,[0 : 0],X).
Prolog predicate names must begin with a lower case letter. So as #CapelliC points out, Path(X) :0-... is going to be a problem.
But your syntax error on line 5 is because you copy/pasted this code from something online or from an eBook perhaps. In your expression, Y−(4−X) those − symbols are not minuses but something else that look like minuses (perhaps EM dashes). Try retyping line 5 manually, and the problem will go away.
This one is a problem:
Y−(4−X)
And this one is correct:
Y-(4-X)
There is actually a subtle difference in length of the dash you can see if you look closely. The second example is an actual dash or minus (ASCII code hex 2d). The first example of a dash is a special character (a hex dump shows a character code of 59 88 92). This is an issue with copy/pasting code from an eBook or other electronic document, since there are several characters used for visual convenience that aren't the specific one required by the language.
the error is the clause following
Path(X):-
...
should be
path(X):-
...

Resources