Crates.io | cu-rp-sn754410-new |
lib.rs | cu-rp-sn754410-new |
version | |
source | src |
created_at | 2024-10-12 19:59:29.708072 |
updated_at | 2024-12-05 22:16:26.006237 |
description | Rust library for controlling the SN754410 motor driver on the Raspberry Pi for Copper |
homepage | https://github.com/copper-project |
repository | https://github.com/copper-project/copper-rs |
max_upload_size | |
id | 1406835 |
Cargo.toml error: | TOML parse error at line 18, column 1 | 18 | autolib = false | ^^^^^^^ unknown field `autolib`, expected one of `name`, `version`, `edition`, `authors`, `description`, `readme`, `license`, `repository`, `homepage`, `documentation`, `build`, `resolver`, `links`, `default-run`, `default_dash_run`, `rust-version`, `rust_dash_version`, `rust_version`, `license-file`, `license_dash_file`, `license_file`, `licenseFile`, `license_capital_file`, `forced-target`, `forced_dash_target`, `autobins`, `autotests`, `autoexamples`, `autobenches`, `publish`, `metadata`, `keywords`, `categories`, `exclude`, `include` |
size | 0 |
See the crate cu29 for more information about the Copper project.
The SN754410 is a quadruple half-H driver that can be used to drive motors, solenoids, and other inductive loads. It can drive up to 1A of current at 4.5V to 36V. The driver is capable of driving two motors in both directions using the 2 PWMs generators from the Raspberry Pi.
OS: Linux on Rapsberry Pi.
hardware: Texas Instrument SN754410
It can drive a DC motors like the MG513P2012:
Add the following to your Cargo.toml
:
[dependencies]
cu-rp-sn754410 = "0.2.3"
In your Copper RON config file, add the following:
tasks: [
(
id: "dst",
type: "cu_rp_sn754410::SN754410",
),
]
There is no config for this driver.
When you connect this driver to the rest of the system you need to use the cu_rp_sn754410::MotorMsg
message type.
cnx: [
(src: "src", dst: "dst", msg: "cu_rp_sn754410::MotorMsg"),
],
In this message the field current_power is the power that you want to apply to the motor. It is a value between -1.0f32 and 1.0f32. The negative values are for the reverse direction.