Changeset 8246 for trunk/psModules/src/concepts
- Timestamp:
- Aug 8, 2006, 4:37:08 PM (20 years ago)
- Location:
- trunk/psModules/src/concepts
- Files:
-
- 3 edited
-
pmConcepts.c (modified) (11 diffs)
-
pmConceptsRead.c (modified) (3 diffs)
-
pmConceptsWrite.c (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psModules/src/concepts/pmConcepts.c
r7752 r8246 89 89 psMetadataItem *specItem = NULL; // Item from the specs metadata 90 90 while ((specItem = psMetadataGetAndIncrement(specsIter))) { 91 psTrace( __func__, 9, "Blanking %s...\n", specItem->name);91 psTrace("psModules.concepts", 9, "Blanking %s...\n", specItem->name); 92 92 pmConceptSpec *spec = specItem->data.V; // The specification 93 93 psMetadataItem *blank = spec->blank; // The concept … … 189 189 } 190 190 191 psTrace( __func__, 3, "Writing concepts (%x %x %x): %x\n", fpa, chip, cell, source);191 psTrace("psModules.concepts", 3, "Writing concepts (%x %x %x): %x\n", fpa, chip, cell, source); 192 192 193 193 if (source & PM_CONCEPT_SOURCE_CAMERA) { … … 212 212 { 213 213 PS_ASSERT_PTR_NON_NULL(fpa, false); 214 psTrace("psModule .concepts", 5, "Blanking FPA concepts: %x %x\n", conceptsFPA, fpa->concepts);214 psTrace("psModules.concepts", 5, "Blanking FPA concepts: %x %x\n", conceptsFPA, fpa->concepts); 215 215 return conceptsBlank(&conceptsFPA, fpa->concepts); 216 216 } … … 225 225 { 226 226 PS_ASSERT_PTR_NON_NULL(fpa, false); 227 psTrace("psModule .concepts", 5, "Reading FPA concepts: %x %x\n", conceptsFPA, fpa->concepts);227 psTrace("psModules.concepts", 5, "Reading FPA concepts: %x %x\n", conceptsFPA, fpa->concepts); 228 228 bool success = conceptsRead(&conceptsFPA, fpa, NULL, NULL, &fpa->conceptsRead, source, db, fpa->concepts); 229 229 if (propagateDown) { … … 248 248 { 249 249 PS_ASSERT_PTR_NON_NULL(fpa, false); 250 psTrace("psModule .concepts", 5, "Writing FPA concepts: %x %x\n", conceptsFPA, fpa->concepts);250 psTrace("psModules.concepts", 5, "Writing FPA concepts: %x %x\n", conceptsFPA, fpa->concepts); 251 251 bool success = conceptsWrite(&conceptsFPA, fpa, NULL, NULL, source, db, fpa->concepts); 252 252 if (propagateDown) { … … 267 267 { 268 268 PS_ASSERT_PTR_NON_NULL(chip, false); 269 psTrace("psModule .concepts", 5, "Blanking chip concepts: %x %x\n", conceptsChip, chip->concepts);269 psTrace("psModules.concepts", 5, "Blanking chip concepts: %x %x\n", conceptsChip, chip->concepts); 270 270 return conceptsBlank(&conceptsChip, chip->concepts); 271 271 } … … 280 280 { 281 281 PS_ASSERT_PTR_NON_NULL(chip, false); 282 psTrace("psModule .concepts", 5, "Reading chip concepts: %x %x\n", conceptsChip, chip->concepts);282 psTrace("psModules.concepts", 5, "Reading chip concepts: %x %x\n", conceptsChip, chip->concepts); 283 283 pmFPA *fpa = chip->parent; // FPA to which the chip belongs 284 284 bool success = conceptsRead(&conceptsChip, fpa, chip, NULL, &chip->conceptsRead, source, db, … … 308 308 { 309 309 PS_ASSERT_PTR_NON_NULL(chip, false); 310 psTrace("psModule .concepts", 5, "Writing chip concepts: %x %x\n", conceptsChip, chip->concepts);310 psTrace("psModules.concepts", 5, "Writing chip concepts: %x %x\n", conceptsChip, chip->concepts); 311 311 pmFPA *fpa = chip->parent; // FPA to which the chip belongs 312 312 bool success = conceptsWrite(&conceptsChip, fpa, chip, NULL, source, db, chip->concepts); … … 331 331 { 332 332 PS_ASSERT_PTR_NON_NULL(cell, false); 333 psTrace("psModule .concepts", 5, "Blanking cell concepts: %x %x\n", conceptsCell, cell->concepts);333 psTrace("psModules.concepts", 5, "Blanking cell concepts: %x %x\n", conceptsCell, cell->concepts); 334 334 return conceptsBlank(&conceptsCell, cell->concepts); 335 335 } … … 343 343 { 344 344 PS_ASSERT_PTR_NON_NULL(cell, false); 345 psTrace("psModule .concepts", 5, "Reading cell concepts: %x %x\n", conceptsCell, cell->concepts);345 psTrace("psModules.concepts", 5, "Reading cell concepts: %x %x\n", conceptsCell, cell->concepts); 346 346 pmChip *chip = cell->parent; // Chip to which the cell belongs 347 347 pmFPA *fpa = chip->parent; // FPA to which the chip belongs … … 371 371 { 372 372 PS_ASSERT_PTR_NON_NULL(cell, false); 373 psTrace("psModule .concepts", 5, "Writing cell concepts: %x %x\n", conceptsCell, cell->concepts);373 psTrace("psModules.concepts", 5, "Writing cell concepts: %x %x\n", conceptsCell, cell->concepts); 374 374 pmChip *chip = cell->parent; // Chip to which the cell belongs 375 375 pmFPA *fpa = chip->parent; // FPA to which the chip belongs -
trunk/psModules/src/concepts/pmConceptsRead.c
r7923 r8246 177 177 PS_ASSERT_PTR_NON_NULL(target, false); 178 178 179 psTrace( __func__, 3, "Reading concepts from defaults...\n");179 psTrace("psModules.concepts", 3, "Reading concepts from defaults...\n"); 180 180 181 181 pmHDU *hdu = pmHDUGetLowest(fpa, chip, cell); // The HDU at the lowest level … … 199 199 psString name = specItem->name; // The concept name 200 200 psMetadataItem *conceptItem = psMetadataLookup(defaults, name); // The concept, or NULL 201 psTrace( __func__, 10, "%s: %x\n", name, conceptItem);201 psTrace("psModules.concepts", 10, "%s: %x\n", name, conceptItem); 202 202 if (conceptItem && conceptItem->type == PS_DATA_METADATA) { 203 psTrace( __func__, 5, "%s is of type METADATA.\n", name);203 psTrace("psModules.concepts", 5, "%s is of type METADATA.\n", name); 204 204 // Check for DEPEND 205 205 psMetadata *dependMenu = conceptItem->data.V; // The DEPEND menu … … 236 236 } 237 237 const char *dependKey = dependValue->data.V; // The key to the DEPEND menu 238 psTrace( __func__, 7, "%s.DEPEND resolves to %s....\n", name, dependKey);238 psTrace("psModules.concepts", 7, "%s.DEPEND resolves to %s....\n", name, dependKey); 239 239 240 240 conceptItem = psMetadataLookup(dependMenu, dependKey); -
trunk/psModules/src/concepts/pmConceptsWrite.c
r7835 r8246 140 140 switch (item->type) { 141 141 case PS_DATA_STRING: 142 psTrace( __func__, 9, "Writing header %s: %s\n", keyword, item->data.V);142 psTrace("psModules.concepts", 9, "Writing header %s: %s\n", keyword, item->data.V); 143 143 return psMetadataAddStr(hdu->header, PS_LIST_TAIL, keyword, PS_META_REPLACE, item->comment, 144 144 item->data.V); 145 145 case PS_DATA_S32: 146 psTrace( __func__, 9, "Writing header %s: %d\n", keyword, item->data.S32);146 psTrace("psModules.concepts", 9, "Writing header %s: %d\n", keyword, item->data.S32); 147 147 return psMetadataAddS32(hdu->header, PS_LIST_TAIL, keyword, PS_META_REPLACE, item->comment, 148 148 item->data.S32); 149 149 case PS_DATA_F32: 150 psTrace( __func__, 9, "Writing header %s: %f\n", keyword, item->data.F32);150 psTrace("psModules.concepts", 9, "Writing header %s: %f\n", keyword, item->data.F32); 151 151 return psMetadataAddF32(hdu->header, PS_LIST_TAIL, keyword, PS_META_REPLACE, item->comment, 152 152 item->data.F32); 153 153 case PS_DATA_F64: 154 psTrace( __func__, 9, "Writing header %s: %f\n", keyword, item->data.F64);154 psTrace("psModules.concepts", 9, "Writing header %s: %f\n", keyword, item->data.F64); 155 155 return psMetadataAddF64(hdu->header, PS_LIST_TAIL, keyword, PS_META_REPLACE, item->comment, 156 156 item->data.F64); 157 157 case PS_DATA_REGION: { 158 158 psString region = psRegionToString(*(psRegion*)item->data.V); 159 psTrace( __func__, 9, "Writing header %s: %s\n", keyword, region);159 psTrace("psModules.concepts", 9, "Writing header %s: %s\n", keyword, region); 160 160 bool result = psMetadataAddStr(hdu->header, PS_LIST_TAIL, keyword, PS_META_REPLACE, item->comment, 161 161 region); … … 252 252 psString source = psMetadataLookupStr(&mdok, cell->config, nameSource); // The source 253 253 if (mdok && strlen(source) > 0) { 254 psTrace( __func__, 8, "%s is %s\n", nameSource, source);254 psTrace("psModules.concepts", 8, "%s is %s\n", nameSource, source); 255 255 if (strcasecmp(source, "HEADER") == 0) { 256 256 if (cameraItem->type != PS_DATA_STRING) { … … 259 259 continue; 260 260 } 261 psTrace( __func__, 8, "Writing %s to header %s\n", name, cameraItem->data.V);261 psTrace("psModules.concepts", 8, "Writing %s to header %s\n", name, cameraItem->data.V); 262 262 writeHeader(hdu, cameraItem->data.V, formatted); 263 263 } else if (strcasecmp(source, "VALUE") == 0) { 264 psTrace( __func__, 8, "Checking %s against camera format.\n", name);264 psTrace("psModules.concepts", 8, "Checking %s against camera format.\n", name); 265 265 if (! compareConcepts(formatted, cameraItem)) { 266 266 psLogMsg(__func__, PS_LOG_WARN, "Concept %s is specified by value in the camera " … … 384 384 continue; 385 385 } 386 psTrace( __func__, 3, "Writing %s to header %s\n", name, headerItem->data.V);386 psTrace("psModules.concepts", 3, "Writing %s to header %s\n", name, headerItem->data.V); 387 387 psMetadataItem *conceptItem = psMetadataLookup(concepts, name); // The item from the concepts 388 388 psMetadataItem *formatted = conceptFormat(spec, conceptItem, cameraFormat, fpa, chip, cell);
Note:
See TracChangeset
for help on using the changeset viewer.
