Luckfox Lyra on PicoCalc

Thanks you for the great work!

Maybe you can add this one, if not to much hassle:
root@luckfox:/# lsusb
Bus 001 Device 002: ID 0bda:c820 Realtek Semiconductor Corp. 802.11ac NIC (Is a still available USB WIFI Dongle what was recommended for the Hipstot Build.)

1 Like

Hi, about using the internet connection with Picocalc over adb:
If you have adb correct installed you should have a ethernet4 ip device.


You should also see something with:

>adb devices
* daemon not running; starting now at tcp:5037
* daemon started successfully
List of devices attached
2a9dfd2363bcabd0        device

Now you have to do serveral things:
Go to more adapter options:


And activate sharing for Ethernet 4:

For some strange reasons Windows only allows internet Address 192.168.137.1 to be the network.
So you have to set your Pico ip to something in this network: eg.: 192.168.137.10
I am not sure if you need to activate all the services in the Settings:

In command promt:

adb shell
dhclient usb0

Edit: The following should not be needed if you use the dhcp command!!

adb shell
vi etc/init.d/S60netdevicetype

(or nano, as you like)
In line 66:

ifconfig usb0 192.168.137.10

Also you have to set the default route: (I am not sure how to make this permanent)

ip route add default via 192.168.137.1

One tip, you may changes also the nameserver to 8.8.8.8 to be on the sure side for name resolving.

vi /etc/resolv.conf

nameserver 8.8.8.8

Thats all.
I think as soon we have WIFI this will no longer be needed.

1 Like

At this point if you have a driver, it just requires compiling on the Lyra and supplying the firmware bin if needed in /lib/firmware (using the Armbian firmware github tree - GitHub - armbian/firmware: Collection of firmware files necessary for Armbian supported hardware devices to work correctly with the Linux kernel)

This for example the case with the mt7601. - firmware/mediatek/mt7601u.bin at master · armbian/firmware · GitHub

I used the Tenda AX300 with the aic800 driver but it would sometimes give a error not detecting the dongle

Yes, this works well for me also, easier on Ubuntu Linux and i just share and run adb shell then dhclient usb0

so no need to mess with routes

I did also notice the default dns server in /etc/resolv.conf needs to be modified

i use 1.1.1.1

if you have multiple lyra

adb -s serialnumber shell

1 Like

Do you have a link for this dongle ?

Not sure i have same

But see these drivers support a list of dongles

and

Makefile

CONFIG_MULTIDRV = n
CONFIG_RTL8188E = n
CONFIG_RTL8812A = n
CONFIG_RTL8821A = n
CONFIG_RTL8192E = n
CONFIG_RTL8723B = n
CONFIG_RTL8814A = n
CONFIG_RTL8723C = n
CONFIG_RTL8188F = n
CONFIG_RTL8188GTV = n
CONFIG_RTL8822B = y
CONFIG_RTL8723D = n
CONFIG_RTL8821C = n
CONFIG_RTL8710B = n
CONFIG_RTL8192F = n
CONFIG_RTL8822C = n
CONFIG_RTL8814B = n
CONFIG_RTL8723F = n

and

Oh and other dongles in the 6.1.99 kernel also


Seems to be rt88

Is it possible, to change the mode of the USB-C port, to use it with a wifi-dongle? Or is it only possible with a MX1.25-USB adapter? (I ordered one, but the delivery takes ages and I’m impatient)

Dongle is:
TP-Link-Nano-Bluetooth-Archer-T2UB

BTW: I got Frambuffer to work. No luck with Wifi, I think I have to recompile the Kernel ..

If it were possible, how would you be able to change it back without access to the serial?

Dunno, I was thinking about something like

echo $usb_mode > /sys/path/to/something/usb/mode

or

imaginary_android_usb_tool --change-mode host

I mean, my android phone does switch between modes automatically, the lyra does not. Maybe there is a manual way.

If the local terminal works, I (normally) don’t need the serial.

Ok, will c about that dongle, im trying too source it

1 Like

You will need a good internet connection (Developer Image)

3 Likes

Thanks, I will check it out.

1 Like

Can confrim the v1 TP-LINK AC600 dongle works with the rtw88 driver same as the Cody WU1300S 1.0

git clone https://github.com/lwfinger/rtw88
cd rtw88
make
sudo make install
sudo make install_fw


[   11.528040] rtw_8821au 1-1:1.0: Direct firmware load for rtw88/rtw8821a_fw.bin failed with error -2

mkdir -p /lib/firmware/rtw88
cp /lib/other/firmware/rtw88/rtw8821a_fw.bin /lib/firmware/rtw88/
reboot


root@luckfox:/# lsusb -tv
/:  Bus 001.Port 001: Dev 001, Class=root_hub, Driver=dwc2/1p, 480M
    ID 1d6b:0002 Linux Foundation 2.0 root hub
    |__ Port 001: Dev 002, If 0, Class=Vendor Specific Class, Driver=rtw_8821au, 480M
        ID 2357:011e TP-Link AC600 wireless Realtek RTL8811AU [Archer T2U Nano]
root@luckfox:/# 

nmcli -m m
wlx98ba5fcfc4c2: connected to Frozen
	"TP-Link AC600 Realtek RTL8811AU"
	wifi (rtw_8821au), 98:BA:5F:CF:C4:C2, hw, mtu 1500
	ip4 default
	inet4 172.16.48.52/22
	route4 172.16.48.0/22 metric 600
	route4 default via 172.16.50.1 metric 600

root@luckfox:/# speedtest-cli 
Retrieving speedtest.net configuration...
Testing from OPTINET (197.94.94.95)...
Retrieving speedtest.net server list...
Selecting best server based on ping...
Hosted by Level-7 Internet (PTY) LTD (Johannesburg) [1259.92 km]: 32.382 ms
Testing download speed................................................................................
Download: 78.41 Mbit/s
Testing upload speed......................................................................................................
Upload: 24.56 Mbit/s

I may post an updated image due to a bug i found

3 Likes

Works quite well!

Can you give me a hint, how to build an Ubuntu-image myself?
The SDK only gives me the options to create a buildroot or yocto system. My problem is, that Ubuntu is not optimized, to run with so little memory and even with basic stuff (like apt) it starts to swap. I want to try, to build an image, that is a bit more gentle to the ressources, but still has a sufficient collection of packages. Maybe based on Alpine or even OpenWRT.

1 Like

Restore the Ubuntu OS build functionality from a previous version SDK

1 Like

Just for future reference: Luckfox_Lyra_SDK_250311.tar.gz seems to be the last one with Ubuntu support.

yes, that the last available sdk version available for download with ubuntu os build support. refer to luckfox forum for the changelog also

According to the display manual on github (PicoCalc/ST7365P_SPEC_V1.0.pdf at master · clockworkpi/PicoCalc · GitHub) the picocalc display has MIPI DSI support. I wonder how hard it would be to adapt it to the lyra’s display connector?

My version of the sound fix, for both L and R channels (pins 4 and 5)


I also have an RTC attached to the I2C bus.

2 Likes

if any GPIO will work, then you could use the GPIO pads on the underside of the lyra board:

- (found in the Lyra schematic https://files.luckfox.com/wiki/Luckfox/RK3506/PDF/Luckfox%20Lyra%26Luckfox%20Lyra%20Plus%20SCH.pdf).

You probably also do not need to wire the CS pin, since there is nothing else on this bus you could just tie it to GND. I’m going to try using B2, B3, B4, B5, B6, and D0. The other pins appear to be an I2S bus I’d like to experiment with later.