Don't have an account? Register now to chat, post, use our tools, and much more.
Latest Headlines
Online Users
There are 124 users online: 7 members, 90 guests and 27 bots. Members: Ashbad, fortytwo, Spyro543, tr1p1ea. Bots: VoilaBot (3), Spinn3r (1), MSN/Bing (1), Magpie Crawler (3), VoilaBot (1), Googlebot (18).
RSS & Social Media
SAX
You must log in to view the SAX chat widget
|
| Author |
Message |
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 597
|
Posted: 26 Apr 2012 07:50:11 pm Post subject: |
|
|
dont worry about that linc thats more of a note for me and him and let me know  _________________ Cadan: CD : My (first?!?) mod of the cadan engine for a not so demoified version of the game :HOLD
Cn2.2 Wireless Bridge : Still in the design phase.
Contest #9 Cn2.2 Ika Shmup |
|
| Back to top |
|
|
Compynerd255

Power User

Joined: 08 Apr 2011 Posts: 397
|
Posted: 27 Apr 2012 09:20:34 am Post subject: |
|
|
I just installed the Axiom as of yesterday and got it integrated into Axe 1.1.2. I haven't done any message testing yet, but I did find that getKey(x) works fine, like this:
Code:
CnOn
Repeat getKey(15)
...send code...
End
However, I also noticed that your list of equates does not contain a size pointer, because you have to store the size of the frame in the low byte of the size word. The LSB of the size word is 5 bytes ahead of the beginning of the sender ID, so I was able to figure it out. _________________ Visit Betafreak Games: http://www.betafreak.com
Help Me Pay for College:
- Sign up for Fastweb through my referal link! |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 597
|
Posted: 27 Apr 2012 01:16:16 pm Post subject: |
|
|
0x5 ill add that in for the next version xD
I need to dig deeper to see if i need to replace that it may or may not bug out on the rare occasion due to how axe code is formatted
also i will keep the most uptodate copy of gcnlib right here http://sc.cemetech.net/?xpi=a0dd58b02147d24567312e084848e94b
sourcecoder is wonderful somedays (also i changed some of the names around i will redocument them in the updated readme) _________________ Cadan: CD : My (first?!?) mod of the cadan engine for a not so demoified version of the game :HOLD
Cn2.2 Wireless Bridge : Still in the design phase.
Contest #9 Cn2.2 Ika Shmup |
|
| Back to top |
|
|
Compynerd255

Power User

