Browse Source

revert to clean up for merge

main
xxxajk 5 years ago
parent
commit
d68107e973
1 changed files with 2 additions and 3 deletions
  1. +2
    -3
      SPI.h

+ 2
- 3
SPI.h View File

//return port().POPR; //return port().POPR;
} }
uint16_t transfer16(uint16_t data) { uint16_t transfer16(uint16_t data) {
uint16_t rv=transfer(data >> 8);
rv |=transfer(data & 255) << 8;
transfer(data >> 8);
transfer(data & 255) << 8;
//port().SR = SPI_SR_TCF; //port().SR = SPI_SR_TCF;
//port().PUSHR = data | SPI_PUSHR_CTAS(1); //port().PUSHR = data | SPI_PUSHR_CTAS(1);
//while (!(port().SR & SPI_SR_TCF)) ; // wait //while (!(port().SR & SPI_SR_TCF)) ; // wait
//return port().POPR; //return port().POPR;
return rv;
} }


void inline transfer(void *buf, size_t count) {transfer(buf, buf, count);} void inline transfer(void *buf, size_t count) {transfer(buf, buf, count);}

Loading…
Cancel
Save