Hi,
I'm fairly new to Step 7 and mainly have a Rockwell background. I have a project which has an S7-300 talking to ABB drives over profibus. the first peripheral input word form the drive is its status word. This word is made up of individual bits for its status i.e Bit 0 = 'drive healthy', bit 1 = 'drive tripped' etc. PIW256 is the status word. I've created a DB for each drive and within this created a UDT which has all the drive status bits as BOOL's. This is so I can use symbolic addressing for the status bits. when I look at the DB in data view it shows that the status word is DBW8 and that 'drive healthy' = 8.1 and 'drive tripped' = 8.2 etc.
So DB20.DB8.0 is drive healthy ??
I MOVE PIW256 to DB20.DBW8. When I monitor these at word level, when the drive sets its healthy bit, then bit 0 of PIW256 is energised as is bit 0 of DB20.DBW8. Theres no byte swapping here. So far so good. The problem is that if I monitor DB20.DBX8.0 ('drivehealthy' symbolically), this doesn't reflect bit 0 of the words. its DB20.DBX9.0 which does. This isn't even shown in the DB. I'm confused ??? I was under the impression that its only when changinf rom Bytes to words that you have to be careful of the byte swapping ???
Thanks in advance
I'm fairly new to Step 7 and mainly have a Rockwell background. I have a project which has an S7-300 talking to ABB drives over profibus. the first peripheral input word form the drive is its status word. This word is made up of individual bits for its status i.e Bit 0 = 'drive healthy', bit 1 = 'drive tripped' etc. PIW256 is the status word. I've created a DB for each drive and within this created a UDT which has all the drive status bits as BOOL's. This is so I can use symbolic addressing for the status bits. when I look at the DB in data view it shows that the status word is DBW8 and that 'drive healthy' = 8.1 and 'drive tripped' = 8.2 etc.
So DB20.DB8.0 is drive healthy ??
I MOVE PIW256 to DB20.DBW8. When I monitor these at word level, when the drive sets its healthy bit, then bit 0 of PIW256 is energised as is bit 0 of DB20.DBW8. Theres no byte swapping here. So far so good. The problem is that if I monitor DB20.DBX8.0 ('drivehealthy' symbolically), this doesn't reflect bit 0 of the words. its DB20.DBX9.0 which does. This isn't even shown in the DB. I'm confused ??? I was under the impression that its only when changinf rom Bytes to words that you have to be careful of the byte swapping ???
Thanks in advance