ScfEpin* Bp;
ScfEpin* Bn;
- size_t i;
- size_t j;
- size_t k;
-
B = f->components[0];
Bp = B->pins[SCF_EDA_Battery_POS];
Bn = B->pins[SCF_EDA_Battery_NEG];
printf("\n*******************\n");
+ int i;
+
for (i = 0; i < ctx->paths->size; i++) {
path = ctx->paths->data[i];
- scf_logi("i: %ld, path->type: %d\n", i, path->type);
+ scf_logi("i: %d, path->type: %d\n", i, path->type);
if (path->pins->size < 2) {
scf_loge("\n");
static int _va_balance_handler(ScfEfunction* f, int64_t ns, int64_t count, ses_ctx_t* ctx)
{
+ ses_path_t* path;
+ ScfEcomponent* B;
+ ScfEpin* p0;
+ ScfEpin* p1;
+ ScfEpin* Bp;
+ ScfEpin* Bn;
+
+ B = f->components[0];
+ Bp = B->pins[SCF_EDA_Battery_POS];
+ Bn = B->pins[SCF_EDA_Battery_NEG];
+
+ printf("\n*******************\n");
+
+ int i;
+
+ for (i = 0; i < ctx->paths->size; i++) {
+ path = ctx->paths->data[i];
+
+ if (path->pins->size < 2) {
+ scf_loge("\n");
+ return -EINVAL;
+ }
+
+ p0 = path->pins->data[0];
+ p1 = path->pins->data[path->pins->size - 1];
+
+ if (p0->lid == Bp->lid || p1->lid == Bn->lid)
+ continue;
+
+ scf_logi("i: %d, path->type: %d\n", i, path->type);
+
+ ses_path_print(path);
+#if 0
+ int ret = __ses_path_va(f, path);
+ if (ret < 0)
+ return ret;
+#endif
+ printf("\n");
+ }
+
return 0;
}