![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
Version FC
Dependencies: DmTftLibrary eeprom SX1280Lib filesystem mbed
Fork of MSNV2-Terminal_V1-5 by
Diff: ExtMemory.cpp
- Revision:
- 36:14a8da4108d5
- Parent:
- 33:6ae45cba7958
- Child:
- 38:9b43b2415093
- Child:
- 41:5a436163dddf
diff -r be9473118f9a -r 14a8da4108d5 ExtMemory.cpp --- a/ExtMemory.cpp Tue Oct 16 07:19:47 2018 +0000 +++ b/ExtMemory.cpp Tue Oct 16 07:29:51 2018 +0000 @@ -56,9 +56,9 @@ if (ep.getError() != 0) { error(ep.getErrorMessage()); continue;} // TODO STATE field is missing in ServiceDefinition // TODO access pins - Service::ACCESS_PIN access_pins[6] = { 1, 2, 3, 4, 5, 6 }; + // Service::ACCESS_PIN access_pins[6] = { 1, 2, 3, 4, 5, 6 }; Service* service; -// = new Service((misnet::Service::DEVICE_TYPE) sd.device_type, +// = new Service((misnet::Service::SERVICE_TYPE) sd.service_type, // sd.mistnet_code, // Service::ENABLED, // (misnet::Service::ACCESS_TYPE) sd.access_type, @@ -271,7 +271,7 @@ // ---------services---------- sd.component_id = Component::DS18B20; - sd.device_type = Service::DEVICE_TYPE::SENSOR; + sd.service_type = Service::SERVICE_TYPE::SENSOR; sd.mistnet_code = 0x5f; strcpy(sd.comment,"DS1_TEMP"); ep.write((uint32_t) (pos), (void *) &sd, sizeof(sd)); @@ -280,10 +280,10 @@ if (ep.getError() != 0) error(ep.getErrorMessage()); pos += sizeof(sd); printf("service1 ID:0x%02x type:0x%02x code:0x%04x\n", - sd_r.component_id, sd_r.device_type, sd_r.mistnet_code); + sd_r.component_id, sd_r.service_type, sd_r.mistnet_code); sd.component_id = Component::LSM303D; - sd.device_type = Service::DEVICE_TYPE::SENSOR; + sd.service_type = Service::SERVICE_TYPE::SENSOR; sd.mistnet_code = 0x2b; strcpy(sd.comment,"LSM_ACCEL"); ep.write((uint32_t) (pos), (void *) &sd, sizeof(sd)); @@ -292,10 +292,10 @@ if (ep.getError() != 0) error(ep.getErrorMessage()); pos += sizeof(sd); printf("service2 ID:0x%02x type:0x%02x code:0x%04x\n", - sd_r.component_id, sd_r.device_type, sd_r.mistnet_code); + sd_r.component_id, sd_r.service_type, sd_r.mistnet_code); sd.component_id = Component::BME280; - sd.device_type = Service::DEVICE_TYPE::SENSOR; + sd.service_type = Service::SERVICE_TYPE::SENSOR; sd.mistnet_code = 0x4a; strcpy(sd.comment,"BME_TEMP"); ep.write((uint32_t) (pos), (void *) &sd, sizeof(sd)); @@ -304,10 +304,10 @@ if (ep.getError() != 0) error(ep.getErrorMessage()); pos += sizeof(sd); printf("service3 ID:0x%02x type:0x%02x code:0x%04x\n", - sd_r.component_id, sd_r.device_type, sd_r.mistnet_code); + sd_r.component_id, sd_r.service_type, sd_r.mistnet_code); sd.component_id = Component::BME280; - sd.device_type = Service::DEVICE_TYPE::SENSOR; + sd.service_type = Service::SERVICE_TYPE::SENSOR; sd.mistnet_code = 0x4b; strcpy(sd.comment,"BME_HUMI"); ep.write((uint32_t) (pos), (void *) &sd, sizeof(sd)); @@ -316,10 +316,10 @@ if (ep.getError() != 0) error(ep.getErrorMessage()); pos += sizeof(sd); printf("service4 ID:0x%02x type:0x%02x code:0x%04x\n", - sd_r.component_id, sd_r.device_type, sd_r.mistnet_code); + sd_r.component_id, sd_r.service_type, sd_r.mistnet_code); sd.component_id = Component::BME280; - sd.device_type = Service::DEVICE_TYPE::SENSOR; + sd.service_type = Service::SERVICE_TYPE::SENSOR; sd.mistnet_code = 0x4c; strcpy(sd.comment,"BME_BARO"); @@ -329,5 +329,5 @@ if (ep.getError() != 0) error(ep.getErrorMessage()); pos += sizeof(sd); printf("service5 ID:0x%02x type:0x%02x code:0x%04x\n", - sd_r.component_id, sd_r.device_type, sd_r.mistnet_code); + sd_r.component_id, sd_r.service_type, sd_r.mistnet_code); } \ No newline at end of file