1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-22 15:38:11 +00:00

trezor.messages: regenerate classes

This commit is contained in:
Pavol Rusnak 2016-10-24 15:42:59 +02:00
parent 507d9bdf68
commit 6e658ff2f1
No known key found for this signature in database
GPG Key ID: 91F3B339B9A02A3D
86 changed files with 91 additions and 86 deletions

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('Address')
t.wire_type = const(30)
t.add_field(1, 'address', p.UnicodeType, flags=p.FLAG_REQUIRED)
Address = t
Address = t

View File

@ -7,4 +7,4 @@ t.add_field(1, 'language', p.UnicodeType)
t.add_field(2, 'label', p.UnicodeType)
t.add_field(3, 'use_passphrase', p.BoolType)
t.add_field(4, 'homescreen', p.BytesType)
ApplySettings = t
ApplySettings = t

View File

@ -3,4 +3,4 @@ import protobuf as p
from micropython import const
t = p.MessageType('ButtonAck')
t.wire_type = const(27)
ButtonAck = t
ButtonAck = t

View File

@ -5,4 +5,4 @@ t = p.MessageType('ButtonRequest')
t.wire_type = const(26)
t.add_field(1, 'code', p.UVarintType)
t.add_field(2, 'data', p.UnicodeType)
ButtonRequest = t
ButtonRequest = t

View File

@ -9,4 +9,4 @@ ProtectCall = const(7)
SignTx = const(8)
FirmwareCheck = const(9)
Address = const(10)
PublicKey = const(11)
PublicKey = const(11)

View File

@ -3,4 +3,4 @@ import protobuf as p
from micropython import const
t = p.MessageType('Cancel')
t.wire_type = const(20)
Cancel = t
Cancel = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('ChangePin')
t.wire_type = const(4)
t.add_field(1, 'remove', p.BoolType)
ChangePin = t
ChangePin = t

View File

@ -10,4 +10,4 @@ t.add_field(4, 'encrypt', p.BoolType)
t.add_field(5, 'ask_on_encrypt', p.BoolType)
t.add_field(6, 'ask_on_decrypt', p.BoolType)
t.add_field(7, 'iv', p.BytesType)
CipherKeyValue = t
CipherKeyValue = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('CipheredKeyValue')
t.wire_type = const(48)
t.add_field(1, 'value', p.BytesType)
CipheredKeyValue = t
CipheredKeyValue = t

View File

@ -3,4 +3,4 @@ import protobuf as p
from micropython import const
t = p.MessageType('ClearSession')
t.wire_type = const(24)
ClearSession = t
ClearSession = t

View File

@ -10,4 +10,4 @@ t.add_field(5, 'address_type_p2sh', p.UVarintType, default=5)
t.add_field(6, 'address_type_p2wpkh', p.UVarintType, default=6)
t.add_field(7, 'address_type_p2wsh', p.UVarintType, default=10)
t.add_field(8, 'signed_message_header', p.UnicodeType)
CoinType = t
CoinType = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('DebugLinkDecision')
t.wire_type = const(100)
t.add_field(1, 'yes_no', p.BoolType, flags=p.FLAG_REQUIRED)
DebugLinkDecision = t
DebugLinkDecision = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('DebugLinkFlashErase')
t.wire_type = const(113)
t.add_field(1, 'sector', p.UVarintType)
DebugLinkFlashErase = t
DebugLinkFlashErase = t

View File

@ -3,4 +3,4 @@ import protobuf as p
from micropython import const
t = p.MessageType('DebugLinkGetState')
t.wire_type = const(101)
DebugLinkGetState = t
DebugLinkGetState = t

View File

@ -6,4 +6,4 @@ t.wire_type = const(104)
t.add_field(1, 'level', p.UVarintType)
t.add_field(2, 'bucket', p.UnicodeType)
t.add_field(3, 'text', p.UnicodeType)
DebugLinkLog = t
DebugLinkLog = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('DebugLinkMemory')
t.wire_type = const(111)
t.add_field(1, 'memory', p.BytesType)
DebugLinkMemory = t
DebugLinkMemory = t

View File

