Unable to combine SPI radio and i2c sensor in same code

Hi,

I am using an Adafruit RFM69HCW to received messages from a remote sensor (which works fine).
Also a local SHT35D board from closedcube (this also works fine).
Everything works until i combine the 2 devices, the only thing that is shared between them is voltage and ground together with the Arduino MKR1010 Wifi.
My suspicion is that the libraries from each of the devices are incompatible but i am clueless at this point.

PIN 11 & 12 are to the sensor
PIN 5,6,7,8,9,10 are to the radio

This is the Radiohead fork for the adafruit radio: GitHub - adafruit/RadioHead: A github'ified version of http://www.airspayce.com/mikem/arduino/RadioHead/
Here is the library for the SHT sensor: GitHub - closedcube/ClosedCube_SHT31D_Arduino: Arduino library for ClosedCube SHT31-D (SHT30-D, SHT35-D) Digital Humidity & Temperature Sensor breakout board

Here is my code:

#include <SPI.h>
#include <RH_RF69.h>
#include <WiFiNINA.h>
#include <ClosedCube_SHT31D.h>
#include <Wire.h>

#define SECRET_SSID "xxxx"
#define SECRET_PASS "xxxx"

// wifi setup
char ssid[] = SECRET_SSID;
char pass[] = SECRET_PASS;
int status = WL_IDLE_STATUS;

WiFiClient client;

ClosedCube_SHT31D sht3xd;

/************ Radio Setup ***************/

// Change to 434.0 or other frequency, must match RX's freq!
#define RF69_FREQ 868.0
#define RFM69_INT     7
#define RFM69_CS      6
#define RFM69_RST     5
#define LED           13
#define TX_POWER      20

// Singleton instance of the radio driver
RH_RF69 rf69(RFM69_CS, RFM69_INT);

void setup() 
{
  Serial.begin(9600);
  while (!Serial) { delay(1); } // wait until serial console is open, remove if not tethered to computer

  sht3xd.begin(0x45); //sht address

  if (sht3xd.periodicStart(SHT3XD_REPEATABILITY_HIGH, SHT3XD_FREQUENCY_10HZ) != SHT3XD_NO_ERROR) {
    Serial.println("[ERROR] Cannot start sht-31d periodic mode");
    while(1);
  } 

  // rf69 manual reset
  pinMode(RFM69_RST, OUTPUT);
  digitalWrite(RFM69_RST, LOW);
  digitalWrite(RFM69_RST, HIGH);
  delay(10);
  digitalWrite(RFM69_RST, LOW);
  delay(10);
  
  if (!rf69.init()) {
    Serial.println("RFM69 radio init failed");
    while (1);
  }
  Serial.println("RFM69 radio init OK!");
  
  if (!rf69.setFrequency(RF69_FREQ)) {
    Serial.println("setFrequency failed");
  }

  rf69.setTxPower(14, true);  // range from 14-20 for power, 2nd arg must be true for 69HCW

  // The encryption key has to be the same as the one in the server
  uint8_t key[] = { 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08,0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08};
  rf69.setEncryptionKey(key);
  
  Serial.print("RFM69 radio @");  Serial.print((int)RF69_FREQ);  Serial.println(" MHz");

  //check for the WiFi module:
  if (WiFi.status() == WL_NO_MODULE) {
    Serial.println("Communication with WiFi module failed!");
    // don't continue
    while (true);
  }

  // attempt to connect to Wifi network:
  while (status != WL_CONNECTED) {
    Serial.print("Attempting to connect to WPA SSID: ");
    Serial.println(ssid);
    // Connect to WPA/WPA2 network:
    status = WiFi.begin(ssid, pass);
    // wait 10 seconds for connection:
    delay(10000);
  }

  // you're connected now, so print out the data:
  Serial.print("You're connected to the network");
  printCurrentNet();
  printWifiData();
}

void loop() {

 //char postdata[100];
 int siteid = 1;
 
 if (rf69.available()) {
    printResult("Periodic Mode", sht3xd.periodicFetchData());
    // Should be a message for us now   
    uint8_t buf[RH_RF69_MAX_MESSAGE_LEN];
    uint8_t len = sizeof(buf);
    if (rf69.recv(buf, &len)) {
      
      if (!len) return;
      buf[len] = 0;

      Serial.print("Received [");
      Serial.print(len);
      Serial.print("]: ");
      Serial.println((char*)buf);
      Serial.print("RSSI: ");
      Serial.println(rf69.lastRssi(), DEC);

    }

  }

} //end void loop


void printWifiData() {
  // print your board's IP address:
  IPAddress ip = WiFi.localIP();
  Serial.print("IP Address: ");
  Serial.println(ip);
  Serial.println(ip);

  // print your MAC address:
  byte mac[6];
  WiFi.macAddress(mac);
  Serial.print("MAC address: ");
  printMacAddress(mac);
}

void printCurrentNet() {
  // print the SSID of the network you're attached to:
  Serial.print("SSID: ");
  Serial.println(WiFi.SSID());

  // print the MAC address of the router you're attached to:
  byte bssid[6];
  WiFi.BSSID(bssid);
  Serial.print("BSSID: ");
  printMacAddress(bssid);

  // print the received signal strength:
  long rssi = WiFi.RSSI();
  Serial.print("signal strength (RSSI):");
  Serial.println(rssi);

  // print the encryption type:
  byte encryption = WiFi.encryptionType();
  Serial.print("Encryption Type:");
  Serial.println(encryption, HEX);
  Serial.println();
}

void printMacAddress(byte mac[]) {
  for (int i = 5; i >= 0; i--) {
    if (mac[i] < 16) {
      Serial.print("0");
    }
    Serial.print(mac[i], HEX);
    if (i > 0) {
      Serial.print(":");
    }
  }
  Serial.println();
}

void printResult(String text, SHT31D result) {
  if (result.error == SHT3XD_NO_ERROR) {
    Serial.print(text);
    Serial.print(": T=");
    Serial.print(result.t);
    Serial.print("C, RH=");
    Serial.print(result.rh);
    Serial.println("%");
  } else {
    Serial.print(text);
    Serial.print(": [ERROR] Code #");
    Serial.println(result.error);
  }
}

I'd suggest asking on the Adafruit forum.

I now have asked the same question there.
Although this is still a programming question, and not all the sensors are from adafruit.