Jump to content
OMRON Forums

EquWrite in C


daraszz

Recommended Posts

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.

Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

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.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.

×
×
  • Create New...