Commit d386eb29 authored by Claes Sjofors's avatar Claes Sjofors

More 64 bit, adaption of NMps

parent 0a6af4f2
......@@ -58,7 +58,7 @@
/* Data structure for one dataobjekt in a NMpsCell and NMpsSelectCell */
typedef struct {
pwr_tFloat32 *DataP;
pwr_tObjid Data_ObjId pwr_dAlignW;
pwr_tObjid Data_ObjId pwr_dAlignLW;
pwr_tBoolean Data_Front pwr_dAlignW;
pwr_tBoolean Data_Back pwr_dAlignW;
gdh_tDlid Data_Dlid pwr_dAlignW;
......
......@@ -2948,7 +2948,7 @@ void DataFWrite_exec( plc_sThread *tp,
o->Error = 0;
if ( *o->ConditionP && !o->CondOld) {
pwr_tAttrRef aref = cdh_ObjidToAref( *(pwr_tOid *)((char *)o->DataP + 4));
pwr_tAttrRef aref = cdh_ObjidToAref( *(pwr_tOid *)((char *)o->DataP + pwr_cAlignLW));
o->WriteStatus = gdh_FWriteObject( *o->FileNameP, &aref);
if ( EVEN(o->WriteStatus))
......@@ -2972,7 +2972,7 @@ void DataFRead_exec( plc_sThread *tp,
o->Error = 0;
if ( *o->ConditionP && !o->CondOld) {
pwr_tAttrRef aref = cdh_ObjidToAref( *(pwr_tOid *)((char *)o->DataP + 4));
pwr_tAttrRef aref = cdh_ObjidToAref( *(pwr_tOid *)((char *)o->DataP + pwr_cAlignLW));
o->ReadStatus = gdh_FReadObject( *o->FileNameP, &aref);
if ( EVEN(o->ReadStatus))
......
......@@ -572,62 +572,62 @@ static pwr_tStatus dataa_ODa4 (
}
static pwr_tStatus dataa_Da1front( dataa_ctx dataactx, char *line, char *pos,
char *out, int *incr, char *var) {
sprintf( out, "( *(char *)((char *)(%s->DataIn1P) + 12))", var);
sprintf( out, "( *(char *)((char *)(%s->DataIn1P) + pwr_cAlignLW+2*pwr_cAlignW))", var);
*incr = strlen(out);
return GSX__SUCCESS; }
static pwr_tStatus dataa_Da2front( dataa_ctx dataactx, char *line, char *pos,
char *out, int *incr, char *var) {
sprintf( out, "( *(char *)((char *)(%s->DataIn2P) + 12))", var);
sprintf( out, "( *(char *)((char *)(%s->DataIn2P) + pwr_cAlignLW+2*pwr_cAlignW))", var);
*incr = strlen(out);
return GSX__SUCCESS; }
static pwr_tStatus dataa_Da3front( dataa_ctx dataactx, char *line, char *pos,
char *out, int *incr, char *var) {
sprintf( out, "( *(char *)((char *)(%s->DataIn3P) + 12))", var);
sprintf( out, "( *(char *)((char *)(%s->DataIn3P) + pwr_cAlignLW+2*pwr_cAlignW))", var);
*incr = strlen(out);
return GSX__SUCCESS; }
static pwr_tStatus dataa_Da4front( dataa_ctx dataactx, char *line, char *pos,
char *out, int *incr, char *var) {
sprintf( out, "( *(char *)((char *)(%s->DataIn4P) + 12))", var);
sprintf( out, "( *(char *)((char *)(%s->DataIn4P) + pwr_cAlignLW+2*pwr_cAlignW))", var);
*incr = strlen(out);
return GSX__SUCCESS; }
static pwr_tStatus dataa_Da1back( dataa_ctx dataactx, char *line, char *pos,
char *out, int *incr, char *var) {
sprintf( out, "( *(char *)((char *)(%s->DataIn1P) + 16))", var);
sprintf( out, "( *(char *)((char *)(%s->DataIn1P) + pwr_cAlignLW+3*pwr_cAlignW))", var);
*incr = strlen(out);
return GSX__SUCCESS; }
static pwr_tStatus dataa_Da2back( dataa_ctx dataactx, char *line, char *pos,
char *out, int *incr, char *var) {
sprintf( out, "( *(char *)((char *)(%s->DataIn2P) + 16))", var);
sprintf( out, "( *(char *)((char *)(%s->DataIn2P) + pwr_cAlignLW+3*pwr_cAlignW))", var);
*incr = strlen(out);
return GSX__SUCCESS; }
static pwr_tStatus dataa_Da3back( dataa_ctx dataactx, char *line, char *pos,
char *out, int *incr, char *var) {
sprintf( out, "( *(char *)((char *)(%s->DataIn3P) + 16))", var);
sprintf( out, "( *(char *)((char *)(%s->DataIn3P) + pwr_cAlignLW+3*pwr_cAlignW))", var);
*incr = strlen(out);
return GSX__SUCCESS; }
static pwr_tStatus dataa_Da4back( dataa_ctx dataactx, char *line, char *pos,
char *out, int *incr, char *var) {
sprintf( out, "( *(char *)((char *)(%s->DataIn4P) + 16))", var);
sprintf( out, "( *(char *)((char *)(%s->DataIn4P) + pwr_cAlignLW+3*pwr_cAlignW))", var);
*incr = strlen(out);
return GSX__SUCCESS; }
static pwr_tStatus dataa_Da1objid( dataa_ctx dataactx, char *line, char *pos,
char *out, int *incr, char *var) {
sprintf( out, "( *(pwr_tObjid *)((char *)(%s->DataIn1P) + 4))", var);
sprintf( out, "( *(pwr_tObjid *)((char *)(%s->DataIn1P) + pwr_cAlignLW))", var);
*incr = strlen(out);
return GSX__SUCCESS; }
static pwr_tStatus dataa_Da2objid( dataa_ctx dataactx, char *line, char *pos,
char *out, int *incr, char *var) {
sprintf( out, "( *(pwr_tObjid *)((char *)(%s->DataIn2P) + 4))", var);
sprintf( out, "( *(pwr_tObjid *)((char *)(%s->DataIn2P) + pwr_cAlignLW))", var);
*incr = strlen(out);
return GSX__SUCCESS; }
static pwr_tStatus dataa_Da3objid( dataa_ctx dataactx, char *line, char *pos,
char *out, int *incr, char *var) {
sprintf( out, "( *(pwr_tObjid *)((char *)(%s->DataIn3P) + 4))", var);
sprintf( out, "( *(pwr_tObjid *)((char *)(%s->DataIn3P) + pwr_cAlignLW))", var);
*incr = strlen(out);
return GSX__SUCCESS; }
static pwr_tStatus dataa_Da4objid( dataa_ctx dataactx, char *line, char *pos,
char *out, int *incr, char *var) {
sprintf( out, "( *(pwr_tObjid *)((char *)(%s->DataIn4P) + 4))", var);
sprintf( out, "( *(pwr_tObjid *)((char *)(%s->DataIn4P) + pwr_cAlignLW))", var);
*incr = strlen(out);
return GSX__SUCCESS; }
static pwr_tStatus dataa_d1( dataa_ctx dataactx, char *line, char *pos,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment