for e-bikes at least, it seems that Bosch e-bikes use AES encryption between their controller and the battery, to prevent third-party batteries, perhaps you have knowledge about this, or how it could be possible to circumvent?
Depending on the hardware this can range from needing to attach a debugger to JTAG, to dumping a flash chip, to decapping a microcontroller at the hardest.