Joined: 08 Apr 2011 Posts: 397
|
Posted: 27 Apr 2012 02:08:33 pm Post subject: |
|
|
Thanks, geekboy.
I did a little more testing with the Axiom and library, and I was able to get Calcnet up and running between two calculators (TI 84 Plus and TI 84 Plus Silver Edition, if you'd like to know).
However, I found that the set and recieve flag commands don't work: SetS appears to set the recieve flag (or GetR appears to get the recieve flag), and a few other bugs I couldn't locate. Calcnet only started working when I modified the MSB of the size words directly.
Taking a look at your code...
Code:
;1 GetS returns the send buffer flag
ld a,(SWord+1) ;put msb in l
rlca ; rotate to bit one
ld l,a ; load into l
ld h,0 ; clear h
...it appears like correct logic. I don't know the logistics of z80, but I think that the rotate operations actually rotates the most significant bit into the carry flag, as it does on the Apple //e's 6502. Try adding another rotate to fix the problem. _________________ Visit Betafreak Games: http://www.betafreak.com
Help Me Pay for College:
- Sign up for Fastweb through my referal link! |
|
| Back to top |
|
|
KermMartian

Site Admin

Joined: 14 Mar 2005 Posts: 55763 Location: Earth, Sol, Milky Way
|
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 597
|
Posted: 27 Apr 2012 04:09:13 pm Post subject: |
|
|
using rlca is still faster there Kerm seeing as we don't care for any of the other flag stuff rlc does (4 cycles over i do agree with the and 1 tho and U have updated my source with that as that's a good idea for future proofing  _________________ Cadan: CD : My (first?!?) mod of the cadan engine for a not so demoified version of the game :HOLD
Cn2.2 Wireless Bridge : Still in the design phase.
Contest #9 Cn2.2 Ika Shmup |
|
| Back to top |
|
|
KermMartian

Site Admin

Joined: 14 Mar 2005 Posts: 55763 Location: Earth, Sol, Milky Way
|
Posted: 27 Apr 2012 04:10:11 pm Post subject: |
|
|
| geekboy1011 wrote: | using rlca is still faster there Kerm seeing as we don't care for any of the other flag stuff rlc does (4 cycles over i do agree with the and 1 tho and U have updated my source with that as that's a good idea for future proofing  | Sorry, that was the point I was making, the and 1. Sorry if that was not entirely clear; I wasn't criticizing the rlca. _________________
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 597
|
Posted: 27 Apr 2012 04:12:42 pm Post subject: |
|
|
yeah thought so was just pointing out
also compy I looked at my code the set/gets are pointed to/should be returning the right data. I will upload a new copy with a updated readme and such at some point tonight _________________ Cadan: CD : My (first?!?) mod of the cadan engine for a not so demoified version of the game :HOLD
Cn2.2 Wireless Bridge : Still in the design phase.
Contest #9 Cn2.2 Ika Shmup |
|
| Back to top |
|
|
KermMartian

Site Admin

Joined: 14 Mar 2005 Posts: 55763 Location: Earth, Sol, Milky Way
|
Posted: 27 Apr 2012 04:16:03 pm Post subject: |
|
|
Sounds like a plan. As I mentioned on IRC, when I get home I'd be happy to look over your code as a sanity check. _________________
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 597
|
Posted: 27 Apr 2012 04:25:05 pm Post subject: |
|
|
awesome thanks once I get that sanity check I will update stuff. Seeing as this is why its in beta xD _________________ Cadan: CD : My (first?!?) mod of the cadan engine for a not so demoified version of the game :HOLD
Cn2.2 Wireless Bridge : Still in the design phase.
Contest #9 Cn2.2 Ika Shmup |
|
| Back to top |
|
|
LincolnB

Advanced Member

Joined: 07 Jul 2011 Posts: 199
|
Posted: 27 Apr 2012 08:05:18 pm Post subject: |
|
|
Alright, so I'm looking through the white pages on the wiki, and it says, "To send data via CALCnet2.2, a calculator program must first place the receiver ID... in the associated memory areas". If I understand correctly, this memory area is 86EE, or the constant UID? How do I get the receiver ID? _________________ -LincolnB
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 597
|
Posted: 27 Apr 2012 08:21:13 pm Post subject: |
|
|
86ee is your calcs id. you do not modify that as that will break stuff.
87FA or SNDID\TXID is the is the id of the calc you are sending to.
now to get that id you would follow this flow chart http://geekboy.57o9.org/CALCNet/CALCnet%20Server%20Client%20Initialization%20Flow.png
you load RCVID\TXID with 00000 then use SetS then every calc will get a frame with your id in it. they then save it and send a reply back which will contain there id.
then you copy those id's into ram. so you can copy them back into the SNDID to send data to a specific calculator _________________ Cadan: CD : My (first?!?) mod of the cadan engine for a not so demoified version of the game :HOLD
Cn2.2 Wireless Bridge : Still in the design phase.
Contest #9 Cn2.2 Ika Shmup |
|
| Back to top |
|
|
KermMartian

Site Admin

Joined: 14 Mar 2005 Posts: 55763 Location: Earth, Sol, Milky Way
|
Posted: 27 Apr 2012 08:41:26 pm Post subject: |
|
|
To say the same thing again, but in a different way, you load data into Cn2_Int_SendBuf, and you read data from Cn2_Int_RecBuf. You should never touch any other area of the data near 86EC. For Cn2_Int_SendBuf, you load 5 bytes of receiver ID, leave two bytes of space, load the data to send, then go back and put the size in with its high bit set. To receive, check Cn2_Int_RecBuf until the highest bit of the size gets set. When it does, read out the sender ID and data as needed, then clear the flag. _________________
 |
|
| Back to top |
|
|
LincolnB

Advanced Member

Joined: 07 Jul 2011 Posts: 199
|
Posted: 28 Apr 2012 12:17:34 pm Post subject: |
|
|
OK, I think that makes sense. I'll look more in depth to that later today. _________________ -LincolnB
 |
|
| Back to top |
|
|
KermMartian

Site Admin

Joined: 14 Mar 2005 Posts: 55763 Location: Earth, Sol, Milky Way
|
|
| Back to top |
|
|
LincolnB

Advanced Member

Joined: 07 Jul 2011 Posts: 199
|
Posted: 28 Apr 2012 05:23:50 pm Post subject: |
|
|
OK, so looking at geekboy's flowcharts at http://ima.tiz80.com:1235/FrameFlowControl.png, I wrote some code, do you think this would work?
Code: ::Pseudocode
//program inits
Repeat getkey(15)
//Load 4 bytes of data to be sent into L4
2->{L4}r
2->{L4+2}r
//Clear out L5, the recently received data buffer
0->{L5}r
0->{L5+2}r
//Sending
//is Sizeword+1 msb reset?
If GetS = 0
//load data into the send buffer
Copy(L4,OTDAT,4
//set size into Sizeword
4->{SNDID+5}r
//set Sizeword+1 msb
SetS
End
//Receiving
//is size word set?
If GetR
//put the data somewhere we can use it later in the program
Copy(INDAT,L5,4
//reset msb of Sizeword+1
SetR //I'm not sure if this is correct...
End
//now we're doing sending and receiving
//do whatever crap with the data
//recently sent data is in L4
//recently received data is in L5
ClrDraw
Text(0,0,{L5}r>Dec
Text(0,8,{L5}r>Dec
Dispgraph
End
Also, I noticed that nowhere on the flowchart did it say a thing about any calc's ID. Do I ever need to worry about any calc's ID, sending or receiving? _________________ -LincolnB
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 597
|
|
| Back to top |
|
|
KermMartian

Site Admin

Joined: 14 Mar 2005 Posts: 55763 Location: Earth, Sol, Milky Way
|
Posted: 28 Apr 2012 06:43:22 pm Post subject: |
|
|
I should also point out that to clear the receive buffer, the ONLY thing you need to do is zero out the size word (you might as well just ld a word-wise zero into it, ie, ld hl, 0 \ ld (Cn2_Int_RecBuf+5),hl ). It's not necessary to clear out the address or the data received. _________________
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 597
|
Posted: 28 Apr 2012 06:45:49 pm Post subject: |
|
|
all i do in code is
Code:
ld hl,Cn2_Int_RecBuf
res 7,(hl)
only because in the future you may use those bits for other stuff as you have said _________________ Cadan: CD : My (first?!?) mod of the cadan engine for a not so demoified version of the game :HOLD
Cn2.2 Wireless Bridge : Still in the design phase.
Contest #9 Cn2.2 Ika Shmup |
|
| Back to top |
|
|
KermMartian

Site Admin

Joined: 14 Mar 2005 Posts: 55763 Location: Earth, Sol, Milky Way
|
Posted: 28 Apr 2012 06:47:27 pm Post subject: |
|
|
As far as setting, yes. But for clearing, just clear out the whole word. I believe those are the semantics I use in all of my CALCnet2.2-enabled programs. _________________
 |
|
| Back to top |
|
|
|
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.
» Go to Registration page
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
© Copyright 2000-2013 Cemetech & Kerm Martian :: Page Execution Time: 0.044732 seconds.
|