A simple DCC++ throttle

แชร์
ฝัง
  • เผยแพร่เมื่อ 28 พ.ย. 2024

ความคิดเห็น • 48

  • @cckspe
    @cckspe 4 ปีที่แล้ว

    Hi Dave, Just finished building the wireless and encoder version of this. Everything appears to be working but I have to finish the Base Station side yet and wire it into my layout. I did have a similar problem to 'gwkdad' but I solved it by using the YWROBOT library which was the correct one for my display. Had to modify the code slightly. I designed and printed a 3D case for it and the power supply is a 5v powerbank with a resistive load to keep it powered up, will have to see how that works out. Thanks for all the effort you put into these videos and keeping some of us sane during these troubled times. Stay safe. Regards Colin W

    • @DaveBodnar
      @DaveBodnar  4 ปีที่แล้ว

      That is good news and good information, Colin - I appreciate your letting me know what you have done.
      Congratulations!
      dave

  • @joshenriquei.oliveira2348
    @joshenriquei.oliveira2348 8 ปีที่แล้ว +1

    Mr. Dave,
    Great job.

  • @w.rustylane5650
    @w.rustylane5650 7 ปีที่แล้ว

    Great video tutorial. I would like to make a throttle but I´ll have to save up for an Arduino Mini to use in the controller. My Arduino Uno is going to be used to make the DCC++ base station. I´ve been following you for a couple of years now especially when you were using the micro servo motors to control switches with the servo tester. I really love your electronics videos. Please keep ´em comin´.

    • @DaveBodnar
      @DaveBodnar  7 ปีที่แล้ว

      Thanks, Rusty - good luck with your projects.
      dave

  • @pukavita
    @pukavita 4 ปีที่แล้ว

    I've watched this video a couple of times and each time I was impressed, not only by the awesome implementation, but also by the quality and how neat it looks. I was wondering when you said you can control up to 4 locos, do you mean 4 locos running concurrently? How do you switch control from one loco to the other seeing that you use a rotary throttle button? It seems that the rotary button preserves the "throttle position" of the current loco. Wouldn't this cause the next loco you switch to, to "throttle match" the current loco? I'd be interested to learn how you resolve that as I'd like to build a remote throttle myself. Many thanks.

  • @alexisautube
    @alexisautube 8 ปีที่แล้ว

    Much enjoyed the video! A fun project! I am thinking on making one. Toward the end of
    the video you mentioned that there are a few software bugs. Can you let
    us know roughly what they are. Not the solution, just your observations or what
    happens when the bugs appear, or... I sure hope you still monitor this channel

  • @ke4nyv
    @ke4nyv 8 ปีที่แล้ว

    Brilliant work, Dave! Very similar to the mockup I was working on, but I never got to the code. Did you settle on TTL Serial. I know SPI was discussed in the forums.

    • @DaveBodnar
      @DaveBodnar  8 ปีที่แล้ว

      Jason - I am using straight serial on the unit shown here and a wireless HC-12 on the wireless version shown on TH-cam here: th-cam.com/video/F6RGIXDaZtg/w-d-xo.html
      dave

  • @thebadgerontheescalator1065
    @thebadgerontheescalator1065 6 ปีที่แล้ว +1

    is it possible to use multiple throttles on a layout? my layout is a small switching layout that could keep 2 operators busy and maybe dispatcher. it would be nice for each to have a throttle

    • @DaveBodnar
      @DaveBodnar  6 ปีที่แล้ว

      Tommy - I have experimented with using two throttles and it does work - that is certainly not a guarantee as I did not do extensive testing nor was the project designed for multiple throttles - it is surely worth a try!
      dave

  • @hankus253
    @hankus253 7 ปีที่แล้ว

    Dave what is your suggestion for compiling your 5-23-16 sketch with the current version of Arduino 1.8.4? I get errors when I compile, saying the LCD.h file can't be located. I've have gathered all the hardware needed and just need to get over this hurtle before putting my efforts to assembly. Can you compile that sketch under the current version of Arduino? Thanks for a great tool never-the-less.

    • @DaveBodnar
      @DaveBodnar  7 ปีที่แล้ว

      I just successfully compiled it using IDE 1.8.4 - if you get that error make sure you have a library called LiquidCrystal2 installed - if not it is included in the ZIP file of my libraries on my web page just above the code listing
      www.trainelectronics.com/DCC_Arduino/DCC++/Throttle/index.htm
      Hope that does it for you
      dave

    • @gwkdad
      @gwkdad 7 ปีที่แล้ว

      You didn't say if you got this solved so... You may need to find the right library for your lcd, I bought a couple from Sainsmart on Amazon and they gave me a link to their own library as the LiquidCrystal2 default library doesn't work with their lcd.

  • @pistiberez
    @pistiberez 3 ปีที่แล้ว

    Hi,thx for great job.Can I use this w/o dcc++ , only normal Roco 10764 central?(Replace Lokmaus) if yes
    how the wiring?Thx

    • @DaveBodnar
      @DaveBodnar  3 ปีที่แล้ว

      This throttle only works with DCC - if you want a wireless unit without DCC have a look here
      th-cam.com/video/JpcBw8IOWUI/w-d-xo.html
      dave

    • @pistiberez
      @pistiberez 3 ปีที่แล้ว

      @@DaveBodnar Dave, thx answering,my Roco 1076 is DCC center, with Lokmaus2,this have
      normal RJ11 kabel with 6 wire.(only 4 connected ,2 to 5):Pin2 - GND, Pin3 and 4 -RS485,
      Pin5 +12V.
      What is ifArduino TX pin connect to RS485 pin3,and Arduino RX pin connect toRS485 pin4?

    • @DaveBodnar
      @DaveBodnar  3 ปีที่แล้ว

      @@pistiberez Sorry but I am not familiar with that system
      dave

  • @hammer5848
    @hammer5848 5 ปีที่แล้ว +1

    Dude, you are awesome, can you take over NASA?

    • @hammer5848
      @hammer5848 5 ปีที่แล้ว

      If all those bitches weren't thoughtless, misdirected, morons, we'd stand a chance

  • @gwkdad
    @gwkdad 6 ปีที่แล้ว

    Hi Dave, you inspired me to build a Arduino Mega 2560 DCC++ Base. I used a real Mega 2560 and Arduino motor shield for the first one, to assure no problems and to make the process easier, it tests out perfect using the diagnostics wiki. Will try again with chinese cheapies next time.
    My problem is on your wiring diagram of this throttle you show A4, A5 coming off the LCD display but I can't find the A4, A5 pins on the pro mini. What am I missing?
    Thanks, -Terry
    Edit: I never had a Pro Mini but I just remembered on Uno and Mega A4/A5 are the same as sda & scl and I have several Mini USB Nano V3.0 boards to use, so I tracked down pinouts for the Pro Mini and my Mini USB Nano and found A4/A5 on your Pro Mini are sda & scl (located inboard of A3) and D4/D5 on my Nano are sda and scl. So I think I found my answer but that leaves me not knowing how to change the code for the keypad if D4/D5 are used by the lcd. Can I just shift the pins for the keypad and Trigger #2? The trigger is just an input, but I don't know how arrays and tables work.
    -Terry

    • @DaveBodnar
      @DaveBodnar  6 ปีที่แล้ว

      Terry - those two pins are not on the long edges on the Pro Mini- on some they are on the short side opposite the programming header (look for labels on the back) or a bit in from the side (see: www.davidpilling.com/wiki/files/ArduinoCrystal/ArduinoCrystal_ProMini_DP3.jpg
      dave

    • @gwkdad
      @gwkdad 6 ปีที่แล้ว

      Yep, got it Thanks.
      Could you tell me if I can arbitrarily change the pin assignments in the following code? Because I need D5 on my Mini USB Nano for my lcd. I believe I can, I just would like someone knowledgeable to confirm that I can change "5" to any available pin.
      byte rowPins[ROWS] = {5, 6, 7, 8 }; //{8,7,6,5 }; //connect to the row pinouts of the keypad
      byte colPins[COLS] = {9, 10, 11}; // {11,10,9}; //connect to the column pinouts of the keypad
      I just ordered a few keypads so I will eventually be able to experiment and find out. :-)
      Thanks, -Terry

    • @DaveBodnar
      @DaveBodnar  6 ปีที่แล้ว

      Terry - I believe you can - the only pin numbers you have to be careful of are those that are defined in a library.
      Good luck!
      dave

    • @gwkdad
      @gwkdad 6 ปีที่แล้ว

      Dave, I am trying to upload this sketch but I was running into library conflicts so I grabbed your zip file and extracted all to my library folder. Now everytime I load a sketch into the IDE I get the following messages (below), and they repeat several times. Do you know what it means?
      Thanks, -Terry
      Invalid library found in C:\Program Files (x86)\Arduino\libraries\Arduino-master: C:\Program Files (x86)\Arduino\libraries\Arduino-master
      Invalid library found in C:\Program Files (x86)\Arduino\libraries\EasyIoT-Cloud-master: C:\Program Files (x86)\Arduino\libraries\EasyIoT-Cloud-master
      Invalid library found in C:\Program Files (x86)\Arduino\libraries\hexbright-master: C:\Program Files (x86)\Arduino\libraries\hexbright-master
      Invalid library found in C:\Program Files (x86)\Arduino\libraries\RFDK_RFM69H_V2_1: C:\Program Files (x86)\Arduino\libraries\RFDK_RFM69H_V2_1
      Invalid library found in C:\Program Files (x86)\Arduino\libraries\__MACOSX: C:\Program Files (x86)\Arduino\libraries\__MACOSX

    • @DaveBodnar
      @DaveBodnar  6 ปีที่แล้ว

      The IDE is unhappy with some of the libraries - you can try deleting those that are mentioned but I have found that the error messages generally do no harm so I just leave them
      dave

  • @DIYDigitalRailroad
    @DIYDigitalRailroad 5 ปีที่แล้ว

    Hi Dave! I love all of your work. It's way beyond my knowledge of arduinos, I am having an issue when I am verifying the sketch that multiple things are throwing the error "not declared in this scope" some of them are "getAddresses" "all2ZeroSpeeed" and "doDCC" to name a couple. I was wondering if you had any advice?

    • @DIYDigitalRailroad
      @DIYDigitalRailroad 5 ปีที่แล้ว

      Nevermind. I pasted the code in a text editor then copied over to the IDE and it worked! I am using it with a Nano, but can't seem to get it running right. Should I use the Pro Mini instead?

    • @DaveBodnar
      @DaveBodnar  5 ปีที่แล้ว

      Either version should work. It is good to hear that you got it to work.
      enjoy
      dave

    • @DIYDigitalRailroad
      @DIYDigitalRailroad 5 ปีที่แล้ว

      @@DaveBodnar Got it working this morning! Thank you so much!

    • @DIYDigitalRailroad
      @DIYDigitalRailroad 5 ปีที่แล้ว

      @@DaveBodnar So apparently the 1.8.7 version of the IDE does not like the sketch and won't compile. I downloaded the 1.8.5 version and it worked fine.

    • @DaveBodnar
      @DaveBodnar  5 ปีที่แล้ว

      Interesting - that is good to know - thanks!
      dave

  • @BRCAOfficial
    @BRCAOfficial 7 ปีที่แล้ว

    Hi Dave, have you release the build or complete code anywhere? Just found this tonight and it looks epic, regards Darren

    • @DaveBodnar
      @DaveBodnar  7 ปีที่แล้ว +1

      Darren - all of the code and other details are on my web page here
      trainelectronics.com/DCC_Arduino/DCC++/Throttle/
      enjoy!
      dave

  • @oldradioshop
    @oldradioshop 7 ปีที่แล้ว

    Hi Dave, What size/type is the pot? I don't see a hardware list on your page. Thanks!

    • @DaveBodnar
      @DaveBodnar  7 ปีที่แล้ว

      The value of the pot can be anything from 10K to 100K or more - it acts as a simple voltage divider so most any value will do.
      dave

    • @oldradioshop
      @oldradioshop 7 ปีที่แล้ว

      Thanks!

  • @yusaseptiandityasputra600
    @yusaseptiandityasputra600 6 ปีที่แล้ว

    hi mr Dave. i have a question. how to use programming track with this DCC++ throttle?

    • @DaveBodnar
      @DaveBodnar  6 ปีที่แล้ว

      The throttle does not do programming - best to hook up to JMRI to program decoders.
      dave

    • @yusaseptiandityasputra600
      @yusaseptiandityasputra600 6 ปีที่แล้ว

      Mr. dave, can i make the throttle (potentiometer) 0 to 126 only? And to control direction with toggle on off on? On for backward, off for idle, on for forward

    • @DaveBodnar
      @DaveBodnar  6 ปีที่แล้ว

      It would require a bit of program revision, but, yes you could do both things
      Good luck & enjoy!
      dave

    • @yusaseptiandityasputra600
      @yusaseptiandityasputra600 6 ปีที่แล้ว

      Sorry Mr.Dave I cant find the line sketch which should be replaced to start 0 to 126. Can I consult you via email?

    • @DaveBodnar
      @DaveBodnar  6 ปีที่แล้ว

      The code is in this area
      potValue = analogRead(pot1Pin); // read the value from the sensor
      if (potValue != potValueOld) {
      NewPotValue = 1;
      //doMainLCD();
      }
      else NewPotValue = 0;
      potValueOld = potValue;
      potValue = (potValue / 4) - 128;
      if (potValue = 126) potValue = 126; // max is 127
      if (potValue