@ -5,4 +5,4 @@ t = p.MessageType('DebugLinkMemoryRead')
t.wire_type = const(110)
t.add_field(1, 'address', p.UVarintType)
t.add_field(2, 'length', p.UVarintType)
DebugLinkMemoryRead = t
DebugLinkMemoryRead = t

View File

@ -6,4 +6,4 @@ t.wire_type = const(112)
t.add_field(1, 'address', p.UVarintType)
t.add_field(2, 'memory', p.BytesType)
t.add_field(3, 'flash', p.BoolType)
DebugLinkMemoryWrite = t
DebugLinkMemoryWrite = t

View File

@ -14,4 +14,4 @@ t.add_field(7, 'reset_word', p.UnicodeType)
t.add_field(8, 'reset_entropy', p.BytesType)
t.add_field(9, 'recovery_fake_word', p.UnicodeType)
t.add_field(10, 'recovery_word_pos', p.UVarintType)
DebugLinkState = t
DebugLinkState = t

View File

@ -3,4 +3,4 @@ import protobuf as p
from micropython import const
t = p.MessageType('DebugLinkStop')
t.wire_type = const(103)
DebugLinkStop = t
DebugLinkStop = t

View File

@ -7,4 +7,4 @@ t.add_field(1, 'address_n', p.UVarintType, flags=p.FLAG_REPEATED)
t.add_field(2, 'nonce', p.BytesType)
t.add_field(3, 'message', p.BytesType)
t.add_field(4, 'hmac', p.BytesType)
DecryptMessage = t
DecryptMessage = t

View File

@ -5,4 +5,4 @@ t = p.MessageType('DecryptedMessage')
t.wire_type = const(52)
t.add_field(1, 'message', p.BytesType)
t.add_field(2, 'address', p.UnicodeType)
DecryptedMessage = t
DecryptedMessage = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('ECDHSessionKey')
t.wire_type = const(62)
t.add_field(1, 'session_key', p.BytesType)
ECDHSessionKey = t
ECDHSessionKey = t

View File

@ -8,4 +8,4 @@ t.add_field(2, 'message', p.BytesType)
t.add_field(3, 'display_only', p.BoolType)
t.add_field(4, 'address_n', p.UVarintType, flags=p.FLAG_REPEATED)
t.add_field(5, 'coin_name', p.UnicodeType, default=u'Bitcoin')
EncryptMessage = t
EncryptMessage = t

View File

@ -6,4 +6,4 @@ t.wire_type = const(50)
t.add_field(1, 'nonce', p.BytesType)
t.add_field(2, 'message', p.BytesType)
t.add_field(3, 'hmac', p.BytesType)
EncryptedMessage = t
EncryptedMessage = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('Entropy')
t.wire_type = const(10)
t.add_field(1, 'entropy', p.BytesType, flags=p.FLAG_REQUIRED)
Entropy = t
Entropy = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('EntropyAck')
t.wire_type = const(36)
t.add_field(1, 'entropy', p.BytesType)
EntropyAck = t
EntropyAck = t

View File

@ -3,4 +3,4 @@ import protobuf as p
from micropython import const
t = p.MessageType('EntropyRequest')
t.wire_type = const(35)
EntropyRequest = t
EntropyRequest = t

View File

@ -6,4 +6,4 @@ t.wire_type = const(43)
t.add_field(1, 'outputs_count', p.UVarintType, flags=p.FLAG_REQUIRED)
t.add_field(2, 'inputs_count', p.UVarintType, flags=p.FLAG_REQUIRED)
t.add_field(3, 'coin_name', p.UnicodeType, default=u'Bitcoin')
EstimateTxSize = t
EstimateTxSize = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('EthereumAddress')
t.wire_type = const(57)
t.add_field(1, 'address', p.BytesType, flags=p.FLAG_REQUIRED)
EthereumAddress = t
EthereumAddress = t

View File

@ -5,4 +5,4 @@ t = p.MessageType('EthereumGetAddress')
t.wire_type = const(56)
t.add_field(1, 'address_n', p.UVarintType, flags=p.FLAG_REPEATED)
t.add_field(2, 'show_display', p.BoolType)
EthereumGetAddress = t
EthereumGetAddress = t

