Link Port Viewer

A forum where you can announce your awesome project(s).

Moderator: MaxCoderz Staff

User avatar
Timendus
Calc King
Posts: 1729
Joined: Sun 23 Jan, 2005 12:37 am
Location: Netherlands
Contact:

Link Port Viewer

Post by Timendus »

Because PTI still lacks a graphical link port monitor, and my linktest utility really needed a redo (redrawing the screen using puts would reset the link port before setting it back again :?), and I once again ran into impossible to debug annoyances, I decided to write a quick oncalc link port viewer.

Image

I'm not entirely satisfied with it yet because it's too slow to keep up with my routines, and therefore useless for debugging my problem that still hasn't been solved :cry:, even if I don't update the screen on every change. It also detects keypresses wrong from time to time (pressing 2 changes the tip sometimes :?).

Anyway, here's a download for whoever wants it:
Download

Pressing 1 toggles the tip, pressing 2 toggles the ring, pressing Clear exits. The four dots represent if the line is high (inactive, open circle) or pulled low (active, filled dot) first and second if it's you pulling the line low or the connected calculator(s). This will be clear enough once you try to use it. In the screenshot the current calculator is holding the ring low and the connected calculator is holding the tip low.

The history shows the status of the lines (tip on top, ring bottom) scrolling from right to left on every status change. So if it were fast enough you'd be able to see byte transfers plotted on it.

Request@CoBB: It would be nice to see something like this, but with PC speed instead of TI speed, put into PTI :)
http://clap.timendus.com/ - The Calculator Link Alternative Protocol
http://api.timendus.com/ - Make your life easier, leave the coding to the API
http://vera.timendus.com/ - The calc lover's OS
User avatar
KermMartian
Calc Wizard
Posts: 549
Joined: Tue 05 Jul, 2005 11:28 pm
Contact:

Post by KermMartian »

Yeah, I've nagged him in the past for something like this. Good job on it; I bet this will help me debug Cn2 even more than your previous link port tool. :)
Image Image Image
CoBB
MCF Legend
Posts: 1601
Joined: Mon 20 Dec, 2004 8:45 am
Location: Budapest, Absurdistan
Contact:

Post by CoBB »

There is problem with this. PTI has no notion of time beyond that needed between two frames, which is a fundamental limitation. I have to rethink this part thoroughly, because it can affect things in weird ways (remember the blinking bug related to raw linking? that was also a time-related issue). I’ll probably have to use 64-bit counters instead of 32 (I want to be able to represent much smaller time quanta than a Z80 clock cycle, since that will be a must for the SE) and drop the display-oriented time concept, which was a pretty stupid thing to introduce in the first place. :roll:

I can’t even estimate how much work this change will involve, but it’s likely much less than the one that made it possible to emulate multiple calcs. That was... :x
User avatar
Timendus
Calc King
Posts: 1729
Joined: Sun 23 Jan, 2005 12:37 am
Location: Netherlands
Contact:

Post by Timendus »

My little thingy has no notion of time either, it just records all successive changes that it detects on the link port. This sounds stupid, but in link programming that is all that really matters. The calculators don't have proper timing, so all link software depends on detecting changes anyway.
http://clap.timendus.com/ - The Calculator Link Alternative Protocol
http://api.timendus.com/ - Make your life easier, leave the coding to the API
http://vera.timendus.com/ - The calc lover's OS
CoBB
MCF Legend
Posts: 1601
Joined: Mon 20 Dec, 2004 8:45 am
Location: Budapest, Absurdistan
Contact:

Post by CoBB »

I guess so. Well, it might be possible in this specific case, if I add a global link state tracker (if I were to record them separately for each calculator, I couldn’t determine the proper sequence when merging the data without timestamps), but it still requires some thinking to integrate it properly... I’ll see what I can do.
User avatar
Timendus
Calc King
Posts: 1729
Joined: Sun 23 Jan, 2005 12:37 am
Location: Netherlands
Contact:

Post by Timendus »

* Hopes * :mrgreen:
http://clap.timendus.com/ - The Calculator Link Alternative Protocol
http://api.timendus.com/ - Make your life easier, leave the coding to the API
http://vera.timendus.com/ - The calc lover's OS
User avatar
benryves
Maxcoderz Staff
Posts: 3087
Joined: Thu 16 Dec, 2004 10:06 pm
Location: Croydon, England
Contact:

Post by benryves »

I still use your old "ASCII-art" one from time to time. Nice to see it being updated ;)
CoBB
MCF Legend
Posts: 1601
Joined: Mon 20 Dec, 2004 8:45 am
Location: Budapest, Absurdistan
Contact:

Post by CoBB »

benryves wrote:I still use your old "ASCII-art" one from time to time. Nice to see it being updated ;)
It was a bit too phallic anyway. ;)
User avatar
Timendus
Calc King
Posts: 1729
Joined: Sun 23 Jan, 2005 12:37 am
Location: Netherlands
Contact:

Post by Timendus »

Wow, that's two already... I didn't even know it had a single user before yesterday :P

Edit: :mrgreen: @ CoBB
http://clap.timendus.com/ - The Calculator Link Alternative Protocol
http://api.timendus.com/ - Make your life easier, leave the coding to the API
http://vera.timendus.com/ - The calc lover's OS
User avatar
KermMartian
Calc Wizard
Posts: 549
Joined: Tue 05 Jul, 2005 11:28 pm
Contact:

Post by KermMartian »

CoBB wrote:
benryves wrote:I still use your old "ASCII-art" one from time to time. Nice to see it being updated ;)
It was a bit too phallic anyway. ;)
Agreed, that was just freaky. It did the trick though.
Image Image Image
User avatar
DigiTan
Calc Master
Posts: 1069
Joined: Fri 04 Mar, 2005 12:52 am
Location: NW Wisconsin
Contact:

Post by DigiTan »

This one will probably help me clear up the checksum vs. CRC uncertainty. 8)
My diet consists of nails, code-stealers, and HP fans.
Projects:

Robot War [TI-82, TI Flash App]
Sonic the Hedgehog [Multiplatform]
User avatar
KermMartian
Calc Wizard
Posts: 549
Joined: Tue 05 Jul, 2005 11:28 pm
Contact:

Post by KermMartian »

Timendus, I find that as you said, it's too slow. It only sees about 5 of the 8 bits getting sent per byte with Cn2.
Image Image Image
User avatar
Timendus
Calc King
Posts: 1729
Joined: Sun 23 Jan, 2005 12:37 am
Location: Netherlands
Contact:

Post by Timendus »

DigiTan wrote:This one will probably help me clear up the checksum vs. CRC uncertainty. 8)
Don't trust it too much yet :)
kerm_martian wrote:It only sees about 5 of the 8 bits getting sent per byte with Cn2.
Really? It sees my entire "CLAP lite" byte transfer as one change... As I said before; it seems your CN is pretty slow in it's current state. Are you going to do much about that?
http://clap.timendus.com/ - The Calculator Link Alternative Protocol
http://api.timendus.com/ - Make your life easier, leave the coding to the API
http://vera.timendus.com/ - The calc lover's OS
User avatar
KermMartian
Calc Wizard
Posts: 549
Joined: Tue 05 Jul, 2005 11:28 pm
Contact:

Post by KermMartian »

Timendus wrote:
DigiTan wrote:This one will probably help me clear up the checksum vs. CRC uncertainty. 8)
Don't trust it too much yet :)
kerm_martian wrote:It only sees about 5 of the 8 bits getting sent per byte with Cn2.
Really? It sees my entire "CLAP lite" byte transfer as one change... As I said before; it seems your CN is pretty slow in it's current state. Are you going to do much about that?
Uhhh, no, clearly mine is much faster, at least 8/5ths as fast as yours.
Image Image Image
User avatar
Timendus
Calc King
Posts: 1729
Joined: Sun 23 Jan, 2005 12:37 am
Location: Netherlands
Contact:

Post by Timendus »

You must suck in math even more than I do :)

I send 8 bits in 32 changes to the port, you send 8 bits in 8 or 16 changes to the port. Of my 32 changes, only one gets detected. The same program detects 5 of your changes. Since your routine uses at least twice as much changes, yet 5 times more are picked up, your routine should be roughly ten times slower than mine to get such a high detection rate. Have you tried sending over a full screen b/w image yet? (Or 768 random bytes) How long does that take? If my little calculation is correct it should take you about 15-20 seconds.
http://clap.timendus.com/ - The Calculator Link Alternative Protocol
http://api.timendus.com/ - Make your life easier, leave the coding to the API
http://vera.timendus.com/ - The calc lover's OS
Post Reply