Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Quirks for ALLNET ALL-BM300 #16

Open
plush opened this issue Feb 12, 2024 · 1 comment
Open

Quirks for ALLNET ALL-BM300 #16

plush opened this issue Feb 12, 2024 · 1 comment

Comments

@plush
Copy link

plush commented Feb 12, 2024

I was able to get go-dsl working with my ALLNET ALL-BM300 modem after applying some quirks. I don't have a straight up patch because some of the quirks go beyond what go-dsl does right now, and others conflict with some of its assumptions. Here is what I had to do:

  1. Once accessed by telnet (192.168.16.254, user admin, password admin), the command prompt ends in $, not # (lantiq/telnet.go line 37).
  2. The command is found at /opt/opt/intel/bin/dsl_pipe, but it's owned by dsl:dslgrp with permissions 110, so user admin cannot run it. Fortunately, sudo is available. I didn't want to mess with the original binary via overlayfs and simply copied it to /tmp/dsl_pipe_ (there was an unrelated file called /tmp/dsl_pipe there already), then changed its permissions to 755.
  3. When run as user admin, the command fails because it has no write access to /tmp/pipe/dms_0_cmd. I changed this file's permissions to 777 and go-dsl was finally able to read data.
  4. The modem reports API version 5.5.21 and did not understand most commands sent by go-dsl. Treating it as legacy (lantiq/data.go, line 137) helped and made more data appear.
  5. I was able to add the following commandLegacy entries in lantiq/data.go to get more data:
LineFeatureStatus_US         dataItem `command:"lfsg 0" commandLegacy:"lfsg 0 0"`
LineFeatureStatus_DS         dataItem `command:"lfsg 1" commandLegacy:"lfsg 0 1"`
G997_RateAdaptationStatus_US dataItem `command:"g997rasg 0" commandLegacy:"g997rasg 0 0"`
G997_RateAdaptationStatus_DS dataItem `command:"g997rasg 1" commandLegacy:"g997rasg 0 1"`
BandBorderStatus_US           dataItem `command:"bbsg 0" commandLegacy:"bbsg 0 0"`
BandBorderStatus_DS           dataItem `command:"bbsg 1" commandLegacy:"bbsg 0 1"`
  1. I also had to change one of the commandLegacy entries for my modem:
G997_XTUSystemEnablingStatus dataItem `command:"g997xtusesg" commandLegacy:"g997xtusesg 0"`
  1. Finally, for the line state, lantiq/status.go checks for a 0x prefix on the state code in line 235, but only to strip it, not to distinguish between hex and decimal numbers. This is wrong for my modem. The code has no 0x prefix and it isn't hex, but decimal. Decoding it as such in line 239 gave me the correct line state.
@janh
Copy link
Owner

janh commented Mar 4, 2024

Thank you for the report and sorry for the late response.

Adding proper support for the newer API version should be possible, but I need more data. If you can find out the working commands and send them to me including the full output, I'll look into it.

About the first three points: Allowing the $ prompt should not be an issue. If I understand correctly, the other two steps can be done manually by the user, right?

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants