Skip to content

Commit

Permalink
feat(client-iot-wireless): Supports the new feature of LoRaWAN roamin…
Browse files Browse the repository at this point in the history
…g, allows to configure MaxEirp for LoRaWAN gateway, and allows to configure PingSlotPeriod for LoRaWAN multicast group
  • Loading branch information
awstools committed Apr 17, 2023
1 parent 7be646f commit 73f7859
Show file tree
Hide file tree
Showing 8 changed files with 182 additions and 59 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ export interface CreateServiceProfileCommandOutput extends CreateServiceProfileR
* AddGwMetadata: true || false,
* DrMin: Number("int"),
* DrMax: Number("int"),
* PrAllowed: true || false,
* RaAllowed: true || false,
* },
* Tags: [ // TagList
* { // Tag
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ export interface CreateWirelessGatewayCommandOutput extends CreateWirelessGatewa
* Number("int"),
* ],
* },
* MaxEirp: Number("float"),
* },
* Tags: [ // TagList
* { // Tag
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ export interface StartMulticastGroupSessionCommandOutput extends StartMulticastG
* DlFreq: Number("int"),
* SessionStartTime: new Date("TIMESTAMP"),
* SessionTimeout: Number("int"),
* PingSlotPeriod: Number("int"),
* },
* };
* const command = new StartMulticastGroupSessionCommand(input);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ export interface UpdateWirelessGatewayCommandOutput extends UpdateWirelessGatewa
* NetIdFilters: [ // NetIdFilters
* "STRING_VALUE",
* ],
* MaxEirp: Number("float"),
* };
* const command = new UpdateWirelessGatewayCommand(input);
* const response = await client.send(command);
Expand Down
20 changes: 20 additions & 0 deletions clients/client-iot-wireless/src/models/models_0.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1700,6 +1700,16 @@ export interface LoRaWANServiceProfile {
* <p>The DrMax value.</p>
*/
DrMax?: number;

/**
* <p>The PRAllowed value that describes whether passive roaming is allowed.</p>
*/
PrAllowed?: boolean;

/**
* <p>The RAAllowed value that describes whether roaming activation is allowed.</p>
*/
RaAllowed?: boolean;
}

/**
Expand Down Expand Up @@ -2020,6 +2030,11 @@ export interface LoRaWANGateway {
* <p>Beaconing object information, which consists of the data rate and frequency parameters.</p>
*/
Beaconing?: Beaconing;

/**
* <p>The MaxEIRP value.</p>
*/
MaxEirp?: number;
}

/**
Expand Down Expand Up @@ -3642,6 +3657,11 @@ export interface LoRaWANMulticastSession {
* <p>How long before a multicast group session is to timeout.</p>
*/
SessionTimeout?: number;

/**
* <p>The PingSlotPeriod value.</p>
*/
PingSlotPeriod?: number;
}

/**
Expand Down
5 changes: 5 additions & 0 deletions clients/client-iot-wireless/src/models/models_1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1369,6 +1369,11 @@ export interface UpdateWirelessGatewayRequest {
* <p>A list of NetId values that are used by LoRa gateways to filter the uplink frames.</p>
*/
NetIdFilters?: string[];

/**
* <p>The MaxEIRP value.</p>
*/
MaxEirp?: number;
}

