How to send to i2c PCA9685 PWM driver from Oopsy patch

Hello guys,
a little bit late to the party I guess, but I’m trying to use this driver on my Patch_SM with Oopsy and I receive the “compiler error” message when trying to upload the patch on my board. I’m currently using this json, removed all the knobs and switches controls to focus on the leds declaration. Also the patch it’s pretty basic: a single knob controlling the brightness of the red pin of the first rgb.

I’m a little bit confused on how to declare the driver and the leds inside the json file, but I really do not understand what I’m missing, can anyone help?

{
  "name": "testrgb3",
  "som": "patch_sm",
  "audio": {
    "channels": 2
  },
  "parents": {
    "i2c": {
      "component": "i2c",
      "pin": {
        "scl": "B8",
        "sda": "B7"
      }
    },
    "led_driver": {
      "component": "PCA9685",
      "address": "{0x40}",
      "parent": "i2c",
      "driver_count": 1
    }
  },
  "components": {
    "led_1": {
      "component": "Led",
      "index": 0,
      "parent": "led_driver"
    },
    "cv_1": {
        "component": "AnalogControl",
	"pin": "C5"
    }
  },
  "aliases": {
    "knob": "cv_1",
    "knob1": "cv_1",
    "ctrl": "cv_1",
    "ctrl1": "cv_1"
  }
}

hi sawtooth,

i may not be much help as i am clueless and just learning, but this is the json that worked for me - assigning each led of the driver as a component so i can address it in the pd patch…. it worked and i got all the leds as a ring shaped phase sweep of my lfo - happy - but yet to put it all together into hardware….

other more experienced users may be of more help in terms of details that i have forgotten or fudged in….

{
  "name": "newlfotrial",
  "som": "seed",
  "audio": {
    "channels": 2
  },
  "parents": {
    "i2c": {
      "component": "i2c",
      "pin": {
        "scl": 11,
        "sda": 12
      }
    },
    "led_driver": {
      "component": "PCA9685",
      "address": "{0x40}",
      "parent": "i2c",
      "driver_count": 1
    }
  },
"components": {
    "knob_1": {
      "component": "AnalogControl",
      "pin": 15
    },
    "knob_2": {
      "component": "AnalogControl",
      "pin": 16
    },
    "led_1": {
      "component": "PCA9685Led",
      "index": 0,
      "parent": "led_driver"
    },
    "led_2": {
      "component": "PCA9685Led",
      "index": 1,
      "parent": "led_driver"
    },
    "led_3": {
      "component": "PCA9685Led",
      "index": 2,
      "parent": "led_driver"
    },
    "led_4": {
      "component": "PCA9685Led",
      "index": 3,
      "parent": "led_driver"
    },
    "led_5": {
      "component": "PCA9685Led",
      "index": 4,
      "parent": "led_driver"
    },
    "led_6": {
      "component": "PCA9685Led",
      "index": 5,
      "parent": "led_driver"
    },
    "led_7": {
      "component": "PCA9685Led",
      "index": 6,
      "parent": "led_driver"
    },
    "led_8": {
      "component": "PCA9685Led",
      "index": 7,
      "parent": "led_driver"
    },
    "led_9": {
      "component": "PCA9685Led",
      "index": 8,
      "parent": "led_driver"
    },
    "led_10": {
      "component": "PCA9685Led",
      "index": 9,
      "parent": "led_driver"
    },
    "led_11": {
      "component": "PCA9685Led",
      "index": 10,
      "parent": "led_driver"
    },
    "led_12": {
      "component": "PCA9685Led",
      "index": 11,
      "parent": "led_driver"
    },
    "led_13": {
      "component": "PCA9685Led",
      "index": 12,
      "parent": "led_driver"
    },
    "led_14": {
      "component": "PCA9685Led",
      "index": 13,
      "parent": "led_driver"
    },
    "led_15": {
      "component": "PCA9685Led",
      "index": 14,
      "parent": "led_driver"
    },
    "led_16": {
      "component": "PCA9685Led",
      "index": 15,
      "parent": "led_driver"
    }
  }
}

if it was me, i would first change the “Led” to ““PCA9685” as you have assigned it earlier in the json - in this part -
“components”: {
“led_1”: {
“component”: “Led”,
“index”: 0,
“parent”: “led_driver”

Since I can’t support Oopsy I’ve moved your question to a new topic in the Gen~ section of the forum.
It’s best to not combine the information of these different environments as their support is very very different :slight_smile:

Hi @dreamer, thanks a lot for moving my question in a new topic and sorry for the confusion this may have caused!

Thanks for your suggestion @albertpaca, but if I use "component": "PCA9685Led" I get the compiler error message: “node.script: undefined component kind: PCA9685Led”. The same error appears if I replace it with "component": "PCA9685”.

The Json files are correct, I actually verified them with an online json validator, so I’m starting thinking there may be some problems with my Oopsy (??). I actually re-installed it via gitclone but nothing changed.