DCC-EX / Support-Planning

DCC++EX Repo to hold project planning documentation and processes
1 stars 1 forks source link

Ticket Submitted via Website #494

Closed fire-bot closed 1 year ago

fire-bot commented 1 year ago

Sent by (dccextended@gmail.com). Created by fire.


glen created a ticket

Name: glen o'connor

Email: ghoconnor@icloud.com

Timezone: 10

Software: EX-CommandStation

Version: 4.0.x

Title: makerfabs motor sheild

Description: what do i need to change to use this shield.

Remaining email Quota: 100

Ash-4 commented 1 year ago

This board does not have onboard current sense, so an external sensor will be needed.

It seems the documentation has gotten ahead of the code... https://dcc-ex.com/reference/hardware/motorboards/makerfabs-h-bridge-motor-shield.html

There is a statement: Select MAKERFABS_MOTOR_SHIELD in your config.h file. -- but perhaps it should read: You will likely need something like this in your config.h file. //-------------------- // Assuming current sensing via single MAX471 // MAX471 outputs 1V/A, Current conversion factor is ((5/1024)/1)*1000 = 4.88

#define MY_MOTOR_SHIELD F("MY_MOTOR_SHIELD"),         \
        new MotorDriver(9, 4, 5, -6, A0, 4.88, 3000, UNUSED_PIN), \
        new MotorDriver(10, 7, 8, UNUSED_PIN, A0, 4.88, 3000, UNUSED_PIN)
#define MOTOR_SHIELD_TYPE MY_MOTOR_SHIELD

//---------------------

for the Makerfabs shield, you might use the Pololu ACS724 0-10A. The MAX471 is a 0-3A sensor, and might be fine if used with a 3A or less power supply. https://www.pololu.com/product/4042 [out of stock] The specs on the 0-10A version look good, with 0.4v/A current sensing.

Note that there are issues/differences to consider when using a common current sensor on the DC input from the power supply. You would need to have MAIN track power off when using the programming track.

The use of a current sensor with a 0-10A range will result in lower granularity/sensitivity, and may result in less reliable performance on the programming track. For example, it worked for several of my HO scale locomotives with higher current draw, but a fairly recent Athearn Genesis with OEM Tsunami2 pulses at much lower current.

As a result, I no longer use an external current sensor for programming. The external current sensor will work for MAIN.

With this Makerfabs shield, I would consider using one-half of a separate L298N for programming. https://dcc-ex.com/reference/hardware/motorboards/L298N-motor-board-setup.html

There is a development branch which includes the ability to define up to 8 tracks. So you might use half of the MakerFabs board for each half of your layout, somewhat like having a booster. And use one track for the L298N programming.

(Note that the MakerFabs and L298N boards would require additional circuitry for use with DC/DCX -- a feature in development.)

Suggest joining the discussion on discord. https://discord.gg/y2sB4Fp

FrightRisk commented 1 year ago

answered in email