summaryrefslogtreecommitdiffstats
path: root/views/transform.c
diff options
context:
space:
mode:
authorSuren A. Chilingaryan <csa@suren.me>2015-10-09 04:42:53 +0200
committerSuren A. Chilingaryan <csa@suren.me>2015-10-09 04:42:53 +0200
commitf13867f64fcba24ef2cb9d726b5ee1082ac1a8b9 (patch)
treed7186eb2a2c2d2e36c05cc702eb0ab0b3c877443 /views/transform.c
parent3b8e32c9bbe0d909c34303da0ad36ef0ef5be852 (diff)
downloadpcitool-f13867f64fcba24ef2cb9d726b5ee1082ac1a8b9.tar.gz
pcitool-f13867f64fcba24ef2cb9d726b5ee1082ac1a8b9.tar.bz2
pcitool-f13867f64fcba24ef2cb9d726b5ee1082ac1a8b9.tar.xz
pcitool-f13867f64fcba24ef2cb9d726b5ee1082ac1a8b9.zip
Implement enum view
Diffstat (limited to 'views/transform.c')
-rw-r--r--views/transform.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/views/transform.c b/views/transform.c
index 8885e17..818c1d6 100644
--- a/views/transform.c
+++ b/views/transform.c
@@ -10,7 +10,9 @@
#include "transform.h"
-static int pcilib_transform_view_read(pcilib_t *ctx, pcilib_view_context_t *view, const pcilib_register_value_t *regval, pcilib_value_t *val) {
+static int pcilib_transform_view_read(pcilib_t *ctx, pcilib_view_context_t *view, pcilib_register_value_t regval, pcilib_value_t *val) {
+ pcilib_set_value_from_int(ctx, val, 0);
+ return 0;
/* int j=0;
pcilib_register_value_t value=0;
char* formula=NULL;
@@ -43,7 +45,7 @@ static int pcilib_transform_view_read(pcilib_t *ctx, pcilib_view_context_t *view
}*/
}
-static int pcilib_transform_view_write(pcilib_t *ctx, pcilib_view_context_t *view, pcilib_register_value_t *regval, pcilib_value_t *val) {
+static int pcilib_transform_view_write(pcilib_t *ctx, pcilib_view_context_t *view, pcilib_register_value_t *regval, const pcilib_value_t *val) {
/* if(!(strcasecmp(unit, ((pcilib_view_t*)viewval)->base_unit.name))) {
formula=malloc(sizeof(char)*strlen(((pcilib_formula_t*)params)->write_formula));
strncpy(formula,((pcilib_formula_t*)params)->write_formula,strlen(((pcilib_formula_t*)params)->write_formula));