xspice, flip-flops and ram, cast the `ic' PARAM to Digitial_State_t
the *.ifs file claims this parameter to be an integer in range 0..2 meant to represent ZERO, ONE and UNKNOWN
This commit is contained in:
parent
26412f883e
commit
84a69a3896
13
ChangeLog
13
ChangeLog
|
|
@ -1,3 +1,16 @@
|
||||||
|
2010-07-16 Robert Larice
|
||||||
|
* src/xspice/icm/digital/d_dff/cfunc.mod ,
|
||||||
|
* src/xspice/icm/digital/d_dlatch/cfunc.mod ,
|
||||||
|
* src/xspice/icm/digital/d_jkff/cfunc.mod ,
|
||||||
|
* src/xspice/icm/digital/d_srff/cfunc.mod ,
|
||||||
|
* src/xspice/icm/digital/d_srlatch/cfunc.mod ,
|
||||||
|
* src/xspice/icm/digital/d_tff/cfunc.mod :
|
||||||
|
xspice, flip-flops, cast the `ic' PARAM to Digitial_State_t
|
||||||
|
the *.ifs file claims this parameter to be an integer in range 0..2
|
||||||
|
meant to represent ZERO, ONE and UNKNOWN
|
||||||
|
* src/xspice/icm/digital/d_ram/cfunc.mod :
|
||||||
|
xspice, the same fix for `ram'
|
||||||
|
|
||||||
2010-07-16 Robert Larice
|
2010-07-16 Robert Larice
|
||||||
* src/xspice/icm/analog/pwl/cfunc.mod ,
|
* src/xspice/icm/analog/pwl/cfunc.mod ,
|
||||||
* src/xspice/icm/spice2poly/icm_spice2poly/cfunc.mod ,
|
* src/xspice/icm/spice2poly/icm_spice2poly/cfunc.mod ,
|
||||||
|
|
|
||||||
|
|
@ -284,7 +284,7 @@ void cm_d_dff(ARGS)
|
||||||
|
|
||||||
if (0.0 == TIME) { /****** Initial conditions...output w/o delays ******/
|
if (0.0 == TIME) { /****** Initial conditions...output w/o delays ******/
|
||||||
|
|
||||||
temp = PARAM(ic);
|
temp = (Digital_State_t) PARAM(ic);
|
||||||
|
|
||||||
/** Modify output if set or reset lines are active **/
|
/** Modify output if set or reset lines are active **/
|
||||||
if ( (*set==ONE) && (*reset==ZERO) ) temp = ONE;
|
if ( (*set==ONE) && (*reset==ZERO) ) temp = ONE;
|
||||||
|
|
|
||||||
|
|
@ -289,7 +289,7 @@ void cm_d_dlatch(ARGS)
|
||||||
|
|
||||||
if (0.0 == TIME) { /****** DC analysis...output w/o delays ******/
|
if (0.0 == TIME) { /****** DC analysis...output w/o delays ******/
|
||||||
|
|
||||||
temp = PARAM(ic);
|
temp = (Digital_State_t) PARAM(ic);
|
||||||
|
|
||||||
/** Modify output if set or reset lines are active **/
|
/** Modify output if set or reset lines are active **/
|
||||||
if (*enable==ONE) temp = *data;
|
if (*enable==ONE) temp = *data;
|
||||||
|
|
|
||||||
|
|
@ -374,7 +374,7 @@ void cm_d_jkff(ARGS)
|
||||||
|
|
||||||
if (0.0 == TIME) { /****** DC analysis...output w/o delays ******/
|
if (0.0 == TIME) { /****** DC analysis...output w/o delays ******/
|
||||||
|
|
||||||
temp = PARAM(ic);
|
temp = (Digital_State_t) PARAM(ic);
|
||||||
|
|
||||||
/** Modify output if set or reset lines are active **/
|
/** Modify output if set or reset lines are active **/
|
||||||
if ( (*set==ONE) && (*reset==ZERO) ) temp = ONE;
|
if ( (*set==ONE) && (*reset==ZERO) ) temp = ONE;
|
||||||
|
|
|
||||||
|
|
@ -1046,7 +1046,7 @@ void cm_d_ram(ARGS)
|
||||||
|
|
||||||
/** initialize ram to ic value **/
|
/** initialize ram to ic value **/
|
||||||
|
|
||||||
out = PARAM(ic);
|
out = (Digital_State_t) PARAM(ic);
|
||||||
for (i=0; i<word_width; i++) {
|
for (i=0; i<word_width; i++) {
|
||||||
for (j=0; j<ram_size; j++) {
|
for (j=0; j<ram_size; j++) {
|
||||||
cm_initialize_ram(out,word_width,i,j,ram);
|
cm_initialize_ram(out,word_width,i,j,ram);
|
||||||
|
|
@ -1056,7 +1056,7 @@ void cm_d_ram(ARGS)
|
||||||
if ( (ONE==*select) && (ZERO==*write_en) ) {
|
if ( (ONE==*select) && (ZERO==*write_en) ) {
|
||||||
/* output STRONG initial conditions */
|
/* output STRONG initial conditions */
|
||||||
for (i=0; i<word_width; i++) {
|
for (i=0; i<word_width; i++) {
|
||||||
OUTPUT_STATE(data_out[i]) = PARAM(ic);
|
OUTPUT_STATE(data_out[i]) = (Digital_State_t) PARAM(ic);
|
||||||
OUTPUT_STRENGTH(data_out[i]) = STRONG;
|
OUTPUT_STRENGTH(data_out[i]) = STRONG;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -370,7 +370,7 @@ void cm_d_srff(ARGS)
|
||||||
|
|
||||||
if (0.0 == TIME) { /****** DC analysis...output w/o delays ******/
|
if (0.0 == TIME) { /****** DC analysis...output w/o delays ******/
|
||||||
|
|
||||||
temp = PARAM(ic);
|
temp = (Digital_State_t) PARAM(ic);
|
||||||
|
|
||||||
/** Modify output if set or reset lines are active **/
|
/** Modify output if set or reset lines are active **/
|
||||||
if ( (*set==ONE) && (*reset==ZERO) ) temp = ONE;
|
if ( (*set==ONE) && (*reset==ZERO) ) temp = ONE;
|
||||||
|
|
|
||||||
|
|
@ -384,7 +384,7 @@ void cm_d_srlatch(ARGS)
|
||||||
|
|
||||||
if (0.0 == TIME) { /****** DC analysis...output w/o delays ******/
|
if (0.0 == TIME) { /****** DC analysis...output w/o delays ******/
|
||||||
|
|
||||||
temp = PARAM(ic);
|
temp = (Digital_State_t) PARAM(ic);
|
||||||
|
|
||||||
/** Modify output if set or reset lines are active **/
|
/** Modify output if set or reset lines are active **/
|
||||||
if ( (*enable==ONE) && (*s==ONE) && (*r==ZERO) ) temp = ONE;
|
if ( (*enable==ONE) && (*s==ONE) && (*r==ZERO) ) temp = ONE;
|
||||||
|
|
|
||||||
|
|
@ -297,7 +297,7 @@ void cm_d_tff(ARGS)
|
||||||
|
|
||||||
if (0.0 == TIME) { /****** DC analysis...output w/o delays ******/
|
if (0.0 == TIME) { /****** DC analysis...output w/o delays ******/
|
||||||
|
|
||||||
temp = PARAM(ic);
|
temp = (Digital_State_t) PARAM(ic);
|
||||||
|
|
||||||
/** Modify output if set or reset lines are active **/
|
/** Modify output if set or reset lines are active **/
|
||||||
if ( (*set==ONE) && (*reset==ZERO) ) temp = ONE;
|
if ( (*set==ONE) && (*reset==ZERO) ) temp = ONE;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue