paulvha:
I do not have any of the hardware you refer to, but looking at the source code of the rfm69 library (RFM69.h) it looks an easy change.
In the top of the sketch define the pins to use. I changed the S_RF69_IRQ_PIN from pin 3 to pin 4 (so connect the RFM69 INT pin there). You can select another if you want.
Then it is passing on that information when you create the radio constructor.
Untested. !
Good Luck
#include <SparkFun_Qwiic_MP3_Trigger_Arduino_Library.h>
#include <Wire.h>
#include <RFM69.h>
#include <SPI.h>
// Addresses for this node. CHANGE THESE FOR EACH NODE!
#define NETWORKID 0 // Must be the same for all nodes
#define MYNODEID 2 // My node ID
#define TONODEID 1 // Destination node ID
// RFM69 frequency:
#define FREQUENCY RF69_915MHZ
int RXLED = 17;
// define the pins to use for the RFM69HCW radio module
#define S_RF69_SPI_CS SS // SS is the SPI slave select pin
#define S_RF69_IRQ_PIN 4 // this used to be pin 3 but you can select another
#define S_RF69_IRQ_NUM 0 // default as INT0. Do not change.
// Create a library objects
MP3TRIGGER mp3;
// the false in the setting below seems to indicate that is an RFM69W and not an RFM69HW. The default was false.
RFM69(S_RF69_SPI_CS, S_RF69_IRQ_PIN, false, S_RF69_IRQ_NUM) radio;
void setup()
{
Serial1.begin(9600);
// Initialize the RFM69HCW:
radio.setCS(10);
radio.initialize(FREQUENCY, MYNODEID, NETWORKID);
radio.setHighPower();
//For MP3
Serial.begin(115200);
Wire.begin();
pinMode(RXLED, OUTPUT); // is this set HIGH somewhere ?? or only LOW
}
void loop()
{
if (radio.receiveDone())
{
if (Serial1.readString() == ‘P’)
{
mp3.pause();
digitalWrite(RXLED, LOW);
}
if (Serial1.readString() == ‘N’)
{
mp3.playNext();
}
if (Serial1.readString() == "V0")
{
mp3.setVolume(0);
}
if (Serial1.readString() == "V4")
{
mp3.setVolume(4);
}
if (Serial1.readString() == "V8")
{
mp3.setVolume(8);
}
if (Serial1.readString() == "V12")
{
mp3.setVolume(12);
}
if (Serial1.readString() == "V16")
{
mp3.setVolume(16);
}
if (Serial1.readString() == "V20")
{
mp3.setVolume(20);
}
if (Serial1.readString() == "V24")
{
mp3.setVolume(24);
}
if (Serial1.readString() == "V28")
{
mp3.setVolume(28);
}
if (Serial1.readString() == "V32")
{
mp3.setVolume(32);
}
}
}
This code will not compile. I get an error on this line:
RFM69(S_RF69_SPI_CS, S_RF69_IRQ_PIN, false, S_RF69_IRQ_NUM) radio;
error is: expected ‘)’ before ‘,’ token