Project

General

Profile

Revision a96c5547

IDa96c55475a95974ac99a8741adf2f1b943c5a400
Parent 15fa09f7
Child cce97007

Added by Thomas Mullins about 11 years ago

Moved tool address to Makefile

View differences:

toolbox/main.c
10 10
#include "current.h"
11 11
#include "time.h"
12 12

  
13
#if TOOL_ADDRESS < 0
14
#error Please define TOOL_ADDRESS
15
#endif
16

  
13 17
enum toolstate_t {
14 18
  TS_INIT,
15 19
  TS_OFF,
......
25 29
static uint8_t latest_reading[RFID_SERNO_SIZE];
26 30
static uint8_t current_user[RFID_SERNO_SIZE];
27 31
static uint16_t current;
32
static uint16_t current_max_warn, current_max_hard;
28 33

  
29 34
static inline void set_coil(char coil, char bit) {
30 35
  coils = (coils & ~(1 << coil)) | (bit << coil);
......
269 274
  rfid_init();
270 275
  current_init();
271 276

  
272
  eMBInit(MB_RTU, SLAVE_ADDR, 0, MB_BAUD, MB_PAR_NONE);
277
  eMBInit(MB_RTU, TOOL_ADDRESS, 0, MB_BAUD, MB_PAR_NONE);
273 278
  eMBEnable();
274 279

  
275 280
  sei();

Also available in: Unified diff