mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-02-21 12:40:42 +00:00
tool: avoid // in comments for header files generated by Bluetooth SIG web scraping
This commit is contained in:
parent
4d5915b3c6
commit
d918542bd5
@ -7,7 +7,7 @@
|
||||
#define BLUETOOTH_COMPANY_ID_H
|
||||
|
||||
/**
|
||||
* Assigned numbers from https://www.bluetooth.com/specifications/assigned-numbers/company-identifiers
|
||||
* Assigned numbers from www.bluetooth.com/specifications/assigned-numbers/company-identifiers
|
||||
*/
|
||||
#define BLUETOOTH_COMPANY_ID_ERICSSON_TECHNOLOGY_LICENSING 0x0000
|
||||
#define BLUETOOTH_COMPANY_ID_NOKIA_MOBILE_PHONES 0x0001
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* bluetooth_data_types.h generated from Bluetooth SIG website for BTstack by tool/bluetooth_data_types.py
|
||||
* https://www.bluetooth.com/specifications/assigned-numbers/generic-access-profile
|
||||
* www.bluetooth.com/specifications/assigned-numbers/generic-access-profile
|
||||
* 2018-10-05 15:01:05.830879
|
||||
*/
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
#define BLUETOOTH_GATT_H
|
||||
|
||||
/**
|
||||
* Assigned numbers from https://www.bluetooth.com/specifications/gatt/declarations
|
||||
* Assigned numbers from www.bluetooth.com/specifications/gatt/declarations
|
||||
*/
|
||||
#define ORG_BLUETOOTH_ATTRIBUTE_GATT_CHARACTERISTIC_DECLARATION 0x2803 // Characteristic Declaration
|
||||
#define ORG_BLUETOOTH_ATTRIBUTE_GATT_INCLUDE_DECLARATION 0x2802 // Include
|
||||
@ -16,7 +16,7 @@
|
||||
#define ORG_BLUETOOTH_ATTRIBUTE_GATT_SECONDARY_SERVICE_DECLARATION 0x2801 // Secondary Service
|
||||
|
||||
/**
|
||||
* Assigned numbers from https://www.bluetooth.com/specifications/gatt/services
|
||||
* Assigned numbers from www.bluetooth.com/specifications/gatt/services
|
||||
*/
|
||||
#define ORG_BLUETOOTH_SERVICE_ALERT_NOTIFICATION 0x1811 // Alert Notification Service
|
||||
#define ORG_BLUETOOTH_SERVICE_AUTOMATION_IO 0x1815 // Automation IO
|
||||
@ -60,7 +60,7 @@
|
||||
#define ORG_BLUETOOTH_SERVICE_WEIGHT_SCALE 0x181D // Weight Scale
|
||||
|
||||
/**
|
||||
* Assigned numbers from https://www.bluetooth.com/specifications/gatt/characteristics
|
||||
* Assigned numbers from www.bluetooth.com/specifications/gatt/characteristics
|
||||
*/
|
||||
#define ORG_BLUETOOTH_CHARACTERISTIC_AEROBIC_HEART_RATE_LOWER_LIMIT 0x2A7E // Aerobic Heart Rate Lower Limit
|
||||
#define ORG_BLUETOOTH_CHARACTERISTIC_AEROBIC_HEART_RATE_UPPER_LIMIT 0x2A84 // Aerobic Heart Rate Upper Limit
|
||||
@ -290,7 +290,7 @@
|
||||
#define ORG_BLUETOOTH_CHARACTERISTIC_WIND_CHILL 0x2A79 // Wind Chill
|
||||
|
||||
/**
|
||||
* Assigned numbers from https://www.bluetooth.com/specifications/gatt/descriptors
|
||||
* Assigned numbers from www.bluetooth.com/specifications/gatt/descriptors
|
||||
*/
|
||||
#define ORG_BLUETOOTH_DESCRIPTOR_ES_CONFIGURATION 0x290B // Environmental Sensing Configuration
|
||||
#define ORG_BLUETOOTH_DESCRIPTOR_ES_MEASUREMENT 0x290C // Environmental Sensing Measurement
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* bluetooth_sdp.h generated from Bluetooth SIG website for BTstack by tool/bluetooth_sdp.py
|
||||
* https://www.bluetooth.com/specifications/assigned-numbers/service-discovery
|
||||
* www.bluetooth.com/specifications/assigned-numbers/service-discovery
|
||||
*/
|
||||
|
||||
#ifndef BLUETOOTH_SDP_H
|
||||
|
@ -77,7 +77,7 @@ def scrape_page(fout, url):
|
||||
global headers
|
||||
|
||||
print("Parsing %s" % url)
|
||||
fout.write(page_info.format(page=url))
|
||||
fout.write(page_info.format(page=url.replace('https://','')))
|
||||
|
||||
# get from web
|
||||
r = requests.get(url, headers=headers)
|
||||
|
@ -86,7 +86,7 @@ print(program_info)
|
||||
|
||||
with open(gen_path, 'wt') as fout:
|
||||
url = 'https://www.bluetooth.com/specifications/assigned-numbers/generic-access-profile'
|
||||
fout.write(header.format(datetime=str(datetime.datetime.now()), url=url))
|
||||
fout.write(header.format(datetime=str(datetime.datetime.now()), url=url.replace('https://','')))
|
||||
scrape_page(fout, url)
|
||||
fout.write(trailer)
|
||||
|
||||
|
@ -43,7 +43,7 @@ def strip_non_ascii(string):
|
||||
|
||||
def scrape_page(fout, url):
|
||||
print("Parsing %s" % url)
|
||||
fout.write(page_info.format(page=url))
|
||||
fout.write(page_info.format(page=url.replace('https://','')))
|
||||
page = requests.get(url, headers=headers)
|
||||
tree = html.fromstring(page.content)
|
||||
# get all <tr> elements in <table>
|
||||
|
@ -92,7 +92,7 @@ def process_rows(fout, rows, pattern):
|
||||
|
||||
def scrape_page(fout, url):
|
||||
print("Parsing %s" % url)
|
||||
fout.write(header.format(page=url,datetime=str(datetime.datetime.now())))
|
||||
fout.write(header.format(page=url.replace('https://',''),datetime=str(datetime.datetime.now())))
|
||||
|
||||
# get from web
|
||||
r = requests.get(url, headers=headers)
|
||||
|
Loading…
x
Reference in New Issue
Block a user