Looking for ideas on how to get multiple instances of an object with assembly.
andrewsi
Posts: 59
So I'm working on a project where I'd like to have two serial terminals running at once - one from the Demo board's onboard programming port, and one from a second FTDI USB->Serial converter I hooked up.
Using the Parallax Serial Terminal library object with the first port is child's play, but it doesn't seem to work as a multiinstance object once you hook up the second port. I'm wondering if this is because the two cogs are sharing a single DAT instance of the code and perhaps there is global data in main memory getting stomped? Or is this expected to work and I'm just writing a bug in my code somewhere else? I'm just using the standard 'pst[2] : "Parallax Serial Terminal" OBJ definition and STARTing the two instances independently. (I also modified the object to take pin parameters on the Start method so as to not assume that it's using the programming pins on the demo board in all cases.)
I do seem to be able to make things work just fine using one instance of PST and one of Simple_Serial.
Using the Parallax Serial Terminal library object with the first port is child's play, but it doesn't seem to work as a multiinstance object once you hook up the second port. I'm wondering if this is because the two cogs are sharing a single DAT instance of the code and perhaps there is global data in main memory getting stomped? Or is this expected to work and I'm just writing a bug in my code somewhere else? I'm just using the standard 'pst[2] : "Parallax Serial Terminal" OBJ definition and STARTing the two instances independently. (I also modified the object to take pin parameters on the Start method so as to not assume that it's using the programming pins on the demo board in all cases.)
I do seem to be able to make things work just fine using one instance of PST and one of Simple_Serial.
Comments