ised_limit
Query ISED Canada limits for wireless power (RSS-247) and IT equipment emissions (ICES-003). Select standard and frequency band to obtain applicable limits.
Instructions
Get ISED Canada (RSS-247 / ICES-003) limits. Returns wireless power limits and IT equipment emission limits.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| standard | No | ISED standard to query | |
| band | No | Frequency band (for RSS-247) |
Implementation Reference
- The handler function that executes the 'ised_limit' tool logic. It looks up ISED Canada regulatory limits based on the 'standard' parameter (rss-247, ices-003, rss-gen, or all) and optionally filters by 'band' (2.4ghz, 5ghz, 6ghz). Returns formatted text with wireless power limits and IT equipment emission limits.
def _ised_limit(arguments: dict[str, Any]) -> list[TextContent]: standard = arguments.get("standard", "all") band = arguments.get("band", "all") result = "ISED Canada Regulatory Limits\n" + "=" * 50 + "\n\n" if standard in ["rss-247", "all"]: rss247 = ISED_RULES.get("rss_247", ISED_RULES.get("standards", {}).get("rss_247", {})) result += "## RSS-247 (Digital Transmission Systems, FHSS, LE-LAN)\n\n" bands_data = rss247.get("bands", rss247.get("frequency_bands", {})) for band_key, band_data in bands_data.items(): if band != "all": if band == "2.4ghz" and "2_4" not in band_key and "2.4" not in band_key: continue if band == "5ghz" and "5" not in band_key: continue if band == "6ghz" and "6" not in band_key: continue label = band_data.get("label", band_key) freq = band_data.get("frequency_mhz", []) result += f" ### {label}" if freq: result += f" ({freq[0]}-{freq[1]} MHz)" result += "\n" if band_data.get("max_eirp_dbm") is not None: result += f" Max EIRP: {band_data['max_eirp_dbm']} dBm\n" if band_data.get("max_conducted_power_dbm") is not None: result += f" Max conducted: {band_data['max_conducted_power_dbm']} dBm\n" if band_data.get("dfs_required"): result += " DFS: Required\n" if band_data.get("notes"): result += f" Notes: {band_data['notes']}\n" result += "\n" if standard in ["ices-003", "all"]: ices = ISED_RULES.get("ices_003", ISED_RULES.get("standards", {}).get("ices_003", {})) result += "## ICES-003 (IT Equipment Emissions)\n\n" result += f"Based on: {ices.get('based_on', 'CISPR 32')}\n" for cls_key in ["class_a", "class_b"]: cls_data = ices.get(cls_key, ices.get("limits", {}).get(cls_key, {})) if cls_data: result += f"\n {cls_key.replace('_', ' ').title()}:\n" if isinstance(cls_data, dict): for k, v in cls_data.items(): if k not in ("limits",): result += f" {k}: {v}\n" result += "\n" if standard in ["rss-gen", "all"]: rss_gen = ISED_RULES.get("rss_gen", ISED_RULES.get("standards", {}).get("rss_gen", {})) result += "## RSS-Gen (General Requirements)\n\n" if isinstance(rss_gen, dict): for key, val in rss_gen.items(): if key not in ("metadata",) and not isinstance(val, (dict, list)): result += f" {key}: {val}\n" elif isinstance(val, list): result += f" {key}:\n" for item in val[:10]: result += f" - {item}\n" return [TextContent(type="text", text=result)] - The input schema and tool definition for 'ised_limit'. Defines two optional parameters: 'standard' (one of rss-247, ices-003, rss-gen, or all) and 'band' (one of 2.4ghz, 5ghz, 6ghz, or all).
Tool( name="ised_limit", description=( "Get ISED Canada (RSS-247 / ICES-003) limits. " "Returns wireless power limits and IT equipment emission limits." ), inputSchema={ "type": "object", "properties": { "standard": { "type": "string", "enum": ["rss-247", "ices-003", "rss-gen", "all"], "description": "ISED standard to query", }, "band": { "type": "string", "enum": ["2.4ghz", "5ghz", "6ghz", "all"], "description": "Frequency band (for RSS-247)", }, }, }, - src/mcp_emc_regulations/tools/international.py:115-116 (registration)Tool routing/dispatch in the InternationalTools class. When call_tool receives 'ised_limit', it delegates to the _ised_limit handler method.
elif name == "ised_limit": return self._ised_limit(arguments) - src/mcp_emc_regulations/registry.py:14-52 (registration)Auto-discovery registry that finds all ToolModule subclasses (including InternationalTools) and registers their tools. The 'ised_limit' tool is registered as part of InternationalTools' list_tools() output.
class ToolRegistry: """Discovers all :class:`ToolModule` subclasses in the ``tools`` package.""" def __init__(self) -> None: self._modules: list[ToolModule] = [] self._discover() # ------------------------------------------------------------------ # Public API used by server.py # ------------------------------------------------------------------ def list_tools(self) -> list[Tool]: result: list[Tool] = [] for mod in self._modules: result.extend(mod.list_tools()) return result async def call_tool(self, name: str, arguments: dict[str, Any]) -> list[TextContent]: for mod in self._modules: if mod.handles(name): return await mod.call_tool(name, arguments) return [TextContent(type="text", text=f"Unknown tool: {name}")] # ------------------------------------------------------------------ # Auto-discovery # ------------------------------------------------------------------ def _discover(self) -> None: """Import every module in the ``tools`` package and instantiate ToolModules.""" for info in pkgutil.iter_modules(_tools_pkg.__path__, _tools_pkg.__name__ + "."): module = importlib.import_module(info.name) for attr_name in dir(module): attr = getattr(module, attr_name) if ( isinstance(attr, type) and issubclass(attr, ToolModule) and attr is not ToolModule ): self._modules.append(attr()) - Data loading helper: loads ised_rules.json into the ISED_RULES dictionary at module level. This data is consumed by _ised_limit() to populate RSS-247, ICES-003, and RSS-Gen limits.
ISED_RULES = load_json("ised_rules.json") EU_RED = load_json("eu_red_framework.json") JAPAN_RULES = load_json("japan_rules.json") KOREA_RULES = load_json("korea_rules.json") INTL_MARKETS = load_json("international_markets.json")