Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a spec sheet for an ergo dash with LEDs #1

Open
hernantech opened this issue Nov 7, 2023 · 3 comments
Open

Create a spec sheet for an ergo dash with LEDs #1

hernantech opened this issue Nov 7, 2023 · 3 comments
Assignees

Comments

@hernantech
Copy link
Collaborator

hernantech commented Nov 7, 2023

Probably 1 can bus, figure out if it supports 24 or 32 LEDs. Likely will need a single relay for a button, etc. Some way to show fault or warning codes.

@aryamohammadi
Copy link
Collaborator

aryamohammadi commented Nov 7, 2023

support one canbus
can it support 32 leds?
we are gonna have 4 layers with leds on there
1st layer (charge left)
second layer (checks the speed)
third on is how much current we are drawing
4th one is temperature, it is gonna say how hot the accumulator is
we have to figure out what the chip STM F746ZGT6U supports
how much of the led it can support or whether we need to get more chips

@aryamohammadi
Copy link
Collaborator

aryamohammadi commented Nov 15, 2023

1. CAN Bus Support

  • CAN Bus Compatibility: Ensure compatibility with at least one CAN bus system.
  • Data Transfer Rates: Specify the supported data rates for efficient communication.

2. LED Support and Configuration

  • Total LED Support: Assess if the STM32F746ZGT6U microcontroller can support 32 LEDs directly. If not, consider using LED drivers or additional chips.
  • Layer-wise LED Distribution:
  • Layer 1: Charge Left Indicator
  • Layer 2: Speed Monitoring
  • Layer 3: Current Draw Indicator
  • Layer 4: Temperature Monitoring (Accumulator Heat Level)
  • LED Control: Determine the method for controlling LED brightness and color (if applicable).

3. Microcontroller Capabilities (STM32F746ZGT6U)

  • GPIO Pins: Check the number of available GPIO pins for LED connections.
  • Current Handling: Ensure the microcontroller can handle the current draw from all LEDs. If not, use external power sources or drivers.
  • Memory and Processing Power: Evaluate if the microcontroller has sufficient memory and processing power to handle LED control along with other tasks.

4. Additional Hardware Components

  • Relays: Incorporate a relay for button controls, ensuring it can handle the required load.
  • Fault and Warning Indicators: Design a system to display fault or warning codes, possibly using specific LED patterns or colors.

5. Software and Programming

  • Programming Language: C++.
  • Software Requirements: Develop or adapt software for LED control, CAN bus communication, and system monitoring.
  • Fault and Warning Code Integration: Implement a system in the software to trigger LED indicators for various faults or warnings.

6. Power Management

  • Power Supply: Determine the power requirements for all components, especially the total LED setup.
  • Voltage and Current Specifications: Ensure the power supply can handle the voltage and current needs of the system.

7. Testing and Validation

  • Prototype Testing: Build a prototype to test the LED configuration, CAN bus communication, and software integration.
  • Stress Testing: Perform stress tests to ensure system stability under various conditions.

@aryamohammadi
Copy link
Collaborator

aryamohammadi commented Nov 15, 2023

Starting the code:

  • Start with a simple program to blink an LED or send a message over CAN bus to ensure your setup is correct.
  • Gradually build up the functionalities such as led control

Blinking code?

`#include "mbed.h"

DigitalOut myLED(LED1); // Replace LED1 with the actual GPIO pin

int main() {
while (true) {
myLED = 1; // LED is ON
wait(0.5); // 500 ms
myLED = 0; // LED is OFF
wait(0.5); // 500 ms
}
}`

Expand for Multiple LEDs: Define multiple DigitalOut objects for different LEDs.
Control LEDs: Create functions to control these LEDs based on your layers (charge, speed, current, temperature).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants