81 code = code | 0xFF000000;
82 voltage = (float)code / 8388608 * vref;
92 for (i = 0; i < num_of_pulses; ++
i)
104 uint8_t tx[4] = {0,0,0,0};
111 code = (code << 8) | rx[2];
112 code = (code << 8) | rx[1];
113 code = code & 0xFFFFFF;
void send_pulses(uint8_t pin, uint16_t num_of_pulses)
Send n num of pulses on pin given.
#define output_high(pin)
Set "pin" high.
Header File for Linduino Libraries and Demo Code.
float LTC2512_code_to_voltage(int32_t code, float vref)
Calculates the output voltage from the given digital code and reference voltage.
#define output_low(pin)
Set "pin" low.
LT_SPI: Routines to communicate with ATmega328P's hardware SPI port.
LT_I2C: Routines to communicate with ATmega328P's hardware I2C port.
uint32_t LTC2512_read_data(uint8_t QUIKEVAL_CS, uint16_t *DF)
Reads 4 bytes of data on SPI - D23:D0 + W7:W0.
void spi_transfer_block(uint8_t cs_pin, uint8_t *tx, uint8_t *rx, uint8_t length)
Reads and sends a byte array.
#define QUIKEVAL_CS
QuikEval CS pin (SPI chip select on QuikEval connector pin 6) connects to Arduino SS pin...