-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pi4 potential? #7
Comments
RPi4 indeed should work. Great, please follow the steps from doc/INSTALL.md file. I do not expect any major differences, except maybe getting kernel 5.4.x+ ready. Please report any questions/issues encountered here and I will do my best to help. When actually running AACS openauto will be useful for initial testing so please have it ready on your PC. |
I have openauto PRO (licensed) on a pi3, and also crankshaft. Both of those work as head units from a stock pixel setup starting setting up with a ubuntu 20.10 arm64b server first. I will fallback to raspbian (aka raspberry pi OS) if i have issues with the USB OTG part. |
First basic check would be to verify existence of /sys/kernel/config/usb_gadget and contents of /sys/class/udc after libcomposite kernel module is loaded. |
the Pi4 2GB Ram version REALLY doesn't like building anbox! I could make a coffee on the CPU. Even the uSD card gets hot from IO thrashing, so dropping that back to single thread building |
To test AACS alone you could skip anbox for now - this one is used only for running OsmAnd navigation. |
good point, a lightweight "video stream only" --> head unit is a thought I have right now |
/home/ubuntu/AA/AACS/AAServer/include/InputChannelHandler.h:14:8: error: ‘set’ in namespace ‘std’ does not name a template type |
The error message is quite informative :-) Try adding #include <set> in InputChannelHandler.h - for some reason for me it works without this one, but it should be there. |
worked, and RealWorld™ in the way of any more setup for next few hours. will let you know how I get on later |
ok, ubuntu and OTG stuff seems "interesting". So AAServer can't find USB to use etc Using raspberry pi OS seems easier for that, however, I can't build with cmake -- Checking for module 'gstreamer-base-1.0' I know libpcap (inc dev) is installed ls /usr/lib/arm-linux-gnueabihf/ | grep pcap libpcap.a build and install from source works .. will try testing tomorrow |
Looks to me like pkgconfig file might be missing:
I would call it libpcap packaging issue on your system. |
Yeah. It will pass that with a manual libpcap build . The base raspberry Pi OS is still 32bit ! |
hmm /AACS/build/AAServer $ sudo ./AAServer Got 51, write=2 DefaultChannelHandler: 7 |
Looks like unimplemented feature. 11 is MessageType::PingRequest sent by headunit and AACS should probably send PingResponse. In my setup the headunit did not send ping request so I have no way to test. Therefore this is a first opportunity to implement a feature in AAServer :-) Shouldn't be too complicated, best to start with sniffing transmission between your Openauto headunit and phone to see how the phone replies. Or analyze openauto source code to see what it expects. |
I have an idea, I can setup a couple of pi4, 1 with ubuntu arm64, and the other with raspberry pi os ( armv7 / armmhf / 32 bit) such they can be remote connected to for any remote debugging ? and given the 32 bit seems to work, at least before the last error of unexpected messageType, I can throw a piZeroW in as well. whilst a (very) slow CPU, its hot hardware h264 decode and encode to take for example a cast or sinked video source to it to onward send (transcode) to the head unit. so airplay / chromecast for media could both be options! |
very interesting project, I was wondering if I can test on PI zero, got one in hand and ready to play with it. Is there some sort of image that I can use directly? |
Would love to see the posibility to open web page on the screen, lots of ideas can be implemented in that case |
You could try. I have some doubts how this would work for remote debugging given there will be no possibility to disconnect USB cable or reset/see/interact with headunit - or would that be an option as well? |
My idea was to go for electronjs app, I even started fiddling with it (do not expect anything end-user ready anytime soon). It would also be great to have possibility to launch new apps and switch between apps dynamically - that however requires kind of 'gstreamer router' - I haven't investigated that yet though. |
I can easily have HDMI capture connected back to the USB , so it's easy to frame grab or restream what's going on, even remotely. And at least on the primary usb A ports on the raspberry Pi, possible on all, to disable and re enable data. Essentially the same as physically inserting cables. With a small caveat on one particular port that you have to disable the whole hub only, it can be done on an individual port level. |
Depending on the device,, extracting the GPU framebuffer maybe "all" that's needed. The pi is quite capable of doing it, so whatever is rendered to it's (headless) concept of the display can be forwarded to the head unit (GStreamer) I should have some time later to do a setup. I could message you directly with details of login etc etc for it? |
I bet it is not very complicated - it just requires time for someone to test/implement/describe it :-) For sure it should be done outside AAServer and I am wondering whether some solution already exists. Currently window contents of anbox+OsmAnd is sent to AAServer using ximagesrc plugin. What need to be done is an app that would dynamically switch video streams sent to AAServer and direct events received from AAServer to correct application. As for login data - sure, my mail is publicly available on github. |
Hello @tomasz-grobelny , i managed to setup openauto on my linux laptop in order to test AAC. I can run autoapp with QtCreator, and first i wanted to try openauto with my phone. When connecting my phone to laptop via USB, video stream cannot start and i get:
Did you encountered this error as well? If so how did you fixed it? |
I do not recall anything like that, but my first thought would be to install all available packages with gstreamer plugins on your system (good, bad, ugly, etc.). |
Thank you, got it working after i installed |
Hello, I managed to build a yocto image for Raspberry Pi4 which run AAServer. You can check it out here https://github.com/adrianalin/meta-aacs |
That's great :-) I was thinking of some kind of build image automation, but wasn't aware of yocto. Do you think it makes sense to have the yocto build definition in AACS repository or are you planning to maintain separate repository with AACS image definition? Also, I see you disabled GetEvents - any particular reason for that? X11 dependency? Any plans to work on that in the future? Getting back to reading about yocto and trying your work. |
Being new to yocto I am probably missing something simple. UPDATE: reading more and more about yocto there is some progress with the build as well... |
Regarding separate repo i'm not sure i can maintain one for long time. Anyway the yocto layer (which will contain the AACS recipe) will have to be separate from the source code, not in the AACS repository. Will try to build with X11 as well, and enable back GstEvents. |
Be aware that a yocto build may take quite a long time. This is how my layers directories look on my side (notice csng_yocto layer which contains the aacs recipes): |
I also started to clean-up the layer for aacs, and probably will put it in a separate repo as you suggested (now there are all kinds of recipes related to openauto/crankshaft). |
I managed to create a completely separate repo dedicated to meta-aacs https://github.com/adrianalin/meta-aacs :) (will try to maintain it as long as i can). Next will try to enable GetEvents. |
The build is almost halfway through - it will take another several hours it seems. If it succeeds I would have a RPi4 build that I can do nothing with :-) Would it be difficult to rebuild it for Odroid N2? Seems like yocto layers for the hardware should exist (meta-odroid?, meta-meson?). Also do you know if it would be feasible to do automatic builds on some public service (github?) and publish the builds somewhere? |
It should be quite easy to rebuild for odroid, you are right, you need the meta-odroid instead of meta-raspberrypi. You may need to start the build all over (lots of time spent again). Don't forget to change the MACHINE in local.conf .
This would be nice indeed but i didn't do it untill now. Do let me know if there is any way this can be done. Update: here https://github.com/akuster/meta-odroid seems to be a |
Managed to build for odroid-n2, system starts and I can log in. Kernel is 5.10, but it is missing dwc2 and libcomposite kernel modules (and possibly others related). Will need to investigate how to add them (hints welcome).
Unfortunately I am not aware of any such service available freely (that would require quite some resources). Anyway, local build is good enough for now.
Good start, but I understand I would need to setup my own gitlab instance, right? I am also wondering how my changes could be merged into your repo - I had to remove recipes-bsp/bootfiles/rpi-config_git.bbappend (does not seem applicable for Odroid) and changes in local.conf (different usernames for odroid and rpi). But that's after I get the base thing running (see kernel modules above). |
For enabling dwc2 (USB_DWC2) and libcomposite (USB_LIBCOMPOSITE) you may need to run Regarding the merging of the changes, i don't know for sure. Maybe separate branch? Indeed there are some recipes like the one you mentioned should not apply to odroid. |
I don't think branches are the way to go in this case - I made a pull request to your repo, please have a look. |
Yes, you are right. looking on it now. |
The USB-C connection has full OTG support, and the hardware is "reasonable" with 2,4,8GB ram options.
Have hardware, and happy to help support / test
The text was updated successfully, but these errors were encountered: