Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

<sangr> home is where the highest bandwidth is


devel / comp.lang.tcl / [Incr Tcl] and configbody concepts

SubjectAuthor
* [Incr Tcl] and configbody conceptsDavid Gravereaux
+- Re: [Incr Tcl] and configbody conceptsDavid Gravereaux
`- Re: [Incr Tcl] and configbody conceptsDavid Gravereaux

1
[Incr Tcl] and configbody concepts

<v01k4v$3u215$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=13307&group=comp.lang.tcl#13307

  copy link   Newsgroups: comp.lang.tcl
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: davyg...@pobox.com (David Gravereaux)
Newsgroups: comp.lang.tcl
Subject: [Incr Tcl] and configbody concepts
Date: Sat, 20 Apr 2024 16:46:37 -0700
Organization: A noiseless patient Spider
Lines: 52
Message-ID: <v01k4v$3u215$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sun, 21 Apr 2024 01:46:39 +0200 (CEST)
Injection-Info: dont-email.me; posting-host="f66660e956e5f0f396165a13286c95d0";
logging-data="4130853"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19Z3Jfa7j9qxm7yJakzX0KaBj92TbUWBfU="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:DEPGPF7aDM621DrvBd34QDqRFPE=
Content-Language: en-US
 by: David Gravereaux - Sat, 20 Apr 2024 23:46 UTC

Hi,

I'm writing an [Incr Tcl] extension to an API that uses quite a lot of
Set/Get calls:

PMDCFunc PMDSetProfileMode (PMDAxisInterface axis_intf,
PMDuint16 mode);
PMDCFunc PMDGetProfileMode (PMDAxisInterface axis_intf,
PMDuint16* mode);
PMDCFunc PMDSetPosition (PMDAxisInterface axis_intf,
PMDint32 position);
PMDCFunc PMDGetPosition (PMDAxisInterface axis_intf,
PMDint32* position);
PMDCFunc PMDSetVelocity (PMDAxisInterface axis_intf,
PMDint32 velocity);
PMDCFunc PMDGetVelocity (PMDAxisInterface axis_intf,
PMDint32* velocity);
....etc.

The hooks are currently set as this sourced from the pkgIndex:

load [file join [file dirname [info script]] CMoTcl10.[info
sharedlibextension]]

itcl::class ::pmd::cmotion {
constructor {} { _init }
destructor { _destroy }
public {
method GetCMotionVersion {} @CMo-GetCMotionVersion

# Profile Generation
method SetProfileMode {} @CMo-SetProfileMode
method GetProfileMode {} @CMo-GetProfileMode
method SetPosition {} @CMo-SetPosition
method GetPosition {} @CMo-GetPosition
method SetVelocity {} @CMo-SetVelocity
method GetVelocity {} @CMo-GetVelocity
...

Is there a way to use configbody to differentiate the [G|S]et calls? IOW,

$instance config -ProfileMode

routes to PMDGetProfileMode() for returning the value and

$instance config -ProfileMode <somevalue>

routes to PMDSetProfileMode() for setting it? Thanks in advance.
https://github.com/davygrvy/CMoTcl

Re: [Incr Tcl] and configbody concepts

<v01mi7$3ubdb$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=13308&group=comp.lang.tcl#13308

  copy link   Newsgroups: comp.lang.tcl
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: davyg...@pobox.com (David Gravereaux)
Newsgroups: comp.lang.tcl
Subject: Re: [Incr Tcl] and configbody concepts
Date: Sat, 20 Apr 2024 17:27:51 -0700
Organization: A noiseless patient Spider
Lines: 7
Message-ID: <v01mi7$3ubdb$1@dont-email.me>
References: <v01k4v$3u215$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sun, 21 Apr 2024 02:27:52 +0200 (CEST)
Injection-Info: dont-email.me; posting-host="f66660e956e5f0f396165a13286c95d0";
logging-data="4140459"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+AO/GW/1138cfnyVY/B8PQav0329eUoQ8="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:Irxwtee/9vbkyQlwIsw5WGuqZA4=
Content-Language: en-US
In-Reply-To: <v01k4v$3u215$1@dont-email.me>
 by: David Gravereaux - Sun, 21 Apr 2024 00:27 UTC

Maybe with
itcl::configbody ProfileMode @CMo-somefunc

$instance config -ProfileMode ?someValue?

will get called with objc of 2 for a value (a set) or 1 with nothing (a
get). I will check

Re: [Incr Tcl] and configbody concepts

<v02kvg$7gp6$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=13309&group=comp.lang.tcl#13309

  copy link   Newsgroups: comp.lang.tcl
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: davyg...@pobox.com (David Gravereaux)
Newsgroups: comp.lang.tcl
Subject: Re: [Incr Tcl] and configbody concepts
Date: Sun, 21 Apr 2024 02:06:57 -0700
Organization: A noiseless patient Spider
Lines: 8
Message-ID: <v02kvg$7gp6$1@dont-email.me>
References: <v01k4v$3u215$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sun, 21 Apr 2024 11:06:57 +0200 (CEST)
Injection-Info: dont-email.me; posting-host="f66660e956e5f0f396165a13286c95d0";
logging-data="246566"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19+Q3SjF/lVLjLxAXxxdGnrIJuJZYheCSM="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:g6kWnVJwmYeeWvRA8X9VoQzFDlg=
Content-Language: en-US
In-Reply-To: <v01k4v$3u215$1@dont-email.me>
 by: David Gravereaux - Sun, 21 Apr 2024 09:06 UTC

My concept is completely off. I think I'm conceptualizing
Tcl_TraceVar() with the TCL_TRACE_READS and TCL_TRACE_WRITES flags.

This won't do what I think it does:

itcl::class foo {
public variable ProfileMode @myGetSetProc
}


devel / comp.lang.tcl / [Incr Tcl] and configbody concepts

1
server_pubkey.txt

rocksolid light 0.9.81
clearnet tor