Multiple serial connections (SPI & I2C at the same time) in Nano IOT 33

There isn't a single function and the indentation is completely off. How can you even make sense of that thing?

What part of the code is working? What part is not? If you break the code into manageable chunks, you will be able to test them one at a time.