×

INDI Library v2.0.6 is Released (02 Feb 2024)

Bi-monthly release with minor bug fixes and improvements

INDI focuser driver for Waveshare Stepper Motor HAT for Raspberry Pi / Rock Pi

  • Posts: 1309
  • Thank you received: 226
So, I guess I had an oopsie. Looks like the saved driver config did not load one time I had it powered on for other tests and the motor ran hot. Gonna have to reprint it's housing.
The default mode seems to be to set the pin Low. Which on the original board is the powered on state.
2 years 9 months ago #72662

Please Log in or Create an account to join the conversation.

  • Posts: 421
  • Thank you received: 102
Try adding this to the /etc/rc.local file, before the exit 0 line:
# turn off the stepper motor
gpioset 0 12=1

That way, as soon as the Pi boots, it will turn off the motor.[/code]
2 years 9 months ago #72663

Please Log in or Create an account to join the conversation.

  • Posts: 1309
  • Thank you received: 226
I took care of the motor running hot on system start already with the pull-up resistor.
I believe the pull-up resistor is an overall better solution because it saves the motor even when the Pi is shutdown but still connected to power.
This time I believe it was when the focus driver started with the default configuration, which for me I noted was to engage to motor on the Revision 1 board. As seen here.
www.indilib.org/forum/focusers-filter-wh...html?start=264#72252

I didn't catch it this time because I assumed it was all saved and loaded correctly. But I do recall my preset positions were empty. So I'm quite certain that is what happened.
2 years 9 months ago #72664

Please Log in or Create an account to join the conversation.

  • Posts: 1309
  • Thank you received: 226
Ok. New information. It wasn't that the profile didn't load. I've noticed it will always engage the motor regardless the first time the indi driver is started after rebooting the system.
It didn't used to do that.
2 years 9 months ago #72667

Please Log in or Create an account to join the conversation.

  • Posts: 1309
  • Thank you received: 226
Restore these lines of code to prevent lockup of the motor on the first run after system boot
Line 91  	DRV8825_SelectMotor(MOTOR1);
Line 92 	DRV8825_Stop();
2 years 9 months ago #72668

Please Log in or Create an account to join the conversation.

  • Posts: 421
  • Thank you received: 102
I'm sorry you had a (partial) meltdown. At least it was the 3D printed bracket and not the motor.

I removed those lines because, if someone used this driver with the new (current) board revision, it would actually turn the stepper motor on, for no good reason.

I just committed a change that will read the config file on startup, and if (and only if) it finds that the user has configured the board revision, it will turn off the stepper motor, based on board revision. If it doesn't find that the user has yet saved a configuration, it assumes the user hasn't yet configured the driver, and it will do nothing, so that we don't make things worse.

-- Kevin
The following user(s) said Thank You: Jon Carleton
2 years 9 months ago #72674

Please Log in or Create an account to join the conversation.

  • Posts: 215
  • Thank you received: 16
Quick bit of useless info:

First, my setup is working flawlessly. THANK YOU!

Second, some programs (other than EKOS) don't load the configuraton by default (or at all) and may rely on a manual configuration load via the INDI Control Panel. CCDciel, for instance, will only load the config if the OPTIONAL "Load INDI config" in the setup profile is checked.

Just FYI...
2 years 9 months ago #72686

Please Log in or Create an account to join the conversation.

  • Posts: 421
  • Thank you received: 102
That's okay Jon, the driver loads the board configuration as soon as the driver starts up, even before any clients connect to it.
2 years 9 months ago #72696

Please Log in or Create an account to join the conversation.

  • Posts: 83
  • Thank you received: 9
Kevin,
I appreciate all the work you have done here.  Can I ask that your code be migrated tot he INDI library for easier install and updates??  Thanks Bruce
2 years 8 months ago #73942

Please Log in or Create an account to join the conversation.

  • Posts: 421
  • Thank you received: 102
Now with Rock Pi 4 support! The Rock Pi is basically a speedier version of the Raspberry Pi.

I've updated the readme in the git repository for instructions on how to build the driver.
2 years 7 months ago #74145

Please Log in or Create an account to join the conversation.

  • Posts: 1
  • Thank you received: 1
Kevin,
     Just wanted to say thank you very much for your efforts with this.   
It worked for me.   

Thanks
Andy 
The following user(s) said Thank You: Kevin Ross
2 years 7 months ago #74443

Please Log in or Create an account to join the conversation.

  • Posts: 62
  • Thank you received: 1
Kevin,

I wanted to activate an older Raspi SD card and to add your wmh driver. First I updated the package list and then upgraded with apt-get dist-upgrade. The subsequent installation failed with-- The C compiler identification is GNU 8.3.0-- The CXX compiler identification is GNU 8.3.0-- Check for working C compiler: /usr/bin/cc-- Check for working C compiler: /usr/bin/cc -- works-- Detecting C compiler ABI info-- Detecting C compiler ABI info - done-- Detecting C compile features-- Detecting C compile features - done-- Check for working CXX compiler: /usr/bin/c++-- Check for working CXX compiler: /usr/bin/c++ -- works-- Detecting CXX compiler ABI info-- Detecting CXX compiler ABI info - done-- Detecting CXX compile features-- Detecting CXX compile features - done-- Found INDI: /usr/lib/arm-linux-gnueabihf/libindidriver.so;/usr/lib/arm-linux-gnueabihf/libindiAlignmentDriver.so (found version "1.9.1")-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29")-- Checking for one of the modules 'libgpiod'CMake Error at /usr/share/cmake-3.16/Modules/FindPkgConfig.cmake:741 (message):  None of the required 'libgpiod' foundCall Stack (most recent call first):  CMakeLists.txt:39 (pkg_search_module)  -- Checking for one of the modules 'libgpiodcxx'CMake Error at /usr/share/cmake-3.16/Modules/FindPkgConfig.cmake:741 (message):  None of the required 'libgpiodcxx' foundCall Stack (most recent call first):  CMakeLists.txt:40 (pkg_search_module)  -- Configuring incomplete, errors occurred!See also "/indi-wmh-focuser/build/CMakeFiles/CMakeOutput.log".

Is this due to the recently released bullseye version of Debian? Do you have a suggestion what I can do to get it compiled? (I could send you the complete log file). I tried to copy over the Indi_wmh_focuser from another card, but obviously this is not enough. What else would I need to copy?

Thanks
Kurt
2 years 6 months ago #75067

Please Log in or Create an account to join the conversation.

Time to create page: 1.324 seconds