View File

@ -11,4 +11,4 @@ t.add_field(5, 'to', p.BytesType)
t.add_field(6, 'value', p.BytesType)
t.add_field(7, 'data_initial_chunk', p.BytesType)
t.add_field(8, 'data_length', p.UVarintType)
EthereumSignTx = t
EthereumSignTx = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('EthereumTxAck')
t.wire_type = const(60)
t.add_field(1, 'data_chunk', p.BytesType)
EthereumTxAck = t
EthereumTxAck = t

View File

@ -7,4 +7,4 @@ t.add_field(1, 'data_length', p.UVarintType)
t.add_field(2, 'signature_v', p.UVarintType)
t.add_field(3, 'signature_r', p.BytesType)
t.add_field(4, 'signature_s', p.BytesType)
EthereumTxRequest = t
EthereumTxRequest = t

View File

@ -5,4 +5,4 @@ t = p.MessageType('Failure')
t.wire_type = const(3)
t.add_field(1, 'code', p.UVarintType)
t.add_field(2, 'message', p.UnicodeType)
Failure = t
Failure = t

View File

@ -10,4 +10,4 @@ InvalidSignature = const(8)
Other = const(9)
NotEnoughFunds = const(10)
NotInitialized = const(11)
FirmwareError = const(99)
FirmwareError = const(99)

View File

@ -22,4 +22,4 @@ t.add_field(15, 'imported', p.BoolType)
t.add_field(16, 'pin_cached', p.BoolType)
t.add_field(17, 'passphrase_cached', p.BoolType)
t.add_field(18, 'firmware_present', p.BoolType)
Features = t
Features = t

View File

@ -3,4 +3,4 @@ import protobuf as p
from micropython import const
t = p.MessageType('FirmwareErase')
t.wire_type = const(6)
FirmwareErase = t
FirmwareErase = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('FirmwareUpload')
t.wire_type = const(7)
t.add_field(1, 'payload', p.BytesType, flags=p.FLAG_REQUIRED)
FirmwareUpload = t
FirmwareUpload = t

View File

@ -9,4 +9,4 @@ t.add_field(2, 'coin_name', p.UnicodeType, default=u'Bitcoin')
t.add_field(3, 'show_display', p.BoolType)
t.add_field(4, 'multisig', p.EmbeddedMessage(MultisigRedeemScriptType))
t.add_field(5, 'script_type', p.UVarintType, default=0)
GetAddress = t
GetAddress = t

View File

@ -7,4 +7,4 @@ t.wire_type = const(61)
t.add_field(1, 'identity', p.EmbeddedMessage(IdentityType))
t.add_field(2, 'peer_public_key', p.BytesType)
t.add_field(3, 'ecdsa_curve_name', p.UnicodeType)
GetECDHSessionKey = t
GetECDHSessionKey = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('GetEntropy')
t.wire_type = const(9)
t.add_field(1, 'size', p.UVarintType, flags=p.FLAG_REQUIRED)
GetEntropy = t
GetEntropy = t

View File

@ -3,4 +3,4 @@ import protobuf as p
from micropython import const
t = p.MessageType('GetFeatures')
t.wire_type = const(55)
GetFeatures = t
GetFeatures = t

View File

@ -6,4 +6,4 @@ t.wire_type = const(11)
t.add_field(1, 'address_n', p.UVarintType, flags=p.FLAG_REPEATED)
t.add_field(2, 'ecdsa_curve_name', p.UnicodeType)
t.add_field(3, 'show_display', p.BoolType)
GetPublicKey = t
GetPublicKey = t

View File

@ -5,4 +5,4 @@ from .HDNodeType import HDNodeType
t = p.MessageType('HDNodePathType')
t.add_field(1, 'node', p.EmbeddedMessage(HDNodeType), flags=p.FLAG_REQUIRED)
t.add_field(2, 'address_n', p.UVarintType, flags=p.FLAG_REPEATED)
HDNodePathType = t
HDNodePathType = t

View File

@ -8,4 +8,4 @@ t.add_field(3, 'child_num', p.UVarintType, flags=p.FLAG_REQUIRED)
t.add_field(4, 'chain_code', p.BytesType, flags=p.FLAG_REQUIRED)
t.add_field(5, 'private_key', p.BytesType)
t.add_field(6, 'public_key', p.BytesType)
HDNodeType = t
HDNodeType = t

View File

@ -8,4 +8,4 @@ t.add_field(3, 'host', p.UnicodeType)
t.add_field(4, 'port', p.UnicodeType)
t.add_field(5, 'path', p.UnicodeType)
t.add_field(6, 'index', p.UVarintType, default=0)
IdentityType = t
IdentityType = t

View File

@ -3,4 +3,4 @@ import protobuf as p
from micropython import const
t = p.MessageType('Initialize')
t.wire_type = const(0)
Initialize = t
Initialize = t

View File

@ -3,4 +3,4 @@ SPENDADDRESS = const(0)
SPENDMULTISIG = const(1)
EXTERNAL = const(2)
SPENDWITNESS = const(3)
SPENDP2SHWITNESS = const(4)
SPENDP2SHWITNESS = const(4)

View File

@ -11,4 +11,4 @@ t.add_field(4, 'passphrase_protection', p.BoolType)
t.add_field(5, 'language', p.UnicodeType, default=u'english')
t.add_field(6, 'label', p.UnicodeType)
t.add_field(7, 'skip_checksum', p.BoolType)
LoadDevice = t
LoadDevice = t

View File

@ -5,4 +5,4 @@ t = p.MessageType('MessageSignature')
t.wire_type = const(40)
t.add_field(1, 'address', p.UnicodeType)
t.add_field(2, 'signature', p.BytesType)
MessageSignature = t
MessageSignature = t

View File

@ -64,4 +64,4 @@ DebugLinkLog = const(104)
DebugLinkMemoryRead = const(110)
DebugLinkMemory = const(111)
DebugLinkMemoryWrite = const(112)
DebugLinkFlashErase = const(113)
DebugLinkFlashErase = const(113)

View File

@ -6,4 +6,4 @@ t = p.MessageType('MultisigRedeemScriptType')
t.add_field(1, 'pubkeys', p.EmbeddedMessage(HDNodePathType), flags=p.FLAG_REPEATED)
t.add_field(2, 'signatures', p.BytesType, flags=p.FLAG_REPEATED)
t.add_field(3, 'm', p.UVarintType)
MultisigRedeemScriptType = t
MultisigRedeemScriptType = t

View File

@ -4,4 +4,4 @@ PAYTOSCRIPTHASH = const(1)
PAYTOMULTISIG = const(2)
PAYTOOPRETURN = const(3)
PAYTOWITNESS = const(4)
PAYTOP2SHWITNESS = const(5)
PAYTOP2SHWITNESS = const(5)

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('PassphraseAck')
t.wire_type = const(42)
t.add_field(1, 'passphrase', p.UnicodeType, flags=p.FLAG_REQUIRED)
PassphraseAck = t
PassphraseAck = t

View File

@ -3,4 +3,4 @@ import protobuf as p
from micropython import const
t = p.MessageType('PassphraseRequest')
t.wire_type = const(41)
PassphraseRequest = t
PassphraseRequest = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('PinMatrixAck')
t.wire_type = const(19)
t.add_field(1, 'pin', p.UnicodeType, flags=p.FLAG_REQUIRED)
PinMatrixAck = t
PinMatrixAck = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('PinMatrixRequest')
t.wire_type = const(18)
t.add_field(1, 'type', p.UVarintType)
PinMatrixRequest = t
PinMatrixRequest = t

View File

@ -1,4 +1,4 @@
# Automatically generated by pb2py
Current = const(1)
NewFirst = const(2)
NewSecond = const(3)
NewSecond = const(3)

View File

@ -7,4 +7,4 @@ t.add_field(1, 'message', p.UnicodeType)
t.add_field(2, 'button_protection', p.BoolType)
t.add_field(3, 'pin_protection', p.BoolType)
t.add_field(4, 'passphrase_protection', p.BoolType)
Ping = t
Ping = t

View File

