I am creating a wireless remote transmitter and receiver. The transmitter has a analog potentiometer, and the receiver has a digital potentiometer as the output. I can see in the serial monitor that the analog value is being received but it’s not doing anything to the digital potentiometer.
So it seems that there is nothing wrong with the radio link.
Have you tried running an I2C scanner to check that your digital potentiometer is responding to I2C at the address you have defined for it?
[Edit: I wrote the above before @ahsrabrifat replied, sorry for the duplication]
Have you tried running a variant of the [Edit wrong I2C scanner - I meant the receiver] sketch that doesn't have any wireless receiver code. Maybe it could write some value to the potentiometer that you type into the serial monitor.
First thing to do is check the return value of Wire.endTransmission() and print it to the serial monitor.
I am testing by actually trying to operate it where I’m gonna be using it. I will do the I2C scanner when I get back home. Which line would I add to include the Wire.endtransmission to the serial monitor?
I don't mind answering, but in future you could Google for "Arduino Wire.endTransmission() reference". You can usually find the official info on any Arduino built in library function using that technique.
My search gave me this link which contains this info:
Additionally, print both the byte value sent by the TX nRF24L01 and the byte value received from the RX nRF24L01. Confirm they match and are as expected.
I have the tx serial monitor printing the analog potentiometers output value, and the byte value is matching on the rx serial monitor. The Wire.endtransmission return value is 2 in the monitor. I did an I2C scanner and it showed 0x28 for the address found.
A value of 2 means: A NACK after an address is sent, which in turn means no slave responded to that address, but the scanner found it at 0x28 and your code seems to be using 0x28.