block diagram logic

Thread Starter

Phycho_cat

Joined Aug 23, 2024
26
Hi! I’m designing a small lighting system and PCB for the first time. Before I start creating the PCB layout, I want to make sure my input/output block diagram is correct and properly connected. I’m using CAN FD to control everything. Can you check if my block diagram looks okay or if I’m missing anything important? Also, what would you recommend for protecting the LEDs? should I consider a constant current LED driver instead of a simple resistor for better stability? please let me know what you think or if anything seems wrong and problematic here. Thanks
1762156363986.png
 

Sensacell

Joined Jun 19, 2012
3,780
You are missing all the details regarding the LED itself- and the big picture purpose- "what is it"
There are so many types of LED's and applications, and the power level needed can have a huge impact on circuit complexity.
 

lichurbagan

Joined Jul 4, 2025
121
Hi! I’m designing a small lighting system and PCB for the first time. Before I start creating the PCB layout, I want to make sure my input/output block diagram is correct and properly connected. I’m using CAN FD to control everything. Can you check if my block diagram looks okay or if I’m missing anything important? Also, what would you recommend for protecting the LEDs? should I consider a constant current LED driver instead of a simple resistor for better stability? please let me know what you think or if anything seems wrong and problematic here. Thanks
View attachment 358168
Is there any direct connection between the Buck converter and the STM32?
 

Irving

Joined Jan 30, 2016
5,066
2.8mA to an LED is insignificant if this is a lighting system; that's the sort of level for a simple 'power on' indicator. A metre strip of white LEDs would be typically 6 - 12W, or 0.5 - 1A on a 12v supply, 1.2 - 2.4A on a 5v supply. These would almost definitely be some form of constant current supply, but it depends on what you are trying to do. As said above, the details are important. If you want a sanity check on your PCB layout, first you need a fully detailed schematic.

Why are you using CANBus,? That adds a level of complexity over other comms options, and you certainly don't need the further added complexity of CAN FD, keep it simple. Have you used CANBus in anger before?
 

Thread Starter

Phycho_cat

Joined Aug 23, 2024
26
You are missing all the details regarding the LED itself- and the big picture purpose- "what is it"
There are so many types of LED's and applications, and the power level needed can have a huge impact on circuit complexity.
My goal is to build a lighting system for a robot that increases brightness as it gets closer to an obstacle. The LEDs need to be very bright, so the power level will definitely be higher than typical indicator LEDs. I’m planning to use a constant-current LED driver and protect the system with a fuse and a TVS diode, but I’m concerned about if the heat will be manageable.
 

Thread Starter

Phycho_cat

Joined Aug 23, 2024
26
Is there any direct connection between the Buck converter and the STM32?
Thanks for pointing that out and yes, there should be one eventually. I’m still figuring out how the board will be laid out, so some connections might be missing for now. Please let me know if you have any other suggestions.
 

Thread Starter

Phycho_cat

Joined Aug 23, 2024
26
2.8mA to an LED is insignificant if this is a lighting system; that's the sort of level for a simple 'power on' indicator. A metre strip of white LEDs would be typically 6 - 12W, or 0.5 - 1A on a 12v supply, 1.2 - 2.4A on a 5v supply. These would almost definitely be some form of constant current supply, but it depends on what you are trying to do. As said above, the details are important. If you want a sanity check on your PCB layout, first you need a fully detailed schematic.

Why are you using CANBus,? That adds a level of complexity over other comms options, and you certainly don't need the further added complexity of CAN FD, keep it simple. Have you used CANBus in anger before?
Hello, thanks for pointing this out. I noticed the same thing last night while doing more research on what components I need to use. Your suggestion is completely valid, because I do need high-brightness LEDs to illuminate the environment at night. I found a possible match: “High Power LED Chip, Super Bright SMD COB Light Emitter Component Diode 1W Bulb Lamp.” I also want to be able to control their brightness eventually.

Regarding the use of CANBus I haven’t worked with it before, and this is actually my first PCB design ever. However, since my lighting system is part of a larger project where CANBus is already being used for everything else, I have to stick with it as well.
 

Irving

Joined Jan 30, 2016
5,066
Ok, well before you can even think about laying out a PCB you need a schematic. At this stage you need to think about physical board dimensions and/or shape and, for the LEDs, how many and how they can be mounted - those high power LEDs need a heatsink, and possibly a reflector if you want to get the most out of them. It's not uncommon to use an aluminium-based PCB to mount them on. You also need to consider how you will power them and from what voltage. A dedicated constant current driver IC is best for efficiency and will give you dimming for free. A higher drive voltage and putting multiple diodes in series is preferable as it reduces current draw and removes the need for series resistors improving efficiency. Those diodes typically run at 450 to 700mA and around 3v each. Running at 5v will lose 40% of your energy as heat in the dropper resistor, but putting 4 in series on 12 - 13v wastes almost nothing.

You wouldn't use CANbus within the board, it's not necessary and proliferates chips. A simple 2 or 3 wire I2C bus would be normal. CANbus to communicate with other external modules and handle incoming requests for light on/level/off then makes sense.
 

Sensacell

Joined Jun 19, 2012
3,780
Start with what matters most- buy the LED and test it using a current limited bench supply.
Then... consider how you can drive the LED
Then... build a breadboard LED driver, connect it to your STM32
Then... develop your overall system architecture
Then... breadboard the whole thing using modules - by any means necessary
Then... test-debug-repeat...

Then... layout a PCB.

I hear in your words this fixation that you must go directly to a PCB - this is a very expensive, disappointing and frustrating strategy, especially for a beginner.
Your first PCB will not work.
You must fix and revise it- over and over.
Each time- you wait a week for the new board.
Each time- you spend time and money on parts, assembly and PCB fabrication.

Focus on a step-by-step process, build on solid tested concepts.
Design your system breadboard around a modular idea- each function block is an easily unpluggable/replaceable module.
Bring all the key signals out to easy-to-probe test points.
If there is no evaluation board available for that tiny SMD chip- spin a simple breakout board for that ONE part alone- make it a simple module.
Build and test the modules by themselves, make sure they work as expected BEFORE you connect them all together.

You will be done faster and cheaper- and end up with a much better design using this approach.
 
Last edited:

Irving

Joined Jan 30, 2016
5,066
More good advice from @Sensacell . To add to that, buy several of those LED if they are not branded as you will probably find they vary significantly and it's likely you won't be running one in isolation so you'll need enough to pick out a few that are similar. Next, for the LEDs, avoid pluggable breadboards as they are extremely unreliable for currents more than a few tens of milliamps. You'll need good soldered joints on stripboard or similar. If your soldering skills need some work now's the time to get some practice in or find someone who can!
 
Top