Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
Next revisionBoth sides next revision
toh:tp-link:tl-sg2210p_v3 [2023/09/08 21:24] – Created from the form at meta:create_new_device_page mrnuketoh:tp-link:tl-sg2210p_v3 [2024/07/17 16:15] – [OEM installation using the TFTP method] mrnuke
Line 7: Line 7:
 {{page>meta:infobox:construction&noheader&nofooter&noeditbtn}} {{page>meta:infobox:construction&noheader&nofooter&noeditbtn}}
  
-//Write a short, relevant description of the device. Include a technical overview, but avoid marketing buzzwords/useless stuff. Two to four sentences is about right. A picture is goodtooEdit the page to see how to add pictures.// +The TP-Link TL-SG2210P v3 is an RTL8380M based switch with two SFP slotsand PoE 802.3af on all eight RJ-45 ports
- +
-<WRAP BOX> +
-FIXME Any text with a light background (like this one) provides instructions for creating the Details Page. When you have filled in correct/useful information (instead of any template that's there) **remove the instructions, as well as the ''<nowiki><WRAP></nowiki>'' that encloses it.** +
-</WRAP>+
  
 /*****/ /*****/
Line 18: Line 14:
  
 {{media:example:genericrouter1.png?200|Generic Router}} {{media:example:genericrouter1.png?200|Generic Router}}
- 
-<WRAP BOX> 
-FIXME 
-===== Getting started with a new Device Page ===== 
-  - This is an empty template that suggests the information that should be present on a well-constructed Device Page. This means, that **you have to fill it with life and information.** 
-  - There are several "fixme" tags with text on a light background (like this text) throughout this template. As you fill in the page, remove those tags so that people can judge its completeness. 
-  - When there are no more "fixme" tags left, delete this one too, along with the ''<nowiki><WRAP></nowiki>'' that encloses it. 
- 
-===== Keep the articles modular ===== 
-  * Please include only model specific information, omit bla,bla and put everything generic into separate articles 
-  * If you have no time to write certain stuff, link to [[docs:start]] 
-  * [[docs:guide-user:base-system:start]] should lead the way, do not explain this again 
-  * DO NOT provide a complete howto here! Instead //groom// the [[docs:start|general documentation]]. 
-</WRAP> 
  
 ===== Supported Versions ===== ===== Supported Versions =====
  
-<WRAP BOX> +<!-ToH: { 
-FIXME +  "source": "json"
-  The tables below are automatically generated, **once the correct filters for Brand and Model are set.** +  "dom": "t"
-  - If the tables below show information for ''<nowiki>TP-Link TL-SG2210P v3</nowiki>''everything is OK and you can delete this text and the ''<nowiki><WRAP></nowiki>'' that encloses it. +  "paging": false, 
-  - If the tables below contain "Nothing found", it means that either +  "rotate"true
-    - the dataentry page for TP-Link TL-SG2210P v3 is missing. Please [[meta:create_new_dataentry_page|create a new dataentry page]] firstthen reload this page. The tables should then contain $something. If they do, delete this text and the ''<nowiki><WRAP></nowiki>'' that encloses it. +  "shownColumns": ["brand""model""version""supportedcurrentrel""oemdevicehomepageurl""forumsearch""deviceid"]
-    - filters are not set correctly. Most common reason for "Nothing found": The dataentry does not contain a Versionbut we are filtering here for version -> Please **edit this section and adjust the filters with the proper Brand, Model and Version.** In case the dataentry does not contain a version, delete the line ''filter  : Versions~''. Just tryit's easy. The tables should then contain $something. If they do, delete this text and the ''<nowiki><WRAP></nowiki>'' that encloses it. +  "filterColumns"{"brand": "^TP-Link$", "model""TL-SG2210P$""version""^v3$"} 
-  - If the tables still contain "Nothing found": Don't panic, calm down, take a deep breath and [[:contact|contact a wiki admin]] (tmomas) for help. +-->
-</WRAP> +
- +
----- datatable ---- +
-cols    : BrandModelVersionsSupported Current RelOEM device homepage URL_urlForum Search_search-forumsDevice Techdata_pageid +
-headers : Brand, Model, Version, Current Release, OEM Info, Forum SearchTechnical Data +
-align   : c,c,c,c,c,c,+
-filter  : Brand=TP-Link +
-filter  Model=TL-SG2210P +
-filter  : Versions~v3 +
----- +
- +
-/* If no unsupported functions knowncomment out the following datatable or delete it. */ +
----- datatable ---- +
-cols    Unsupported Functions_unsupporteds +
-filter  : Brand=TP-Link +
-filter  : Model=TL-SG2210P +
-filter  : Versions~v3 +
----- +
- +
-===== Experimental Versions ===== +
- +
-/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *  +
-   The official Table of Hardware only lists current, stable versions of OpenWrt. +
-   Use this space to describe any on-going efforts to create a newer version       * +
-   of the firmware for this device. Provide links to firmware images,              * +
-   active threads on the forum, or other sources of information.                   * +
- * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +
- +
-//None at this time.//+
  
 ===== Hardware Highlights ===== ===== Hardware Highlights =====
----- datatable ---- +<!-- ToH: { 
-cols    ModelVersionsCPUCPU MHz, CPU Cores_numcores, Flash MB_mbflashs, RAM MB_mbram, WLAN Hardware, WLAN 2.4GHz, WLAN 5.0GHz, Ethernet 100M ports_, Ethernet Gbit ports_, ModemUSB ports_ +  "source""json", 
-header  : ModelVersion,SoC,CPU MHz,CPU Cores,Flash MB,RAM MB,WLAN Hardware,WLAN2.4,WLAN5.0,100M ports,Gbit ports,Modem,USB +  "dom": "t", 
-align   : c,c,c,c,c,c,c,c,c,c,c,c,c +  "paging": false, 
-filter  : Brand=TP-Link +  "rotate": true
-filter  Model=TL-SG2210P +  "shownColumns"["model""version""cpu""cpumhz""cpucores""flashmb""rammb""wlanhardware""wlan24ghz""wlan50ghz""ethernet100mports""ethernet1gports""modem""usbports"]
-filter  Versions~v3 +  "filterColumns": {"brand""^TP-Link$", "model""^TL-SG2210P$", "version""^v3$"} 
-----+-->
  
  
Line 87: Line 40:
 /* stable release */ /* stable release */
 /* uncomment once stable release is available /* uncomment once stable release is available
----- datatable ---- +<!-- ToH: { 
-cols    ModelVersionsSupported Current RelFirmware OpenWrt Install URL_urlFirmware OpenWrt Upgrade URL_url, Firmware OEM Stock URL_url +  "source""json", 
-headers ModelVersionCurrent ReleaseFirmware OpenWrt InstallFirmware OpenWrt UpgradeFirmware OEM Stock +  "dom": "t", 
-align   : c,c,c +  "paging": false, 
-filter  : Brand=TP-Link +  "rotate": true
-filter  Model=TL-SG2210P +  "shownColumns"["model""version""supportedcurrentrel""firmwareopenwrtinstallurl""firmwareopenwrtupgradeurl""firmwareoemstockurl"]
-filter  Versions~v3 +  "filterColumns"{"brand": "^TP-Link$", "model""^TL-SG2210P$", "version""^v3$"} 
-----+-->
 */ */
  
Line 100: Line 53:
 /* snapshot */ /* snapshot */
 /* delete once stable release is available */ /* delete once stable release is available */
----- datatable ---- +<!-- ToH: { 
-cols    ModelVersionsSupported Current RelFirmware OpenWrt snapshot Install URL_url, Firmware OpenWrt snapshot Upgrade URL_url, Firmware OEM Stock URL_url +  "source""json", 
-headers ModelVersionCurrent ReleaseFirmware OpenWrt snapshot InstallFirmware OpenWrt snapshot UpgradeFirmware OEM Stock +  "dom": "t", 
-align   : c,c,c +  "paging": false
-filter  : Brand=TP-Link +  "shownColumns"["model""version""supportedcurrentrel""firmwareopenwrtsnapshotinstallurl""firmwareopenwrtsnapshotupgradeurl""firmwareoemstockurl"]
-filter  Model=TL-SG2210P +  "filterColumns"{"brand": "^TP-Link$", "model""^TL-SG2210P$", "version""^v3$"} 
-filter  Versions~v3 +-->
-----+
  
  
Line 123: Line 75:
 ==== OEM easy installation ==== ==== OEM easy installation ====
  
-<WRAP BOX> +There is no known way to install OpenWRT from the OEM firmwareUse the TFTP method below.
-FIXME //The instructions below are for Broadcom devices and only serve as an example.//\\ +
-**//Remove / modify them if they do not apply to this particular device!//** +
- +
-This section deals with +
-  * How you install OpenWrt from a device freshly opened +
-  * The steps required such as reset to factory defaults if the device has already been configured +
- +
-**Note:** Reset router to factory defaults if it has been previously configured. +
-  * Browse to ''<nowiki>http://192.168.1.1/Upgrade.asp</nowiki>'' +
-  * Upload .bin file to router +
-  * Wait for it to reboot +
-  * Telnet to 192.168.1.1 and set a root password, or browse to ''<nowiki>http://192.168.1.1</nowiki>'' if LuCI is installed. +
-</WRAP>+
  
 ==== OEM installation using the TFTP method ==== ==== OEM installation using the TFTP method ====
  
-->  [[docs:guide-user:installation:generic.flashing.tftp]]+The U-Boot firmware drops to a TP-Link specific "BOOTUTIL" shell at 
 +38400 baudThere is no known way to exit out of this shell, and no 
 +way to do anything useful.
  
-=== Specific values needed for tftp ===+Ideally, one would trick the bootloader into flashing the sysupgrade 
 +image first. However, if the image exceeds 6MiB in size, it will not 
 +work. To install OpenWRT:
  
-<WRAP BOX> +Prepare a tftp server with
- +  server address: 192.168.0.146 
-FIXME Enter values for "FILL-IN" below +  the image as: "uImage.img"
- +
-^ Bootloader tftp server IPv4 address  | FILL-IN   | +
-^ Bootloader MAC address (special)     | FILL-IN   | +
-^ Firmware tftp image                  | [[:downloads|Latest OpenWrt release]] (**''NOTE:''** Name must contain //"tftp"//) | +
-^ TFTP transfer window                 | FILL-IN seconds                                | +
-^ TFTP window start                    | approximately FILL-IN seconds after power on   | +
-^ TFTP client required IP address      | FILL-IN                                        | +
- +
-</WRAP> +
- +
-===== Upgrading OpenWrt ===== +
-->  [[docs:guide-user:installation:generic.sysupgrade]] +
- +
-<WRAP BOX> +
- +
-FIXME These are generic instructions. Update with your router's specifics. +
- +
-==== LuCI Web Upgrade Process ==== +
- +
-  * Browse to ''<nowiki>http://192.168.1.1/cgi-bin/luci/mini/system/upgrade/</nowiki>'' LuCI Upgrade URL +
-  * Upload image file for sysupgrade to LuCI +
-  * Wait for reboot +
- +
-==== Terminal Upgrade Process ==== +
- +
-If you don't have a GUI (LuCI) available, you can alternatively upgrade via the command line. +
-There are two command line methods for upgrading: +
- +
-  * ''sysupgrade'' +
-  * ''mtd'' +
- +
-Note: It is important that you put the firmware image into the ramdisk (/tmp) before you start flashing. +
- +
-=== sysupgrade === +
- +
-  * Login as root via SSH on 192.168.1.1, then enter the following commands: +
- +
-<code> +
-cd /tmp +
-wget http://downloads.openwrt.org/snapshots/trunk/XXX/xxx.abc +
-sysupgrade /tmp/xxx.abc +
-</code> +
- +
-=== mtd === +
- +
-If ''sysupgrade'' does not support this router, use ''mtd''+
- +
-  * Login as root via SSH on 192.168.1.1, then enter the following commands: +
- +
-<code> +
-cd /tmp +
-wget http://downloads.openwrt.org/snapshots/trunk/XXX/xxx.abc +
-mtd write /tmp/xxx.abc linux && reboot +
-</code> +
- +
-</WRAP> +
- +
-===== Debricking ===== +
--> [[docs:guide-user:troubleshooting:generic.debrick]]+
  
-===== Failsafe mode ===== +Power on device, and stop boot by pressing any key. 
--> [[docs:guide-user:troubleshooting:failsafe_and_factory_reset]]+Once the shell is active: 
 +  Ground out the CLK (pin 16) of the ROM (U6) 
 +  - Select option "3. Start" 
 +  - Bootloader notes that "The kernel has been damaged!" 
 +  - Release CLK as soon as bootloader thinks image is corrupted. 
 +  - Bootloader enters automatic recovery -- details printed on console 
 +  - Watch as the bootloader flashes and boots OpenWRT.
  
-===== Basic configuration ===== 
--> [[docs:guide-user:base-system:start|Basic configuration]] After flashing, proceed with this.\\ 
-Set up your Internet connection, configure wireless, configure USB port, etc. 
  
 ===== Specific Configuration ===== ===== Specific Configuration =====
Line 261: Line 148:
 ===== Hardware ===== ===== Hardware =====
 ==== Info ==== ==== Info ====
-<WRAP BOX> 
-FIXME 
-  - This table is automatically generated, **once the correct filters for Brand and Model are set.** 
-  - If you see "Nothing." instead of a table, please **edit this section and adjust the filters with the proper Brand and Model.** Just try, it's easy. 
-  - If you still don't see a table here, or a table filled with '¿': [[toh:start|Is there already a Techdata page available]] for TP-Link TL-SG2210P v3? If not: [[meta:create_new_dataentry_page|Create one]]. 
-  - If you see a table with the desired device data, everything is OK and you can delete this text and the ''<nowiki><WRAP></nowiki>'' that encloses it. 
-  - If it still doesn't work: Don't panic, calm down, take a deep breath and [[:contact|contact a wiki admin]] (tmomas) for help. 
-</WRAP> 
  
----- datatemplatelist dttpllist ---- +<!-- ToH: { 
-templatemeta:template_datatemplatelist +  "source""json", 
-cols    BrandModelVersionsDevice TypeAvailabilitySupported Since Commit_gitSupported since RelSupported current RelUnsupportedBootloaderCPUTargetCPU MHzFlash MBsRAM MBSwitchEthernet 100M ports_Ethernet Gbit ports_Comments network ports_ModemVLANWLAN 2.4GHzWLAN 5.0GHzWLAN HardwaresWLAN Comments_Detachable Antennas_USB ports_SATA ports_Comments USB SATA ports_SerialJTAGLED countButton countPower supplyDevice Techdata_pageidForum topic URL_urlwikidevi URL_urlOEM Device Homepage URL_urlFirmware OEM Stock URL_urlFirmware OpenWrt Install URL_urlFirmware OpenWrt Upgrade URL_urlComments_ +  "dom""t", 
-filter  : Brand=TP-Link +  "paging"false, 
-filter  Model=TL-SG2210P +  "rotate": true, 
-filter  Versions=v3 +  "shownColumns": ["brand""model""version""devicetype""availability""supportedsincecommit""supportedsincerel""supportedcurrentrel""unsupported_functions""bootloader""cpu""target""cpumhz""flashmb""rammb""switch""ethernet100mports""ethernet1gports""commentsnetworkports""modem""vlan""wlan24ghz""wlan50ghz""wlanhardware""wlancomments""detachableantennas""usbports""sataports""commentsusbsataports""serial""jtag""ledcount""buttoncount""powersupply""deviceid""owrt_forum_topic_url""wikideviurl""oemdevicehomepageurl""firmwareoemstockurl", "firmwareopenwrtinstallurl", "firmwareopenwrtupgradeurl", "comments"]
-----+  "filterColumns"{"brand": "^TP-Link$", "model""^TL-SG2210P$", "version""^v3$"} 
 +-->
  
 ==== Photos ==== ==== Photos ====
Line 315: Line 195:
 </WRAP> </WRAP>
  
-^ Serial connection parameters\\ for TP-Link TL-SG2210P v3 | EXAMPLE 115200, 8N1, 3.3V |+^ Serial connection parameters\\ for TP-Link TL-SG2210P v3 | 38400, 8N1, 3.3V |
  
 ==== JTAG ==== ==== JTAG ====
 -> [[docs:techref:hardware:port.jtag]] general information about the JTAG port, JTAG cable, etc. -> [[docs:techref:hardware:port.jtag]] general information about the JTAG port, JTAG cable, etc.
  
-How to connect to the JTAG Port of this specific device:\\ +No known JTAG port is present on this device.
-**Insert photo of PCB with markings for JTAG port**+
  
 ===== Bootloader mods ===== ===== Bootloader mods =====
Line 330: Line 209:
 None so far. None so far.
  
- 
-===== Bootlogs ===== 
-==== OEM bootlog ==== 
-<WRAP bootlog> 
-<nowiki>COPY HERE THE BOOTLOG WITH THE ORIGINAL FIRMWARE</nowiki> 
-</WRAP>\\ 
- 
-==== OpenWrt bootlog ==== 
-<WRAP bootlog> 
-<nowiki>COPY HERE THE BOOTLOG ONCE OPENWRT IS INSTALLED AND RUNNING</nowiki> 
-</WRAP>\\ 
  
 ===== Notes ===== ===== Notes =====
 //Space for additional notes, links to forum threads or other resources.// //Space for additional notes, links to forum threads or other resources.//
  
-  * ...+====== Power over Ethernet control ====== 
 +By default, PoE is disabled. To enable PoE on boot, first install **i2c-tools**, then edit **/etc/rc.local** and add the following lines: 
 + 
 +<code>echo 0-0030 > /sys/bus/i2c/drivers/tps23861/unbind  
 +i2cset -y 0 0x30 0x12 0xff 
 +echo tps23861 0x28 > /sys/bus/i2c/devices/i2c-0/new_device  
 + 
 +for poe_enable in $(ls /sys/class/hwmon/hwmon*/in*_enable); do 
 +        echo 1 > $poe_enable 
 +done 
 + 
 +exit 0 
 +</code> 
 + 
 +====== LED control ====== 
 +To enable the status LEDs automatically on boot, copy the following to **/etc/init.d/realtek_leds** and run 
 + 
 +<code> /etc/init.d/realtek_leds enable </code> 
 + 
 +<code> 
 +#!/bin/sh /etc/rc.common 
 + 
 +START=11 
 + 
 +# Enable hardware LED controller on tplink SG2000 series switches 
 +#         ___________________________________________________________ 
 +#        |                                                           | 
 +#        | This is a temporary stand-in for an RTL LED controller    | 
 +#        | driver. It will be obsolete once a kernel driver becomes 
 +#        | available.                                                | 
 +#        |___________________________________________________________| 
 +
 +# Crash course on LED controller: 
 +# ------------------------------- 
 +
 +# From a software perspective, the device has 11 groups with (3) LEDs each. 
 +# We're trying to map the network ports to the LEDs: 
 +#  ______ 
 +# |      | 
 +# | 20-1 | 
 +# |______|                    ______ ______ ______ ______ ______ ______ ______ ______ 
 +# |      |                        |      |      |      |      |      |      |      | 
 +# | 20-0 |                   | 15-2 | 14-2 | 13-2 | 12-2 | 11-2 | 10-2 |  9-2 |  8-2 | 
 +# |______|      ______ ______|______|______|______|______|______|______|______|______| 
 +# |      |     | 26-1 | 24-1 | 15-1 | 14-1 | 13-1 | 12-1 | 11-1 | 10-1 |  9-1 |  8-1 | 
 +# | N/A  |     | 26-0 | 24-0 | 15-0 | 14-0 | 13-0 | 12-0 | 11-0 | 10-0 |  9-0 |  8-0 | 
 +# |______|     |______|______|______|______|______|______|______|______|______|______| 
 +
 +# The port numbering is flexible, but the ordering is fixed. The 'led_p_en_ctrl' 
 +# register is a bitmask that controls which switch ports send status data. 
 +# In this example, Enabling the desired ports results in the bitmask 0x0510ff00 
 +# If there are more bits set than LED groups the extra (LSB) bits are discarded. 
 +
 +# LED[0] and LED[1] are bi-color LEDS 
 +#     - LED[0] = amber, LED[1] = green 
 +#     - Both on or both off turns off the LED 
 +# 0xef: Turn LED1 on 1G, LED 0 on 100M. 
 +
 +# Switch port 20 is not used. The LEDs for port 20 are thus switched to manual 
 +# mode by writing (1 << 20) bitmask in led0_sw_p_en_ctrl, and led0_sw_p_en_ctrl. 
 +
 +# LED[2] in each group is used for PoE or other functions, so they are all set 
 +# to manual mode via the 'led2_sw_p_en_ctrl' register. 
 +
 +tplink_sg2xxx_init_leds() 
 +
 +        local leds="/sys/kernel/debug/rtl838x/led" 
 + 
 +        if [ ! -d "$leds" ]; then 
 +                echo "tplink_sg2xxx_init_leds: Could not find $leds in sysfs" > /dev/kmsg 
 +                return 
 +        fi 
 + 
 +        echo 0x00a4014f > "$leds"/led_mode_ctrl 
 +        echo 0x0510ff00 > "$leds"/led_p_en_ctrl 
 +        echo 0x00100000 > "$leds"/led0_sw_p_en_ctrl 
 +        echo 0x00100000 > "$leds"/led1_sw_p_en_ctrl 
 +        echo 0x0fffffff > "$leds"/led2_sw_p_en_ctrl 
 + 
 +        # Turn on system LED to confirm this script is running 
 +        echo 0x005 > "$leds"/led_sw_p_ctrl.20 
 +
 + 
 +boot() { 
 +        case $(board_name) in 
 +        tplink,sg2008p-v1|\ 
 +        tplink,sg2210p-v3) 
 +                tplink_sg2xxx_init_leds 
 +                ;; 
 +        esac 
 +
 +</code>
  
 ===== Tags ===== ===== Tags =====
  • Last modified: 2024/07/17 16:26
  • by mrnuke