You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
32 lines
1.0 KiB
32 lines
1.0 KiB
7 years ago
|
//----------------------------------------------------------------------------------------------------------------------------
|
||
|
// Project: Uppsense
|
||
|
// Name: hardware.h
|
||
|
// Author: Maximilian Stiefel
|
||
|
// Date: 09.08.2017
|
||
|
//
|
||
|
// Description:
|
||
|
//
|
||
|
//----------------------------------------------------------------------------------------------------------------------------
|
||
|
|
||
|
#ifndef APP_HARDWARE_H_
|
||
|
#define APP_HARDWARE_H_
|
||
|
|
||
7 years ago
|
#define REV_1
|
||
|
|
||
7 years ago
|
//-------------------------------------I2C ADRESSES---------------------------------------------------------------------------
|
||
7 years ago
|
static const uint8_t ADC_ADDRESS = 0x49;
|
||
|
static const uint8_t DAC1_ADDRESS = 0xE;
|
||
7 years ago
|
|
||
7 years ago
|
static const uint16_t R_SENSE = 100; // 100 Ohm sensing resistor
|
||
|
static const uint16_t CURR_MAX_UAMP = 10000; // 10 mA max.
|
||
|
static const uint16_t VREF_DAC = 3300; // in mV
|
||
|
static const uint16_t RESOLUTION_DAC = 1024;
|
||
7 years ago
|
|
||
7 years ago
|
static const int HUB_PERIOD = 5;
|
||
|
static const int ADC_TIMEBASE = 250;
|
||
|
static const int ADC_PERIOD = 5;
|
||
|
|
||
|
#define LED_PIN 2 // GPIO2
|
||
|
|
||
7 years ago
|
#endif /* APP_HARDWARE_H_ */
|