Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/cmdada/adaesc

cheap brushless opensource canbus esc for robosharks
https://github.com/cmdada/adaesc

Last synced: 25 days ago
JSON representation

cheap brushless opensource canbus esc for robosharks

Awesome Lists containing this project

README

        

adaESC Firmware Copyright (C) 2024 Ada Tessar
This program comes with ABSOLUTELY NO WARRANTY
This is free software, and you are welcome to redistribute it
under certain conditions

This project implements a sensorless Brushless DC (BLDC) motor controller using an Arduino and the MCP2515 CAN bus module. The controller uses back-EMF sensing for sensorless commutation and receives speed control commands via CAN bus.

- Sensorless commutation using back-EMF sensing
- Speed control via CAN bus
- Supports minimum speed for reliable sensorless operation
- MOSFET-based motor drive
- canbus control (example in canbus-motor-test.py)
- not rev hardware client (tm) for testing directly over usb

Hardware Requirements

see /partslist

Pinout
+---------------------+
| |
| Arduino |
| |
+----------+ | |
| | | | 5 ----+
| CAN Bus | | | 6 ----|--+
| Module | | | 7 ----|--|--+
| (MCP2515)| | | 8 ----|--|--|--+
| | | | 9 ----|--|--|--|--+
| CS -----|-- 15 | |10 ----|--|--|--|--|--+
| SO -----|-- MISO | | | | | | | |
| SI -----|-- MOSI | | +H L H L H L MOSFET Drivers
| SCK -----|-- SCK | | | | | | | | (for each phase)
| | | | | | | | | |
+----------+ | | v v v v v v
| | Phase A B C
| |
| |A0 --------------------A
| |A1 --------------------B
| |A2 --------------------C
| |
+---------------------+

| | |
| | |
Back-EMF Sensing
(for each phase)
+-------------------+
A --------------------| |
B --------------------| BLDC Motor |
C --------------------| |
| (e.g. T200/Neo ) |
| |
+-------------------+
Notes:
1. MOSFET connections:
- Phase A: High (Pin 5), Low (Pin 6)
- Phase B: High (Pin 7), Low (Pin 8)
- Phase C: High (Pin 9), Low (Pin 10)

2. Back-EMF sensing:
- Phase A: A0
- Phase B: A1
- Phase C: A2

3. CAN Bus Module connections:
- CS: Pin 15
- SO: MISO of Arduino
- SI: MOSI of Arduino
- SCK: SCK of Arduino

4. Double-check all connections before powering on the system!!!! (i maybe shorted a 12v battery :3)
Dependencies

- SPI library (built-in to arduino ide :3)
- MCP2515 library (https://github.com/autowp/arduino-mcp2515)

Setup

1. Connect the MOSFET driver circuit and BLDC motor according to the pinout.
2. Connect the MCP2515 CAN bus module to the Arduino.
3. Install the MCP2515 library in your Arduino IDE.
4. Compile and upload the code to your Arduino board (CHECK YOUR PINOUT AND WIRING NOW!!!!!!)

Usage

1. The motor controller listens for CAN messages with ID 0x123.
2. Send a 16-bit speed value (0-1000) via CAN to control the motor speed.
3. The controller will automatically handle commutation and speed control.

Ensure proper cooling and protection for the MOSFETs and motor during operation.

This code controls high-power electronics. Incorrect use can lead to equipment damage or personal injury. Always ensure proper insulation, cooling, and safety measures when working with motor controllers and power electronics.