@ -6,4 +6,4 @@ t = p.MessageType('PublicKey')
t.wire_type = const(12)
t.add_field(1, 'node', p.EmbeddedMessage(HDNodeType), flags=p.FLAG_REQUIRED)
t.add_field(2, 'xpub', p.UnicodeType)
PublicKey = t
PublicKey = t

View File

@ -9,4 +9,4 @@ t.add_field(3, 'pin_protection', p.BoolType)
t.add_field(4, 'language', p.UnicodeType, default=u'english')
t.add_field(5, 'label', p.UnicodeType)
t.add_field(6, 'enforce_wordlist', p.BoolType)
RecoveryDevice = t
RecoveryDevice = t

View File

@ -2,4 +2,5 @@
TXINPUT = const(0)
TXOUTPUT = const(1)
TXMETA = const(2)
TXFINISHED = const(3)
TXFINISHED = const(3)
TXEXTRADATA = const(4)

View File

@ -9,4 +9,4 @@ t.add_field(3, 'passphrase_protection', p.BoolType)
t.add_field(4, 'pin_protection', p.BoolType)
t.add_field(5, 'language', p.UnicodeType, default=u'english')
t.add_field(6, 'label', p.UnicodeType)
ResetDevice = t
ResetDevice = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('SetU2FCounter')
t.wire_type = const(63)
t.add_field(1, 'u2f_counter', p.UVarintType)
SetU2FCounter = t
SetU2FCounter = t

View File

@ -8,4 +8,4 @@ t.add_field(1, 'identity', p.EmbeddedMessage(IdentityType))
t.add_field(2, 'challenge_hidden', p.BytesType)
t.add_field(3, 'challenge_visual', p.UnicodeType)
t.add_field(4, 'ecdsa_curve_name', p.UnicodeType)
SignIdentity = t
SignIdentity = t

View File

@ -6,4 +6,4 @@ t.wire_type = const(38)
t.add_field(1, 'address_n', p.UVarintType, flags=p.FLAG_REPEATED)
t.add_field(2, 'message', p.BytesType, flags=p.FLAG_REQUIRED)
t.add_field(3, 'coin_name', p.UnicodeType, default=u'Bitcoin')
SignMessage = t
SignMessage = t

View File

@ -8,4 +8,4 @@ t.add_field(2, 'inputs_count', p.UVarintType, flags=p.FLAG_REQUIRED)
t.add_field(3, 'coin_name', p.UnicodeType, default=u'Bitcoin')
t.add_field(4, 'version', p.UVarintType, default=1)
t.add_field(5, 'lock_time', p.UVarintType, default=0)
SignTx = t
SignTx = t

View File

@ -6,4 +6,4 @@ t.wire_type = const(54)
t.add_field(1, 'address', p.UnicodeType)
t.add_field(2, 'public_key', p.BytesType)
t.add_field(3, 'signature', p.BytesType)
SignedIdentity = t
SignedIdentity = t

View File

