Can't load an edited chip!

classic Classic list List threaded Threaded
16 messages Options
Reply | Threaded
Open this post in threaded view
|

Can't load an edited chip!

cmprice11
Hey all, having issues loading a chip after editing it.
-Running Windows 10.
-I am able to load chips I have not yet edited, and run test scripts on them.
-I tried editing the And.hdl chip, as it's the first chip, in notepad.
-I saved it with the same file name, making sure to use ANSI encoding.
-It saves as 'text documents (.txt)' type in the 'Save as type' box, and the only other option is 'All files (.*)

How do I get the chip loaded?  Thanks!
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

cmprice11
to clarify, it just says "Loading Chip" at the bottom
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

cadet1620
Administrator
There is a bug in the HardwareSimulator that causes it to hang while loading if a Chip tries to use itself in the PARTS: section. This most often happens when students start working on Not.hdl.

CHIP Not {
    ...
    PARTS:
    Not(...);
}

When writing the Not chip, the only part that you can use is Nand.

Once you have successfully tested your Not, then you can use Not in new chips that you write. You should follow the order presented in the book: Not, And, Or, Xor, ... because you need to use the earlier parts to write the later parts.

--Mark
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

cmprice11
Perfect, thank you for the quick and clear response!
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

cmprice11
Just tried And chip after successfully doing Not (using Nand), and it's still stuck on 'Loading Chip...'
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

cadet1620
Administrator
Does your And have an "And(...);" in its PARTS?  It can only use Nand and Not.

--Mark
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

cmprice11
it did, I adjusted.  thanks... i'm new to all this.
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

cadet1620
Administrator
cmprice11 wrote
... i'm new to all this.
My favorite students are people who are eager to learn something completely new!

If you didn't see it, check out the Hardware Construction Survival Kit.

--Mark
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

ivant
In reply to this post by cmprice11
Note that basically all the course tools have some problems like that, even when loading correct definitions or programs. That's why my workflow was to reload new versions of the chips (or programs), but if I see any strange behavior I'd restart the emulator. Also, when I'm finished, I'd run the tests on freshly started simulator to make sure they weren't passing because of a glitch.
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

Lozminda
Hi Everybody
So having gone through all the previously mentioned trouble shooting, The Not gate i've written using the Nand gate won't load.
When i load the test script, The Not gate doesn't appear in the HDL box (i've editted it, the char set is us-ascii) and used only the Nand gate in the "PARTS:" section.
There is a Not.out file in the projects/01 directory which is 0 in size (??).
I'm now completely stuck after a few hours getting to this point, any help much appriciated.
Am running Linux mint MATE 17.1 and java version "1.8.0_181". Thanks in advance.. Loz
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

Lozminda
I've solved my own problem. You have to get the chip exactly right, before it'll work, there don't seem to be any error messages of any description however.... . .
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

xedover
In reply to this post by Lozminda
It could be a simple typo... temporarily post your code here so we can see it (then remove it after we're done).

ah, I see you've fixed your own problem now... yes, computers are quite particular about being very exact :)
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

Lozminda
In reply to this post by Lozminda
So I've done a couple of tests, it would seem that the first not gate, if it doesn't work (ie it's PARTS aren't written in the correct way), it won't load into the Hardwaresimulator.
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

Lozminda
Re Computers being very exact, indeed. But usually they give you some kind of indication when one isn't being so, usually in the form of a handy error message of one sort or another ;-)  
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

Lozminda
Ps Thanks for the quick reply, i was wondering whether anyone was still using this forum etc. Loz
Reply | Threaded
Open this post in threaded view
|

Re: Can't load an edited chip!

xedover
In reply to this post by Lozminda
Error messages are written by the person(s) who wrote the program application's code. And they don't always think of each and every possible test condition. Sometimes one can write hdl input that is so bad, that the program doesn't even know what to do with it, much less give a proper error response.