bl4ckc00k1e Posted January 28, 2016 Posted January 28, 2016 Hi all, I bought this ethernet: The idea is connect to the SPI, but not sure what pines i must to connect... i follow this: Raspi.tv So i connect the pines, exactly like there say, but he connect on the UART not in the SPI :S (have 2 pines more, but the pines that he conenct i have in my ethernet board) So i connect to the gpio of my board and well turn on! yeah! xD: If i fo ifconfig i see this: root@bananapim2:~# ifconfig bond0 Link encap:Ethernet HWaddr 7e:99:6b:7c:04:39 UP BROADCAST MASTER MULTICAST MTU:1500 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:0 (0.0 TX bytes:0 (0.0 eth0 Link encap:Ethernet HWaddr 02:44:07:0d:76:33 inet addr:192.168.1.44 Bcast:192.168.1.255 Mask:255.255.255.0 inet6 addr: fe80::44:7ff:fe0d:7633/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:937 errors:0 dropped:0 overruns:0 frame:0 TX packets:459 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:758921 (741.1 KiB) TX bytes:86608 (84.5 KiB) Interrupt:44 lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:65536 Metric:1 RX packets:70 errors:0 dropped:0 overruns:0 frame:0 TX packets:70 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:31817 (31.0 KiB) TX bytes:31817 (31.0 KiB) wlan1 Link encap:Ethernet HWaddr 98:3b:16:c8:56:6e UP BROADCAST MULTICAST MTU:1500 Metric:1 RX packets:42 errors:0 dropped:42 overruns:0 frame:0 TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:12820 (12.5 KiB) TX bytes:0 (0.0 I should supposed is the bond0 the interface?? ot should be the an eth1? Can i connect this to the SPI? Its enabled SPI on armbian by defaultt? Where is the file that i must change for work with GPIO on Armbian? its /boot/config-4.3.3-sunxi? there are a lot of lines that have SPI options, to many with "=m" and others comments :S I try edit /etc/networks/interfaces and put auto bon0, but not get any IP address, i haven't got any idea about wtf means bond0...
zador.blood.stained Posted January 28, 2016 Posted January 28, 2016 Luckily your first image name contains "28j60", so we can say that it's an enc28j60 module. Linux driver for this is in \drivers\net\ethernet\microchip\enc28j60.c, and required kernel option is CONFIG_ENC28J60, Unfortunately it's not enabled by default in Armbian kernel. For compiling your own kernel please read the documentation here or wait for a new kernel release (I'll enable this module if I don't forget). 1
tkaiser Posted January 28, 2016 Posted January 28, 2016 /boot/config-4.3.3-sunxi? Please keep two things in mind: Banana Pi M2 is no Raspberry Pi. On Raspberry Pi /boot/config.txt has a special meaning, with Armbian a file called /boot/config-4.3.3-sunxi is something completely different! (important to note when you rely on tutorials written for RPi) The Ethernet module you try to use is both slow as hell and power hungry. I would check whether it's ok to draw 160mA from the 3.3V pin Any USB-to-Ethernet adapter is a better choice when you have a free USB port. 1
bl4ckc00k1e Posted February 1, 2016 Author Posted February 1, 2016 Please keep two things in mind: Banana Pi M2 is no Raspberry Pi. On Raspberry Pi /boot/config.txt has a special meaning, with Armbian a file called /boot/config-4.3.3-sunxi is something completely different! (important to note when you rely on tutorials written for RPi) The Ethernet module you try to use is both slow as hell and power hungry. I would check whether it's ok to draw 160mA from the 3.3V pin Any USB-to-Ethernet adapter is a better choice when you have a free USB port. Yeah i know, but i biught this because its cheap for testing, i wanna buy an Ethernet 10/100/1000 to connect to the SPI, i dont wanan connect in the usb... Luckily your first image name contains "28j60", so we can say that it's an enc28j60 module. Linux driver for this is in \drivers\net\ethernet\microchip\enc28j60.c, and required kernel option is CONFIG_ENC28J60, Unfortunately it's not enabled by default in Armbian kernel. For compiling your own kernel please read the documentation here or wait for a new kernel release (I'll enable this module if I don't forget). Thanks, I will try this week, anyway, when this new kernel release will come??
tkaiser Posted February 1, 2016 Posted February 1, 2016 i wanna buy an Ethernet 10/100/1000 to connect to the SPI This will be most likely the slowest GbE implementation in the world. Have you checked the state of drivers already? http://lists.infradead.org/pipermail/linux-arm-kernel/2014-February/229951.html
Igor Posted February 1, 2016 Posted February 1, 2016 In 1-2weeks. https://github.com/igorpecovnik/lib/commit/2a072de9d81ebd0cf3b33de1e006ffb6ca6b56ea 1
tkaiser Posted February 1, 2016 Posted February 1, 2016 In 1-2weeks. And then it's time to start whining: https://github.com/torvalds/linux/blob/master/drivers/spi/spi-sun6i.c (still no DMA so good luck when every single bit needs seconds being handed over the wires )
bl4ckc00k1e Posted February 3, 2016 Author Posted February 3, 2016 This will be most likely the slowest GbE implementation in the world. Have you checked the state of drivers already? http://lists.infradead.org/pipermail/linux-arm-kernel/2014-February/229951.html Wow... is a sith... i will open a new topic because i start to have a lot of problems trying to adding new hardware to the arm boards, thanks for the info Update: Here my new post: http://forum.armbian.com/index.php/topic/663-hardware-question-gpio-spi-uart-wireless-ethernet/
Recommended Posts