C Library for mbedWSE project based single board computer for hardware peripherals
Fork of mbedWSEsbc by
Diff: mbedWSEsbc.h
- Revision:
- 14:321d6fdc40e6
- Parent:
- 12:9041603c430e
- Child:
- 15:2564f54c89df
--- a/mbedWSEsbc.h Tue Feb 10 16:14:18 2015 +0000 +++ b/mbedWSEsbc.h Tue Oct 11 17:11:12 2016 +0000 @@ -70,7 +70,7 @@ int read_max1270(int chan, int range, int bipol){ int cword=0x80; //set the start bit - spi_max1270.frequency(10000000); + spi_max1270.frequency(5000000); //10MHz spi_max1270.format(8, 0); // 8 data bits, CPOL0, and CPHA0 (datasheet Digital Interface) cword |= (chan << 4); //shift channel @@ -81,7 +81,8 @@ spi_max1270.write(cword); wait_us(15); //15us - spi_max1270.format(12, 3); + //spi_max1270.format(12, 3); + spi_max1270.format(12, 0); int result = spi_max1270.write(0);