Running out of UDBs too early

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
DaGr_294516
Level 3
Level 3
10 sign-ins 10 questions asked First solution authored

I'm trying to fit as much as I possibly can into a PSoC4 - I want 2 quadrature decoders, 6 pwm outputs, and 3 serial modules

   

By putting two of the serials in to SCBs and the 2 quadrature decoders + 2 PWMs into TCPWM blocks, it just leaves enough for the remaining serial and PWMs in UDBa

   

I can put in 1 x 8 bit double output PWM modules with no trouble, giving me a total of 4 pwm outputs. When I build, this reports enough resources remaining to add another PWM. However, when I try, it says "5 UDBs required" 😞

   

Can any one shed any light on this?

0 Likes
3 Replies
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

When you provide us with a "Workspace Bundle" we all can compile and check what's going on, with so few information any presumptions are pure guesswork.

   

 

   

Bob

0 Likes
HeLi_263931
Level 8
Level 8
100 solutions authored 50 solutions authored 25 solutions authored

According to the data sheet, a 8bit-PWM with two outputs needs 9 macro cells. Since one UDB has 4 MCs, this PWM will consume 3 UDBs. Two of them might be shared with other components, though. But you won't get two of them, since this would require 5 UDBs (because you need 18MCs).

0 Likes
RodolfoGL
Employee
Employee
250 solutions authored 250 sign-ins 5 comments on KBA

You might be interested in this custom PWM component:

8-bit Quad PWM Component - Hackster.io

0 Likes