Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

lattice gal22v10

Status
Not open for further replies.

fedail

New Member
i have write program and with isplerver classic to do and with gal22v10

and when i download it at ic it is work like Nand why

this program

==================
MODULE Gal22v10

TITLE 'test'

input_1,input_2 pin 2,3;
output_q pin 15;

Equations

output_q = input_1 & input_2;

END
=================

i suggues there is inverter at all pins so i want to make this like this !
 
S0 & S1 are programmable, i.e the output of the OLMC is programmable for active high or active low. A quick read of the data sheet should clear up any misunderstandings.

If the Jedec compiler you are using does not allow those bits to be defined, the device will default to it's standard OLMC mapping. Given that there is a negation circle in the layout map for each output buffer, and that the device has active pull-ups on every pin, I would assume the device will default to active low outputs.

You could always use /output_q = input_1 * input_2 to achieve a logical AND


rgds
 
but the pin 15 is not work if don't programe it

i have program pins and the apl language use & for and

if you use this program and test it befor i will test ur example
 
fedail said:
but the pin 15 is not work if don't programe it

i have program pins and the apl language use & for and

if you use this program and test it befor i will test ur example


Most Jedec compatible compilers will support at the least the following command operators:-

/ - invert - Precedence (4 Highest)
! - invert - Precedence (4)
* - Logical AND - Precedence (3)
& - Logical AND - Precedence (3)
| - Logical OR - Precedence (2)
+ - Logical OR - Precedence (2)
^ - Logical XOR - Precedence (1)
$ - Logical XOR - Precedence (1)
:+: - Logical XOR - Precedence (1)
= - Assignment - Precedence (0)
:= - Registered Assignment - Precedence (0 Lowest)

comments can use either a semicolon ( ; ) or curly brackets {}
e.g
;this is a comment

{both of these lines
are comments}

At the very least you should have a :-

Header
A Declaration Block
An Equation Block


Anything before the Declaration Block will be treated as a file header, this will be passed as the header for each generated file.

The Declaration Block is where your Device Identifier Keyword, usually just "CHIP", Pin List, and any compiler directives go. It's always a good idea to pre-define the complete pin list, you can edit whatever you need to change later. Anything before your Keyword will be treated as the file header.

Anything before your Equation Block will be treated as the Declaration Block.

After the Equation Block Identifier Keyword, usually just "EQUATIONS", the compiler will expect your equations using the various operators etc.
Some compilers like to have an "END" keyword after your equations to signify the end of the equations, others just read till they find an eof and treat that as the end of equations.

I suggest that you read up a little on the use of your compiler, the various meanings and significance of the operators, the compiler directives and syntax supported, and obviously the datasheet for the device you are using. The outline above may be different to the way your compiler expects things.

Hope this helps you :)

rgds
 
Last edited:
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top