OpenCV Image and My initial Robot tests

OpenCV, Python and other image processing questions
Post Reply
jemartel
Posts: 5
Joined: Thu May 09, 2019 3:01 am

OpenCV Image and My initial Robot tests

Post by jemartel » Tue Jun 18, 2019 11:01 pm

So, after getting the SLP image setup and tested I had wanted to add the stereopi to a mobile platform. I was confused at the "locked image" conversion to "unlocked and writable" so I started with the OpenCV image to perform this task. I first got the OpenCV image to boot and I was able to get my localizations completed and was able to run the 1_test.py test? and got my two images. Being that I didn't have a chessboard for the calibration tests (which really didn't matter to me) all I wanted to connect an Adafruit PWM 16 Channel I2C board and a L298N motor controller with 2 DC motors to run basic scripts at first. And I was able to do this. What I have noticed is even when powering the stereopi via the supplied USB cable to a 5v 2A RPi power adapter, I found that my USB hub was not being powered or not correctly. I could not install a Wifi or a BT/Wifi dongle into either USB port and have it work. I could plug those into a powered USB 7 port HUB, with the keyboard, mouse, BT/WiFI dongle and connect that to the usb port and have every work via the stereopi's desktop. Am I missing something here?
Also I intend "possibly" to stream the stereopi's video via the mpgstreamer app and use webiopi to control the robot;s motion, as configured using Osoyoo's RPi smart car/tank kit procedure.

I have initial test video that I haven't uploaded to Youtube yet to post here

User avatar
Realizator
Site Admin
Posts: 292
Joined: Tue Apr 16, 2019 9:23 am
Contact:

Re: OpenCV Image and My initial Robot tests

Post by Realizator » Wed Jun 19, 2019 7:47 am

Hello Jemartel,
Am I right understand, that if you connect external HUB to the StereoPi USB, it works correctly only with additional power to this HUB?
This situation usually appears when your power source has some voltage drop under the load. For example, if you consume 1.5A from your power source, your power source may provide not 5V but 4.5V or so. As HUB eats some power itself, it is unable to start.
If your power source is reliable and you know it, then you may consider another potential problem. Every USB wire also leads to some voltage lost (like 5V input and 4.5-4.7V output). So if your HUB has a long USB cable, this may be an issue to.

To debug such an issues I use USB power meter like this one.

Could you please check voltage on your HUB input?
Eugene a.k.a. Realizator

jemartel
Posts: 5
Joined: Thu May 09, 2019 3:01 am

Re: OpenCV Image and My initial Robot tests

Post by jemartel » Wed Jul 03, 2019 10:44 am

Thanks for reply. Just to clarify, i have the stereopi powered by a separate 5v 3A usb plug.
I am using the 7 port usb hub, also 5v 3A, initially for keyboard and mouse and is connected to one of the stereopi's usb ports. All is well.
When i plug any wifi dongle into the stereopi's usb port without the hub it (wifi) does not power on, indicating that the stereopi's usb port are not powered by same input power as mainboard.
I need wifi/BT to remote in once attached to robot chassis, which is now built. The hub will be disconnected.
The robot motors and controller has its own battery source.
Only connection between robot motors and controller(L298) are a ground, I2C , and GPIO/PWM pins on the stereopi.
I haven't checked voltages yet on stereopi and usb ports with or without wifi connected during boot.

User avatar
Realizator
Site Admin
Posts: 292
Joined: Tue Apr 16, 2019 9:23 am
Contact:

Re: OpenCV Image and My initial Robot tests

Post by Realizator » Mon Jul 08, 2019 10:30 am

jemartel wrote:
Wed Jul 03, 2019 10:44 am
Thanks for reply. Just to clarify, i have the stereopi powered by a separate 5v 3A usb plug.
I am using the 7 port usb hub, also 5v 3A, initially for keyboard and mouse and is connected to one of the stereopi's usb ports. All is well.
When i plug any wifi dongle into the stereopi's usb port without the hub it (wifi) does not power on, indicating that the stereopi's usb port are not powered by same input power as mainboard.
I need wifi/BT to remote in once attached to robot chassis, which is now built. The hub will be disconnected.
The robot motors and controller has its own battery source.
Only connection between robot motors and controller(L298) are a ground, I2C , and GPIO/PWM pins on the stereopi.
I haven't checked voltages yet on stereopi and usb ports with or without wifi connected during boot.
Well, I'd prefer to test all parts step-by-step to understand the power issues. Disconnect all equipment, and start with WiFi dongle only (and a monitor). If it works - power it off, and connect one more equipment. And voltage/current indicator will help you a lot to find the issue.
I've connected both WiFi (high-power, 1 Watt https://www.alfa.com.tw/products_detail/10.htm) and LTE dongle, and they both working well simultaneously.
Eugene a.k.a. Realizator

jemartel
Posts: 5
Joined: Thu May 09, 2019 3:01 am

Re: OpenCV Image and My initial Robot tests

Post by jemartel » Thu Nov 21, 2019 2:09 am

Well, its November. I've still not resolved the issue with my stereo pi's USB hub and a wifi dongle. I am trying to revisit my robot. Everything works with the robot tethered to the hub, during programming. When I try to power everything with only the wifi connected to the usb ports onboard, then issues arise. After having the wifi dongle and keyboard attached via a 5 port usb hub the is powered seperately from stereopi. I have configured the SD card and the WIFI address and shutdown. I then moved WIFI dongle to lower stereopi usb port, nothing is in top usb port. stereopi is powered via a 5v 3a usb battery pack. I am using putty to remote into the stereopi, or at least trying to remote in. It appears that the stereopi's usb ports have an issue. I want to resolve this and post the completed project on hackster.io

User avatar
Realizator
Site Admin
Posts: 292
Joined: Tue Apr 16, 2019 9:23 am
Contact:

Re: OpenCV Image and My initial Robot tests

Post by Realizator » Thu Nov 21, 2019 6:12 am

Ough, Jemartel, I thought you've solved this issue, as there were no any additional replies or questions from you. I sent you a personal email with additional question and replacement details. Please answer.
Eugene a.k.a. Realizator

Post Reply