Hi Wang,
I could read the data, using simple Arduino mega, BUT I had to invert MISO and MOSI....
#include <SPI.h>
// the setup function runs once when you press reset or power the board
int highbyte=0b11111101;
int lowbyte =0b00000000;
void setup() {
// initialize digital pin LED_BUILTIN as an output.
pinMode(LED_BUILTIN, OUTPUT);
pinMode(53, OUTPUT);
digitalWrite(53, HIGH);
Serial.begin(9600);
SPI.begin();
SPI.beginTransaction(SPISettings(100000, MSBFIRST, SPI_MODE1));
}
void loop() {
digitalWrite(LED_BUILTIN, HIGH); // turn the LED on (HIGH is the voltage level)
digitalWrite(53, LOW);
int result_0 = SPI.transfer16(0xFD00);
delayMicroseconds(7);
SPI.endTransaction();
digitalWrite(53, HIGH);
digitalWrite(LED_BUILTIN, LOW); // turn the LED off by making the voltage LOW
delay(10);
Serial.println(result_0, HEX);
}
and I get 0x74 as response.
But now I can´t get CAN to work properly.
Best.
Vinicius.