/**
Expand Down
66 changes: 59 additions & 7 deletions clients/client-iot-wireless/src/protocols/Aws_restJson1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -489,6 +489,7 @@ import {
UpdateAbpV1_0_x,
UpdateAbpV1_1,
UpdateFPorts,
WirelessGatewayStatistics,
WirelessMetadata,
} from "../models/models_1";

Expand Down Expand Up @@ -994,7 +995,7 @@ export const se_CreateWirelessGatewayCommand = async (
take(input, {
ClientRequestToken: (_) => _ ?? generateIdempotencyToken(),
Description: [],
LoRaWAN: (_) => _json(_),
LoRaWAN: (_) => se_LoRaWANGateway(_, context),
Name: [],
Tags: (_) => _json(_),
})
Expand Down Expand Up @@ -3758,6 +3759,7 @@ export const se_UpdateWirelessGatewayCommand = async (
take(input, {
Description: [],
JoinEuiFilters: (_) => _json(_),
MaxEirp: (_) => __serializeFloat(_),
Name: [],
NetIdFilters: (_) => _json(_),
})
Expand Down Expand Up @@ -7247,7 +7249,7 @@ export const de_GetWirelessGatewayCommand = async (
Arn: __expectString,
Description: __expectString,
Id: __expectString,
LoRaWAN: _json,
LoRaWAN: (_) => de_LoRaWANGateway(_, context),
Name: __expectString,
ThingArn: __expectString,
ThingName: __expectString,
Expand Down Expand Up @@ -8491,7 +8493,7 @@ export const de_ListWirelessGatewaysCommand = async (
const data: Record<string, any> = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
const doc = take(data, {
NextToken: __expectString,
WirelessGatewayList: _json,
WirelessGatewayList: (_) => de_WirelessGatewayStatisticsList(_, context),
});
Object.assign(contents, doc);
return contents;
Expand Down Expand Up @@ -10441,7 +10443,20 @@ const se_Gnss = (input: Gnss, context: __SerdeContext): any => {

// se_LoRaWANFuotaTask omitted.

// se_LoRaWANGateway omitted.
/**
* serializeAws_restJson1LoRaWANGateway
*/
const se_LoRaWANGateway = (input: LoRaWANGateway, context: __SerdeContext): any => {
return take(input, {
Beaconing: _json,
GatewayEui: [],
JoinEuiFilters: _json,
MaxEirp: __serializeFloat,
NetIdFilters: _json,
RfRegion: [],
SubBands: _json,
});
};

// se_LoRaWANGatewayVersion omitted.

Expand All @@ -10460,6 +10475,7 @@ const se_LoRaWANMulticastSession = (input: LoRaWANMulticastSession, context: __S
return take(input, {
DlDr: [],
DlFreq: [],
PingSlotPeriod: [],
SessionStartTime: (_) => _.toISOString().split(".")[0] + "Z",
SessionTimeout: [],
});
Expand Down Expand Up @@ -10801,7 +10817,20 @@ const de_LoRaWANFuotaTaskGetInfo = (output: any, context: __SerdeContext): LoRaW
}) as any;
};

// de_LoRaWANGateway omitted.
/**
* deserializeAws_restJson1LoRaWANGateway
*/
const de_LoRaWANGateway = (output: any, context: __SerdeContext): LoRaWANGateway => {
return take(output, {
Beaconing: _json,
GatewayEui: __expectString,
JoinEuiFilters: _json,
MaxEirp: __limitedParseFloat32,
NetIdFilters: _json,
RfRegion: __expectString,
SubBands: _json,
}) as any;
};

// de_LoRaWANGatewayCurrentVersion omitted.

Expand Down Expand Up @@ -10847,6 +10876,7 @@ const de_LoRaWANMulticastSession = (output: any, context: __SerdeContext): LoRaW
return take(output, {
DlDr: __expectInt32,
DlFreq: __expectInt32,
PingSlotPeriod: __expectInt32,
SessionStartTime: (_: any) => __expectNonNull(__parseRfc3339DateTimeWithOffset(_)),
SessionTimeout: __expectInt32,
}) as any;
Expand Down Expand Up @@ -11005,9 +11035,31 @@ const de_WirelessDeviceImportTaskList = (output: any, context: __SerdeContext):

// de_WirelessGatewayLogOptionList omitted.

// de_WirelessGatewayStatistics omitted.
/**
* deserializeAws_restJson1WirelessGatewayStatistics
*/
const de_WirelessGatewayStatistics = (output: any, context: __SerdeContext): WirelessGatewayStatistics => {
return take(output, {
Arn: __expectString,
Description: __expectString,
Id: __expectString,
LastUplinkReceivedAt: __expectString,
LoRaWAN: (_: any) => de_LoRaWANGateway(_, context),
Name: __expectString,
}) as any;
};

// de_WirelessGatewayStatisticsList omitted.
/**
* deserializeAws_restJson1WirelessGatewayStatisticsList
*/
const de_WirelessGatewayStatisticsList = (output: any, context: __SerdeContext): WirelessGatewayStatistics[] => {
const retVal = (output || [])
.filter((e: any) => e != null)
.map((entry: any) => {
return de_WirelessGatewayStatistics(entry, context);
});
return retVal;
};

// de_WirelessGatewayTaskDefinitionList omitted.

Expand Down
Loading

0 comments on commit 73f7859

Please sign in to comment.