daraszz Posted April 19, 2016 Posted April 19, 2016 In the example below for writing in a EquWrite value, getting " 'volatile struct ' has no member named 'EquWrite' " on build. volatile GateArray3 *Gate3IC = GetGate3MemPtr(0); Gate3IC->Chan[2].EquWrite = 3; // Set EQU state to 1 // delay here Gate3IC->Chan[2].EquWrite = 1; // Set EQU state to 0 Can you tell me if this particular member is not accessible? The other members work fine.
steve.milici Posted April 19, 2016 Posted April 19, 2016 Gate3.Chan[j].EquWrite constitutes bits 06 – 07 of the full-word element Gate3.Chan[j].OutCtrl and must be accessed through the full-word element in C as in: Gate3IC->Chan[j].OutCtrl = Gate3IC->Chan[j].OutCtrl | (EquWriteVal <<6);
Ychu Posted April 19, 2016 Posted April 19, 2016 Gate3.Chan[j].EquWrite constitutes bits 06 – 07 of the full-word element Gate3.Chan[j].OutCtrl and must be accessed through the full-word element in C as in: Gate3IC->Chan[j].OutCtrl = Gate3IC->Chan[j].OutCtrl | (EquWriteVal <<6); Thanks Steve.
Recommended Posts