Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
VAMS-LRM-2-3-1.pdf
Скачиваний:
43
Добавлен:
05.06.2015
Размер:
3.73 Mб
Скачать

 

Accellera

Analog and Mixed-signal Extensions to Verilog HDL

Version 2.3.1, June 1, 2009

analog begin

 

@(timer(0, period))

 

x = $random + 0.5;

 

V(out) <+ transition( x, 0.0, period/100.0 );

 

end

 

endmodule

 

5.10.4 Named events

An identifier declared as an event data type is called a named event. A named event is triggered explicitly and is used in an event expression to control the execution of procedural statements in the same manner as event control described in 5.10. Named events can be triggered from always and initial blocks, or from an analog event statement. This allows control over the enabling of multiple actions in other procedures.

An event name shall be declared explicitly before it is used. Syntax 5-19 gives the syntax for declaring events.

event_declaration ::= event list_of_event_identifiers ;// from A.2.1.3

list_of_event_identifiers ::= event_identifier { dimension } { , event_identifier { dimension }// from A.2.3 dimension ::= [ dimension_constant_expression : dimension_constant_expression ] // from A.2.5

Syntax 5-19—Syntax for event declaration

A declared event is made to occur by the activation of an event triggering statement with the syntax given in Syntax 5-20. An event is not made to occur by changing the index of an event array in an event control expression.

event_trigger ::=// from A.6.5

-> hierarchical_event_identifier { [ expression ] } ;

Syntax 5-20—Syntax for event trigger

An event-controlled statement (for example, @trig rega = regb;) shall cause simulation of its containing procedure to wait until some other procedure executes the appropriate event-triggering statement (for example, -> trig).

Named events and event control give a powerful and efficient means of describing the communication between, and synchronization of, two or more concurrently active processes. A basic example of this is a small waveform clock generator that synchronizes control of a synchronous circuit by signalling the occurrence of an explicit event periodically while the circuit waits for the event to occur.

5.10.5 Digital events in analog behavior

To model mixed signal functionality, analog behavior can be made sensitive to digital events, including posedge events, negedge events, state change events, and named events.

117

Copyright © 2009 Accellera Organization, Inc. All rights reserved.

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]