迪文科技论坛

 找回密码
 立即注册
搜索
查看: 344|回复: 7

[Question]Callback for help

[复制链接]

7

主题

21

回帖

118

积分

注册会员

Rank: 2

积分
118
发表于 2022-4-26 16:26:55 | 显示全部楼层 |阅读模式
Hi, How can i find the memory address of a control with ID 0x5A02   for example in C language.?
回复

使用道具 举报

2

主题

1228

回帖

1万

积分

论坛元老

Rank: 8Rank: 8

积分
10155
发表于 2022-4-27 08:54:01 | 显示全部楼层
    use   sys_read_vp(u16 addr,u8* buf,u16 len) and   sys_write_vp(u16 addr,u8* buf,u16 len)  function

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?立即注册

x
回复

使用道具 举报

7

主题

21

回帖

118

积分

注册会员

Rank: 2

积分
118
 楼主| 发表于 2022-4-27 14:36:05 | 显示全部楼层
zzs999k 发表于 2022-4-27 08:54
use   sys_read_vp(u16 addr,u8* buf,u16 len) and   sys_write_vp(u16 addr,u8* buf,u16 len)  functi ...

no , i did not want that   but
for display variable "Slider display" from dgus user guide
VP is at offset 0x6
.Which is basic address of display variable "Slider Display".
回复

使用道具 举报

2

主题

1228

回帖

1万

积分

论坛元老

Rank: 8Rank: 8

积分
10155
发表于 2022-4-27 14:48:09 | 显示全部楼层
You got it wrong "Slider Display". , this control is set to a variable address, to the variable address assignment can change the display, you can also set the description pointer, the description pointer offset 0X06 is the scale indicating the y coordinate position shown by the icon (x coordinates longitudinally) . For example, set description pointer 0X5000, modify 0X5006 is to modify the scale indicator icon display y coordinate position.   

0x5A02 is meaningless.

回复

使用道具 举报

7

主题

21

回帖

118

积分

注册会员

Rank: 2

积分
118
 楼主| 发表于 2022-4-27 15:32:55 | 显示全部楼层
本帖最后由 negut 于 2022-4-27 15:37 编辑
zzs999k Posted on 2022-4-27 14:48
You got it wrong "Slider Display". , this control is set to a variable address, to the variable addr ...

You mean SP description pointer right ?
I upload two images from DWIN development guide.
There at Slider display
Address SPAddress Definition Length (bytes)Description
0x00 0x5A02 2
0x02 *SP 2 Parameter Pointer.
                                                        0xFFFF: Disables SP (no run-time modification).
0x04 0x000C 2
0x06 0x00 *VP 2 Variable Pointer.
0x08 0x01 V_Begin 2 Minimum value accepted by the control.
0x0A 0x02 V_End 2 Maximum value accepted by the control.
0x0C 0x03 x_Begin 2 Minimum position of the slider, when its value equals “V_Begin” .
                                                               X coordinate for horizontal sliders, Y coordinate for vertical
0x0E 0x04 x_End 2
...................................................... ................................................................ .........................

Pls refer to first three lines.
adress 0x00, 0x02 , 0x04 from this table.
Also this table with parameter must have a location in memory .Which is that ? *VP ?
&VP = *table_address ? it is self pointer of this table?( to point to it self is like object characteristic   " this    in OOP."
回复

使用道具 举报

2

主题

1228

回帖

1万

积分

论坛元老

Rank: 8Rank: 8

积分
10155
发表于 2022-4-27 15:40:36 | 显示全部楼层
Please refer to the SPAddress     Address No use           for example offset 0x1 Minimum value accepted by the control.      offset 0x2 Maximum value accepted by the control.
回复

使用道具 举报

7

主题

21

回帖

118

积分

注册会员

Rank: 2

积分
118
 楼主| 发表于 2022-4-27 16:39:18 | 显示全部楼层
zzs999k 发表于 2022-4-27 15:40
Please refer to the SPAddress     Address No use           for example offset 0x1 Minimum value acce ...

You mean that the first lines can not be accesed by application code , and only accessed by OS code ?
回复

使用道具 举报

2

主题

1228

回帖

1万

积分

论坛元老

Rank: 8Rank: 8

积分
10155
发表于 2022-4-27 17:28:09 | 显示全部楼层
negut 发表于 2022-4-27 16:39
You mean that the first lines can not be accesed by application code , and only accessed by OS cod ...

Yes.
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|Archiver|手机版|小黑屋|迪文科技论坛 ( 京ICP备05033781号-1 )

GMT+8, 2025-5-10 03:29 , Processed in 0.039747 second(s), 22 queries .

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表