Blog > Re: Viewport & multi-cog debugging advice please

Home Forums ViewPort Viewport & multi-cog debugging advice please Re: Viewport & multi-cog debugging advice please

#11812

Hanno
Keymaster

Hi Max,
Some things get more difficult when you’re multiprocessing- sharing a single resource is one of them. Since there’s only one serial connection, it’s best to make sure that only one cog will be using it at a time. If you must share a single resource with multiple cogs make sure to enforce that only one does so at a time- look up "semaphore", "lock".
Hanno