| Author |
Message |
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 596
|
Posted: 28 Apr 2012 07:05:18 pm Post subject: |
|
|
Unless my math is really wrong. Using my code is 1cc and 1 byte more optimized. Kinda moot but just putting that out there in the thread.
hopefully that chart helps you tho lincolnB  _________________ 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: 28 Apr 2012 10:49:24 pm Post subject: |
|
|
Alright, thanks. I'll be sure to check that out. How does this flowchart relate to the other one, can it be a complete replacement? Like, do I need to use the other one at all, or is this one complete? _________________ -LincolnB
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 596
|
Posted: 28 Apr 2012 10:57:46 pm Post subject: |
|
|
the first flow chart you used is the model for sending and receiving frames. the one i just linked is for setting up a peer to peer network within calcnet. so you need both as one is just initialization the other is what you use when actually handling data _________________ 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: 28 Apr 2012 11:03:26 pm Post subject: |
|
|
OK, so all I need to add is in the //program inits line, where I would set the respective memory areas to the sending and receiving calc's IDs? _________________ -LincolnB
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 596
|
|
| Back to top |
|
|
LincolnB

Advanced Member

Joined: 07 Jul 2011 Posts: 199
|
Posted: 30 Apr 2012 09:07:43 pm Post subject: |
|
|
So the pseudo-pseudocode would look something like this:
.prgmTEST
#Axiom(GCNAXE)
//2nd flowchart here
Repeat getkey(15)
//1st flowchart here
//other game code
End _________________ -LincolnB
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 596
|
Posted: 30 Apr 2012 09:27:31 pm Post subject: |
|
|
.prgmTEST
#Axiom(GCNAXE)
while !GetR
asm(76)
end
//save id and quit to the next step in teh flow chart _________________ 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: 30 Apr 2012 09:32:35 pm Post subject: |
|
|
What does Asm(76) do?
EDIT: Also, I'm looking at that second flowchart, on the Client side; there's a line that's confusing me. It says, "Save ID and send frame back". Would that look something like this?
Copy(RXID,OTDAT,5
5->{TXID+2}
SetS _________________ -LincolnB
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 596
|
Posted: 30 Apr 2012 10:15:41 pm Post subject: |
|
|
yes but that would work. really all you are doing there is sending an ack to the calc that is broadcasting so it knows you exist _________________ 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: 55759 Location: Earth, Sol, Milky Way
|
Posted: 01 May 2012 11:55:24 am Post subject: |
|
|
This is a bit off-topic, but I noticed that your assembly file for the Axiom is named gcn.asm. This is incorrect - you have made a CALCnet axiom. Calculators are (just about) never aware if they're communicating over CALCnet or gCn, since gCn is supposed to be entirely transparent to calculators. A half-hearted analogy would be Ethernet/ TCP/IP = CALCnet2.2, "the internet" (ie, its global infrastructure of satellites, fiber, copper, etc) = globalCALCnet. All a computer knows is that it's talking TCP/IP to something else, without knowing all the details of whether the other computer is on the end of a 3-foot Ethernet cable or thousands of miles of infrastructure. _________________
 |
|
| Back to top |
|
|
LincolnB

Advanced Member

Joined: 07 Jul 2011 Posts: 199
|
Posted: 01 May 2012 04:50:28 pm Post subject: |
|
|
how do you broadcast directly across the link port? Also, what are the values in RCVID and SNDID used for? _________________ -LincolnB
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 596
|
Posted: 01 May 2012 06:10:56 pm Post subject: |
|
|
you don't need to send stuff over the link port lincoln calcnet does that for you.
RCVID is the person who will receive the data being sent
SNDID IS the person who sent you data _________________ 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: 01 May 2012 09:13:35 pm Post subject: |
|
|
So in a two player game, RCVID and SNDID will have the same value? _________________ -LincolnB
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 596
|
|
| Back to top |
|
|
Compynerd255

Power User

Joined: 08 Apr 2011 Posts: 397
|
Posted: 02 May 2012 09:25:32 am Post subject: |
|
|
| geekboy1011 wrote: | you don't need to send stuff over the link port lincoln calcnet does that for you.
RCVID is the person who will receive the data being sent
SNDID IS the person who sent you data |
Actually, I think that RCVID and SNDID are reverse of what you said, because I can use {°RCVID + 6} to access the byte containing the recieve data flag.
But yes, setting the send flag tells CALCnet to broadcast across the link port, and resetting the recieve flag tells CALCnet that it's OK to accept a new recieve frame. In another context of "broadcast", If SNDID contains all zeroes, the frame sent is a "broadcast" frame that anyone can get, but there is no guarantee that any of the calcs will recieve it, so you should keep track of the other player's ID as soon as they get it and use that to send directed frames, which will only reach that calc and are far more likely to get there.
Out of curiosity, Kerm, does the current CALCnet protocol have a timer variable (one that is incremented by 1 every time the interrupt is run)? If not, is there a way that the 84 Plus crystal timers can work with CALCnet? _________________ 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: 55759 Location: Earth, Sol, Milky Way
|
Posted: 02 May 2012 09:32:19 am Post subject: |
|
|
| Compynerd255 wrote: | | Out of curiosity, Kerm, does the current CALCnet protocol have a timer variable (one that is incremented by 1 every time the interrupt is run)? If not, is there a way that the 84 Plus crystal timers can work with CALCnet? | I'm not entirely sure what you're asking. You can indeed use the crystal timers with CALCnet, or at least two of the three (or maybe it's one?). If I recall my USB code correctly, and it's been quite some time since I touched it, one or two timers are required for part of the Direct USB system. I'll have to double-check my code and get back to you on that. I'm not sure what you're asking about the timer variable, though, unless you're saying that you want your program to know when the interrupt has executed, in which case I'd have to ask why. _________________
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 596
|
Posted: 02 May 2012 02:05:18 pm Post subject: |
|
|
compy it very well might be i will post an updated and proofreaded readme before I sleep tonight as I am not home to work on it currently. It will also have a updated lib file called GCNLib (yes Kerm I know you want it to be cn2 which is what I will name it when its out of beta ) which will change the names around slightly to have TX and RX prefixes instead of SND and RCV just easier for me. you can really change them to what ever you want I don't care _________________ 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: 03 May 2012 08:50:17 pm Post subject: |
|
|
| Compynerd255 wrote: | | 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). |
Mind posting your code?  _________________ -LincolnB
 |
|
| Back to top |
|
|
LincolnB

Advanced Member

Joined: 07 Jul 2011 Posts: 199
|
Posted: 07 May 2012 03:33:31 pm Post subject: |
|
|
So what happens if RCVID and SNDID are filled with 5 bytes of zeros? _________________ -LincolnB
 |
|
| Back to top |
|
|
geekboy1011

Expert

Joined: 19 Jul 2009 Posts: 596
|
Posted: 07 May 2012 03:36:26 pm Post subject: |
|
|
ok sndid should never be filled with 5 0's thats pointless
rcvid when that is filled with 5 0's calcnet will send the data you have loaded to everyone. not just a specific endpoint
so say we had 3 calcs on the network
11111
22222
33333
if you filled rcvid with 22222 on calculator 11111 only 22222 will get the frame 33333 will ignore it
now if you filled rcvid with 00000 on calculator 11111 both 33333 and 22222 will get the data IF they are able to accept data. unlike a non braodcast frame it will not poll until it is sent it just sends it once and assumes the data got where it was intended to go _________________ 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 |
|
|
|