LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware > Slackware - ARM
User Name
Password
Slackware - ARM This forum is for the discussion of Slackware ARM.

Notices


Reply
  Search this Thread
Old 10-28-2017, 05:17 PM   #1
janas03
LQ Newbie
 
Registered: Apr 2008
Location: Warsaw, Poland
Distribution: Slackware64 14.2
Posts: 27

Rep: Reputation: 3
Slackware ARM current help with ppp setup, missing ethernet drivers


Recently I bought OrangePi Zero v1.4 board. It comes with a preinstalled Armbian (this distribution uses 3.x kernel branch). I connected gprs modem and managed to establish ppp connection by adding a script to /etc/ppp/peers and verifying /etc/chatscripts/gprs. I also did wlan and ethernet tests. Everything worked as expected. Ok, let's install Slackware then. Slackware ARM current has support for H2+ and H3 chips so using this thread click I managed to successfully install Slackware the 'normal' way. I have three issues however:
1. I don't really know how to setup ppp. There is no pppsetup in path but I found it somewhere in the /usr/share. So I rebuilt the ppp package using Slackware64-current sources. Ok, let's run pppsetup. It asks questions I don't know answers for and exits with failure. All I want is to have pon and poff (or Slackware alternatives). I know that they will be created upon successful pppsetup finish. How should it be done? I just want to copy my scripts and run pon to start ppp connection.
2. There is no ethernet. ifconfig shows loopback interface only. I compared my and Armbian's uboot output and they are the same (except the model version, my is built for orangepi_zero, Armbian's for orangepi_pc). Both uboots recognize eth0 properly. So I suspect that this may be the kernel driver issue. However, I am out of ideas.
3. The same applies for wlan interface. Grepping dmesg for wlan, radio yields nothing.
 
Old 10-28-2017, 05:45 PM   #2
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 6,725

Rep: Reputation: 4092Reputation: 4092Reputation: 4092Reputation: 4092Reputation: 4092Reputation: 4092Reputation: 4092Reputation: 4092Reputation: 4092Reputation: 4092Reputation: 4092
This question belongs in the "Slackware - ARM" subforum.
 
Old 10-29-2017, 03:05 PM   #3
abga
Member
 
Registered: Jul 2017
Location: EU
Distribution: Slackware x86 & ARM
Posts: 135

Rep: Reputation: 42
Quote:
1. I don't really know how to setup ppp. There is no pppsetup in path but I found it somewhere in the /usr/share. So I rebuilt the ppp package using Slackware64-current sources. Ok, let's run pppsetup. It asks questions I don't know answers for and exits with failure. All I want is to have pon and poff (or Slackware alternatives). I know that they will be created upon successful pppsetup finish. How should it be done? I just want to copy my scripts and run pon to start ppp connection.
You haven't specified the type/model of your GPRS modem and I presume it's on USB. If it's one of those 3G newer dongles (Huawei makes some of them that are to be found everywhere) then the (new) kernel has some updated drivers for them and you get a wan adapter recognized:
https://github.com/torvalds/linux/bl.../usb/cdc_ncm.c

You should see something like this (maybe different manufacturer) in your dmesg:
Code:
[11694.571866] usbserial: USB Serial support registered for GSM modem (1-port)
[11694.599900] huawei_cdc_ncm 1-1.4:1.1: MAC-Address: xx:xx:xx:xx:xx:xx
[11694.621753] huawei_cdc_ncm 1-1.4:1.1: NDP will be placed at end of frame for this device.
[11694.622690] huawei_cdc_ncm 1-1.4:1.1: cdc-wdm0: USB WDM device
[11694.624359] huawei_cdc_ncm 1-1.4:1.1 wwan0: register 'huawei_cdc_ncm' at usb-3f980000.usb-1.4, Huawei CDC NCM device, xx:xx:xx:xx:xx:xx
[11694.624812] usbcore: registered new interface driver huawei_cdc_ncm
[11694.641669] option 1-1.4:1.0: GSM modem (1-port) converter detected
[11694.645459] usb 1-1.4: GSM modem (1-port) converter now attached to ttyUSB0
[11694.645829] option 1-1.4:1.2: GSM modem (1-port) converter detected
[11694.650561] usb 1-1.4: GSM modem (1-port) converter now attached to ttyUSB1
[11694.650829] option 1-1.4:1.3: GSM modem (1-port) converter detected
[11694.651937] usb 1-1.4: GSM modem (1-port) converter now attached to ttyUSB2
- notice the wwan0 interface

If this is the case, you don't even need pppd to establish the connection and instead only run some simple commands to get connected, bundle them in two short scripts - gprs-on and gprs-off

