From: yu.dongliang <18588496441@163.com> Date: Mon, 11 Sep 2023 05:52:26 +0000 (+0800) Subject: __ses_path_va() X-Git-Url: http://baseworks.info/?a=commitdiff_plain;h=6ca758cb311488b7be3cf79873fe356a29001e50;p=ses.git __ses_path_va() --- diff --git a/ses_step_dc_input.c b/ses_step_dc_input.c index 2daed43..bef68ea 100644 --- a/ses_step_dc_input.c +++ b/ses_step_dc_input.c @@ -17,7 +17,7 @@ static int _dc_input_handler(ScfEfunction* f, int64_t ns, int64_t count, ses_ctx if (SCF_EDA_PIN_IN & el->flags) { - el->v = (0x0) * B->v; + el->v = (i & 0x1) * B->v; el->vconst = 1; scf_logw("IN el: %ld, V: %lg\n", el->id, el->v); diff --git a/ses_step_va.c b/ses_step_va.c index 77be931..d57d842 100644 --- a/ses_step_va.c +++ b/ses_step_va.c @@ -15,6 +15,7 @@ static int __ses_path_split_a(ScfEfunction* f, ses_path_t* path, int i, double* int j; int k; + int n = 0; p = path->pins->data[i]; @@ -67,9 +68,11 @@ static int __ses_path_split_a(ScfEfunction* f, ses_path_t* path, int i, double* int ret = __ses_path_va(f, child); if (ret < 0) return ret; + + n++; } - return 0; + return n; } static int __ses_path_split_v(ScfEfunction* f, ses_path_t* path, ScfEpin* p0, int i, double a, double ja) @@ -108,7 +111,7 @@ static int __ses_path_split_v(ScfEfunction* f, ses_path_t* path, ScfEpin* p0, in ses_ir_u(&v, &jv, a, ja, r, jr); - scf_logd("c%ldp%ld, a: %lg + j%lg, r: %lg + j%lg, v: %lg + j%lg\n", p->cid, p->id, a, ja, r, jr, v, jv); + scf_logd("c%ldp%ld, c%ldp%ld, a: %lg + j%lg, r: %lg + j%lg, v: %lg + j%lg\n", p0->cid, p0->id, p->cid, p->id, a, ja, r, jr, v, jv); } p->v = p0->v - v; @@ -180,7 +183,10 @@ static int __ses_path_va(ScfEfunction* f, ses_path_t* path) if (ret < 0) return ret; - p0 = p; + if (ret > 0) { + p0 = p; + scf_logd("i: %d, p0: c%ldp%ld\n", i, p0->cid, p0->id); + } } else { int ret = __ses_path_split_v(f, path, p0, i, a, ja);