> I have to send an array from an arduino to a raspberry pi but I have
> problems with the python code. Please, can you give an example to receive
There's no such thing as "sending an array". In a situation such as
this you'd typically send the length of the array first, and then
you'd just loop over the array sending each of the data values.
I've not done any i2c programming for ages, but in (very rough)
pseudo-code you could do something like:
my_array_length = read_number()
my_array = list()
while my_array_length > 0:
my_array.append(read_number())
my_array_length -= 1
Andrew