Here's how I do it on a Raspberry Pi - Slack ARM - current with a Huawei 3G USB Modem:
- gprs-on - initializing - network config - establishing connection (added some comments for clarification)
Code:
#!/bin/sh
# Init Huawei 3G Modem -I need to switch the dongle in Serial Mode
# There are 3 default operating modes this dongle knows - CD Mode / Web Mode - HiLink / Serial Mode
/usr/bin/sg_raw /dev/sr0 11 06 20 00 00 00 00 00 01 00
# establishing the connection and provisioning the APN name - my provider uses the name  internet
echo -e "AT^NDISDUP=1,1,\"internet\"\r" > /dev/ttyUSB2

# deleting the default route (Ethernet)  - I don't use DHCP for the "internal affairs"
/sbin/ip route del default via 192.168.0.1

# saving the default resolv.conf before dhclient will modify it
cp /etc/resolv.conf /etc/resolv.conf.bak

# wwan0 - getting the network configuration from the wireless operator
/sbin/dhclient wwan0
- gprs-off - disabling wwan0, restoring wired network config
Code:
#!/bin/sh
/sbin/ifconfig wwan0 down
/sbin/ip route add default via 192.168.0.1
rm /etc/resolv.conf
mv /etc/resolv.conf.bak /etc/resolv.conf
If you really need pppd for you connection, then things are getting a little bit trickier. Basically you need to establish the connection manually with the help of AT commands, dial *#99#, authenticate if required, provide APN name, etc. The creation/editing of the ppp scripts is needed and I can only guide you to follow these HowTos:
https://www.enigma14.eu/wiki/RPi_3G_...th_Huawei_E173
https://wiki.archlinux.org/index.php...dems_with_pppd

... or copy over (adapt) the ppp scripts that were generated and working with your GPRS Modem on Armbian.

As for your other points, I'm sorry I don't own any OrangePi boards & I'm unable to help.

Last edited by abga; 10-29-2017 at 03:42 PM. Reason: typo x 2
 
Old 11-02-2017, 06:41 PM   #4
janas03
LQ Newbie
 
Registered: Apr 2008
Location: Warsaw, Poland
Distribution: Slackware64 14.2
Posts: 27

Original Poster
Rep: Reputation: 3
Thank you @abga for your input. I should have written that I am using m590 gprs modem connected to the gpio pins (4,6,8,10). I have working scripts and the connection is established properly on preinstalled Armbian. What I want to get is to do the same on Slackware (I would not like to use anything other than Slackware).


The current status is:
1. When I try to use the modem it hangs on AT command which in turn times out. I guess there is something wrong with gpio configuration. Although WiringOP works as expected (and in the same way as on Armbian) on Slackware the only tty I don't get errors is ttyS0. However, it times out as I wrote before. On Armbian the same connection is working on ttyS1. Apart from that I can see different devices under /dev/tty* like ttyGS0, ttyGS1. I don't know whether I am missing some kernel module or there is something wrong with the board config.
2. There is a problem/bug(?) in the dtb file for OrangePi Zero in the u-boot sources. Using dtb file built from u-boot sources (2017.09) results in
Code:
MAC IRQ configuration information not found
error in dmesg. When I used dtb file from SlackwareARM-Current (sun8i-h2-plus-orangepi-zero.dtb) ethernet card is initialized properly.
3. OrangePi Zero uses XR819 chip. One can enable wifi by building the driver (which is out of the mainline tree due to its instability I guess) and downloading needed firmware blobs from https://github.com/armbian/firmware/tree/master/xr819. The reported speeds are about 20Mbits.
 
Old 11-06-2017, 02:27 PM   #5
drmozes
Slackware Contributor
 
Registered: Apr 2008
Location: Surrey, England
Distribution: Slackware
Posts: 607

Rep: Reputation: 430Reputation: 430Reputation: 430Reputation: 430Reputation: 430
Quote:
Originally Posted by janas03 View Post
1. I don't really know how to setup ppp. There is no pppsetup in path but I found it somewhere in the /usr/share.
Thanks - that was a bug in the package build script; fixed in 14.2 and current.
 
  


Reply

Tags
arm, ethernet, ppp, slackware, wlan


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] KODI Krypton - 17.x MediaPlayer - Optimized for Raspberry Pi1/Pi2/Pi3 on Slackware ARM 14.2 SF & Slackware ARM - current HF abga Slackware - ARM 6 12-03-2017 03:03 PM
Slackware ARM (current) epic mistake: the current Android kernels are kicked out! Darth Vader Slackware 16 08-25-2013 05:36 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware > Slackware - ARM

All times are GMT -5. The time now is 10:55 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration