This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Autopilot Errors: no motor controller!
#11
Hi Sean,
It seems the cables on the Pi side of the connector are #1 coded while they are #3 coded on the motor controller side. So I got the most difficult intelligence test, combining those two combinations; not yet sure whether I failed or succeeded. But I am pretty sure I got 3.3V and gnd right. That's easy to measure if nothing else. The other two are the really confusing ones. What starts out as brown on the controller side comes out green in the other end. I know that from measuring continuity. And the other combo is green/ blue. Anyway, if I connect blue to pin 10 and green to pin 8 the leds will blink, while there will just be the power LED when I connect it the other way. Either way I have no success with the next step; I then get pypilot server: Connected and Autopilot Errors: No motor controller! in the Browser Control interface. I agree that I should switch places between blue and green so I can only say that I am super confused. I will sleep on it now!
Reply
#12
(2021-04-14, 10:33 PM)Sparhawk76 Wrote: I have a raspberry pi4 running openplotter, connected to one of Sean's IMU sensor modules, which is connected to the motor controller, also purchased from Sean.   I'm guessing I'm missing something simple, but I can't get Pypilot to sense that the motor controller is connected.   There is one red LED on on the motor controller, if that makes a difference. Also the IMU appears to be working, providing relatively accurate heading data, and pitch and roll.

In the web interface for pypilot I see:

pypilot Server: Connected
Servo Flags:
Autopilot Errors: no motor controller!
Web Server Latency: 4 ms

Any ideas what I might be missing?   

Thanks
Sparhawk

I'm really sorry for not being able to provide any significant help. The only thing I can say is that it's quite weird that the interface for pypilot says nothing about the servo flags.
Reply
#13
(2021-04-16, 09:38 PM)Guttagrynna Wrote: Hi Sean,
It seems the cables on the Pi side of the connector are #1 coded while they are #3 coded on the motor controller side. So I got the most difficult intelligence test, combining those two combinations; not yet sure whether I failed or
succeeded. But I am pretty sure I got 3.3V and gnd right. That's easy to measure if nothing else. The other two are the really confusing ones. What starts out as brown on the controller side comes out green in the other end. I know that from measuring continuity. And the other combo is green/ blue. Anyway, if I connect blue to pin 10 and green to pin 8 the leds will blink, while there will just be the power LED when I connect it the other way. Either way I have no success with the next step; I then get pypilot server: Connected and Autopilot Errors: No motor controller! in the Browser Control interface. I agree that I should switch places between blue and green so I can only say that I am super confused. I will sleep on it now!

Sorry, it may be as you say #1 is what you are dealing with. If both yellow and green leds are flashing then it is working.
Is /dev/ttyAMA0 working? what does "ls -l /dev/serial0" show?

Can you stop pypilot ensure not running with "ps aux | grep python" and just run pypilot_servo to test the motor controller, please show the output.


(2021-04-17, 01:32 AM)T3chfr3ak72! Wrote: I'm really sorry for not being able to provide any significant help. The only thing I can say is that it's quite weird that the interface for pypilot says nothing about the servo flags.

There are only servo flags when the motor controller is connected.
Reply
#14
[quote pid='19083' dateline='1618669639']
Thank you for your reply. Here are my answers.

"Sorry, it may be as you say #1 is what you are dealing with.   If both yellow and green leds are flashing then it is working.
Is /dev/ttyAMA0 working?  what does "ls -l /dev/serial0" show?"

- I get "lrwxrwxrwx 1 root root 7 apr 17 13:28 /dev/serial0 -> ttyAMA0" which should be ok?


"Can you stop pypilot ensure not running with "ps aux | grep python" and just run  pypilot_servo to test the motor controller, please show the output."

- I enclose a screenshot for this. This was about the same as I saw when running full pypilot from console, minus imu-related stuff.

[/quote]


Attached Files Image(s)
   
Reply
#15
did you disable the seria console in /boot/cmdline.txt ?

When you plug the motor controller in without data, just the red light turns on correct? The blue led never lights right?
Reply
#16
(2021-04-17, 04:21 PM)seandepagnier Wrote: did you disable the seria console in /boot/cmdline.txt ?

When you plug the motor controller in without data, just the red light turns on correct?   The blue led never lights right?

- I have: "plymouth.ignore-serial-consoles" in /boot/cmdline.txt. I have not edited it directly, only disabled through GUI

- No blue LED until I start the pypilot service or pypilot_servo, just the red. But when i run any of those two it lights up, and there is quick blinking from the green and yellow LEDs.
Reply
#17
Finally some success! I did a fresh install of openplotter on another RPi, a 3B+, and now I have a working connection with the motor controller. I have no idea what made the difference, but there are two HATs, a PiJuice and a Wireshark RS485 CAN HAT. Maybe that matters. And that was a RPi 3B.

Not everything works, though. So I will most likely be back on the forum with new questions. The Browser interface is not OK, reporting "Pypilot server: not connected", despite having followed the instructions for a workaround in Ironmans workbook (https://github.com/pypilotWorkbook/workb...-interface). And the OpenCPN interface doesn't seem to be able to connect either.

Anyway, great progress!
Reply
#18
it's possible you were connecting to a remote pypilot?

Check ~/.pypilot/pypilot_client.conf to be sure the web interface isn't going to the wrong place.

Are you running the full autopilot? Can pypilot_client connect from command line?
Reply
#19
(2021-04-18, 12:46 AM)seandepagnier Wrote: it's possible you were connecting to a remote pypilot?

Check ~/.pypilot/pypilot_client.conf to be sure the web interface isn't going to the wrong place.

Are you running the full autopilot?  Can pypilot_client connect from command line?

Those things seem to be OK. pypilot_client gives a long list of parameters, then back to the command prompt.

I followed the instructions for upgrading to the current version of pypilot, in Ironman's workbook, and ran "sudo python3 setup.py install".That made the OpenCPN interface work. The adversary effect was that I can't connect to the browser interface at all; the page doesn't even load in the browser.

So to summarize, I have the motor controller working(!), and access to the ordinary user interface and the Open CPN interface. I would like to get the browser interface working but now I am also looking to check operation with my tiller pilot actuator. I have a second-hand Raymarine Q047, the type that is used with their EV-100 system. I should order a cockpit connector/ socket for it, but for lab testing I might just use some crocodile clips.
Reply
#20
If the page does not even load, you might not be running the pypilot_web service. In openplotter, you start that service by switching the button 'browser control' on. The workbook outlines how you check whether a service is running. If it does run, stop the service and run pypilot_web at the prompt and post the output here.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)