@ -12,4 +12,4 @@ t.add_field(3, 'transactions', p.EmbeddedMessage(TransactionType), flags=p.FLAG_
t.add_field(4, 'coin_name', p.UnicodeType, default=u'Bitcoin')
t.add_field(5, 'version', p.UVarintType, default=1)
t.add_field(6, 'lock_time', p.UVarintType, default=0)
SimpleSignTx = t
SimpleSignTx = t

View File

@ -14,4 +14,4 @@ t.add_field(8, 'label', p.UnicodeType)
t.add_field(9, 'imported', p.BoolType)
t.add_field(10, 'homescreen', p.BytesType)
t.add_field(11, 'u2f_counter', p.UVarintType)
Storage = t
Storage = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('Success')
t.wire_type = const(2)
t.add_field(1, 'message', p.UnicodeType)
Success = t
Success = t

View File

@ -12,4 +12,6 @@ t.add_field(4, 'lock_time', p.UVarintType)
t.add_field(5, 'outputs', p.EmbeddedMessage(TxOutputType), flags=p.FLAG_REPEATED)
t.add_field(6, 'inputs_cnt', p.UVarintType)
t.add_field(7, 'outputs_cnt', p.UVarintType)
TransactionType = t
t.add_field(8, 'extra_data', p.BytesType)
t.add_field(9, 'extra_data_len', p.UVarintType)
TransactionType = t

View File

@ -5,4 +5,4 @@ from .TransactionType import TransactionType
t = p.MessageType('TxAck')
t.wire_type = const(22)
t.add_field(1, 'tx', p.EmbeddedMessage(TransactionType))
TxAck = t
TxAck = t

View File

@ -11,4 +11,4 @@ t.add_field(5, 'sequence', p.UVarintType, default=4294967295)
t.add_field(6, 'script_type', p.UVarintType, default=0)
t.add_field(7, 'multisig', p.EmbeddedMessage(MultisigRedeemScriptType))
t.add_field(8, 'amount', p.UVarintType)
TxInputType = t
TxInputType = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('TxOutputBinType')
t.add_field(1, 'amount', p.UVarintType, flags=p.FLAG_REQUIRED)
t.add_field(2, 'script_pubkey', p.BytesType, flags=p.FLAG_REQUIRED)
TxOutputBinType = t
TxOutputBinType = t

View File

@ -9,4 +9,4 @@ t.add_field(3, 'amount', p.UVarintType, flags=p.FLAG_REQUIRED)
t.add_field(4, 'script_type', p.UVarintType, flags=p.FLAG_REQUIRED)
t.add_field(5, 'multisig', p.EmbeddedMessage(MultisigRedeemScriptType))
t.add_field(6, 'op_return_data', p.BytesType)
TxOutputType = t
TxOutputType = t

View File

@ -8,4 +8,4 @@ t.wire_type = const(21)
t.add_field(1, 'request_type', p.UVarintType)
t.add_field(2, 'details', p.EmbeddedMessage(TxRequestDetailsType))
t.add_field(3, 'serialized', p.EmbeddedMessage(TxRequestSerializedType))
TxRequest = t
TxRequest = t

View File

@ -4,4 +4,6 @@ from micropython import const
t = p.MessageType('TxRequestDetailsType')
t.add_field(1, 'request_index', p.UVarintType)
t.add_field(2, 'tx_hash', p.BytesType)
TxRequestDetailsType = t
t.add_field(3, 'extra_data_len', p.UVarintType)
t.add_field(4, 'extra_data_offset', p.UVarintType)
TxRequestDetailsType = t

View File

@ -5,4 +5,4 @@ t = p.MessageType('TxRequestSerializedType')
t.add_field(1, 'signature_index', p.UVarintType)
t.add_field(2, 'signature', p.BytesType)
t.add_field(3, 'serialized_tx', p.BytesType)
TxRequestSerializedType = t
TxRequestSerializedType = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('TxSize')
t.wire_type = const(44)
t.add_field(1, 'tx_size', p.UVarintType)
TxSize = t
TxSize = t

View File

@ -7,4 +7,4 @@ t.add_field(1, 'address', p.UnicodeType)
t.add_field(2, 'signature', p.BytesType)
t.add_field(3, 'message', p.BytesType)
t.add_field(4, 'coin_name', p.UnicodeType, default=u'Bitcoin')
VerifyMessage = t
VerifyMessage = t

View File

@ -3,4 +3,4 @@ import protobuf as p
from micropython import const
t = p.MessageType('WipeDevice')
t.wire_type = const(5)
WipeDevice = t
WipeDevice = t

View File

@ -4,4 +4,4 @@ from micropython import const
t = p.MessageType('WordAck')
t.wire_type = const(47)
t.add_field(1, 'word', p.UnicodeType, flags=p.FLAG_REQUIRED)
WordAck = t
WordAck = t

View File

@ -3,4 +3,4 @@ import protobuf as p
from micropython import const
t = p.MessageType('WordRequest')
t.wire_type = const(46)
WordRequest = t
WordRequest = t

View File

@ -140,7 +140,7 @@ def write_to_file(genpath, t, out):
f = open(os.path.join(genpath, "%s.py" % t), 'w')
out = ["# Automatically generated by pb2py"] + out
data = "\n".join(out)
data = "\n".join(out) + "\n"
f.write(data)
f.close()