Author Topic: Multi channel designs and buses and nested "Repeat()"  (Read 5700 times)

0 Members and 1 Guest are viewing this topic.

Offline ajbTopic starter

  • Super Contributor
  • ***
  • Posts: 2601
  • Country: us
Multi channel designs and buses and nested "Repeat()"
« on: May 22, 2016, 02:35:34 am »
I'm working on a project that has several banks of four output channels each.  If I'm using the repeat command, how the heck do I get unique signals from each channel back out the the main sheet? 

For instance, I have Bank 1 containing Output 1-4, and each output needs a unique PWM signal from the main sheet.  So I have an output channel sheet.  I place that sheet symbol in the bank sheet using "Repeat" and I repeat the ports to get a bus called "PWM[1..4]".  So far so good.  I can connect those to pins inside the bank sheet no problem, but I don't want to do that, because I just need to connect those signals back to the main sheet.

In the main sheet, I can place one instance of the bank sheet symbol and bring out the PWM signals as a bus, then break them out and that works fine.  But I'm at a bit of a loss as to how to do that if I repeat the bank symbol.  Is it even possible to repeat a symbol that contains a repeated symbol and still bring out unique nets back to the parent sheet?

I could do multiple explicit instances of the bank sheet and bring out separate buses from each, but if each bus winds up being called "PWM[1..4]", I don't know how I get them broken out to distinct nets.
« Last Edit: May 22, 2016, 02:52:34 am by ajb »
 

Offline ajbTopic starter

  • Super Contributor
  • ***
  • Posts: 2601
  • Country: us
Re: Multi channel designs and buses and nested "Repeat()"
« Reply #1 on: May 23, 2016, 12:07:42 am »
So I wound up breaking out the PWM signals from the output channels to separate ports in the bank sheet, and then in the main sheet I just have multiple separate (no repeat()) instances of the bank sheet.  That works okay, but apparently you can't copy room formats from one repeat instance to another, because even though they have the same source sheet Altium sees them as different "Channel Classes".  So I guess you have to lay out one channel in each bank and then copy the format to the other channels in the same bank (or try to use snippets or something).  That's annoying.
 

Offline T3sl4co1l

  • Super Contributor
  • ***
  • Posts: 21675
  • Country: us
  • Expert, Analog Electronics, PCB Layout, EMC
    • Seven Transistor Labs
Re: Multi channel designs and buses and nested "Repeat()"
« Reply #2 on: May 23, 2016, 06:30:06 am »
The tech doc on how to use multichannel design explains this with pictures.

In words, it looks something like:
- Sheet symbols get REPEAT()'d (as you already know)
- Sheet entrys get REPEAT()'d as well (if you don't, that indicates you want them all connected together, i.e., a scalar)
- Connect a wire to the sheet entry, give it a net name e.g. BUSIN
- Connect the wire to a bus, and give it a net name e.g. BUSIN[1...10].  This names the nets sequentially.
- You can connect to the nets by placing a net label anywhere on the sheet, but preferably:
- Connect bus entrys to the bus, and run wires off the bus, net-naming them (BUSIN1, BUSIN2, etc.) to show which one is which.

At least, that was the technique last time I had to do it; not sure if they've made it more sensical nowadays.  I think harnesses are more preferred, too.  Check that out in the techdocs too.

Tim
Seven Transistor Labs, LLC
Electronic design, from concept to prototype.
Bringing a project to life?  Send me a message!
 

Offline ajbTopic starter

  • Super Contributor
  • ***
  • Posts: 2601
  • Country: us
Re: Multi channel designs and buses and nested "Repeat()"
« Reply #3 on: May 23, 2016, 11:42:19 am »
Right, I understand how to get a bus out of a repeated sheet symbol and break it out to nets.  That's how I have it set up in the bank sheet now.  The question is if I have three sheets, where I repeat the channel sheet four times in the bank sheet, and then I repeat the bank sheet two times in the main sheets.  So in the bank sheet I wind up with a bus of four nets, but I can't seem to bring out that bus in a repeated port, because that would logically result in a bus of buses, I guess, and Altium has no concept of that because why would you do that?  Probably the most elegant solution would be for it to concatenate the buses into something like PWMA1, PWMB1, PWMA2, etc.

I could break the PWM[1..4] bus out to PWM1, PWM2, etc in the bank sheet as I have now, link those to individual ports, and then repeat the sheet symbol and wind up with four buses like PWM1[1..2], PWM2[1..2], which would probably work but would be super ugly.

I'd forgotten about harnesses, I'll look into those.  Thanks
 

Offline T3sl4co1l

  • Super Contributor
  • ***
  • Posts: 21675
  • Country: us
  • Expert, Analog Electronics, PCB Layout, EMC
    • Seven Transistor Labs
Re: Multi channel designs and buses and nested "Repeat()"
« Reply #4 on: May 23, 2016, 04:53:54 pm »
Ok, nested, and I suppose BUS[1..4][1..2] doesn't work, or whatever?  :-//

At least two isn't much; you're as well off placing two separate sheet symbols for that.

Tim
Seven Transistor Labs, LLC
Electronic design, from concept to prototype.
Bringing a project to life?  Send me a message!
 

Offline ajbTopic starter

  • Super Contributor
  • ***
  • Posts: 2601
  • Country: us
Re: Multi channel designs and buses and nested "Repeat()"
« Reply #5 on: May 23, 2016, 06:02:20 pm »
Yeah, I took a couple of stabs at multidimensional bus notation, nothing seemed to work. 

I'll probably wind up moving the channel sheet symbol into the main sheet so that at least I can copy room formats for channels across the banks, then tie the channels and the bank-specific stuff together in the main sheet.  That will work well enough here, and yeah, only having to do this twice isn't a big deal.  I'm more just surprised that there's apparently no provision for this, given how convoluted some of the hierarchical design examples are. 

Harnesses look pretty neat, but apparently don't work with "repeat()".  Oh well.
 

Offline Fgrir

  • Regular Contributor
  • *
  • Posts: 154
  • Country: us
Re: Multi channel designs and buses and nested "Repeat()"
« Reply #6 on: May 23, 2016, 06:38:08 pm »
It looks like they are going to address the mixing of Harnesses and Repeat, hopefully they will come up with something actually useful for these types of nested cases:

https://bugcrunch.live.altium.com/#Idea/2831

This one is asking for multidimensional bus support, maybe if it got more votes?:

https://bugcrunch.live.altium.com/#Idea/4603

I've been frustrated by the simple limitations of Repeat() in many designs that have much larger channel counts than yours.  I've always ended up just placing a bunch of individual Sheet Symbols to get around the inability to pass busses through repeat blocks.
 

Offline T3sl4co1l

  • Super Contributor
  • ***
  • Posts: 21675
  • Country: us
  • Expert, Analog Electronics, PCB Layout, EMC
    • Seven Transistor Labs
Re: Multi channel designs and buses and nested "Repeat()"
« Reply #7 on: May 23, 2016, 10:02:22 pm »
Well, at least it says "in development"...

Tim
Seven Transistor Labs, LLC
Electronic design, from concept to prototype.
Bringing a project to life?  Send me a message!
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf